@parto-system-design/ui 1.1.5 → 1.1.8
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/AGENTS.md +233 -0
- package/LICENSE +21 -0
- package/README.md +96 -43
- package/dist/chunk-2ACKKPWA.cjs +112 -0
- package/dist/chunk-2ACKKPWA.cjs.map +1 -0
- package/dist/chunk-2UD3LGVX.cjs +316 -0
- package/dist/chunk-2UD3LGVX.cjs.map +1 -0
- package/dist/chunk-3QYYPPFJ.js +269 -0
- package/dist/chunk-3QYYPPFJ.js.map +1 -0
- package/dist/chunk-4SVQNEVH.js +173 -0
- package/dist/chunk-4SVQNEVH.js.map +1 -0
- package/dist/chunk-4WONHORR.cjs +152 -0
- package/dist/chunk-4WONHORR.cjs.map +1 -0
- package/dist/chunk-5HCXH6GS.js +409 -0
- package/dist/chunk-5HCXH6GS.js.map +1 -0
- package/dist/chunk-5JJSRGJD.js +31 -0
- package/dist/chunk-5JJSRGJD.js.map +1 -0
- package/dist/chunk-5K6E4ZSW.cjs +77 -0
- package/dist/chunk-5K6E4ZSW.cjs.map +1 -0
- package/dist/chunk-5NY26ULO.js +89 -0
- package/dist/chunk-5NY26ULO.js.map +1 -0
- package/dist/chunk-7RVPG3LE.cjs +231 -0
- package/dist/chunk-7RVPG3LE.cjs.map +1 -0
- package/dist/chunk-AYEK3WOM.js +207 -0
- package/dist/chunk-AYEK3WOM.js.map +1 -0
- package/dist/chunk-BRMBLIQG.js +53 -0
- package/dist/chunk-BRMBLIQG.js.map +1 -0
- package/dist/chunk-CAJKSTXX.cjs +54 -0
- package/dist/chunk-CAJKSTXX.cjs.map +1 -0
- package/dist/chunk-CKFWMHQU.js +401 -0
- package/dist/chunk-CKFWMHQU.js.map +1 -0
- package/dist/chunk-CV3N3HVK.js +672 -0
- package/dist/chunk-CV3N3HVK.js.map +1 -0
- package/dist/chunk-D2EBLE2B.cjs +220 -0
- package/dist/chunk-D2EBLE2B.cjs.map +1 -0
- package/dist/chunk-GCZ6YATL.js +940 -0
- package/dist/chunk-GCZ6YATL.js.map +1 -0
- package/dist/chunk-GKRAZGDI.cjs +84 -0
- package/dist/chunk-GKRAZGDI.cjs.map +1 -0
- package/dist/chunk-GPYJ66CG.js +45 -0
- package/dist/chunk-GPYJ66CG.js.map +1 -0
- package/dist/chunk-HF6XU5NI.js +84 -0
- package/dist/chunk-HF6XU5NI.js.map +1 -0
- package/dist/chunk-HJPDZOMJ.cjs +87 -0
- package/dist/chunk-HJPDZOMJ.cjs.map +1 -0
- package/dist/chunk-HS3XI3CC.cjs +69 -0
- package/dist/chunk-HS3XI3CC.cjs.map +1 -0
- package/dist/chunk-HUCC3QH5.cjs +53 -0
- package/dist/chunk-HUCC3QH5.cjs.map +1 -0
- package/dist/chunk-HYZ6BQPS.cjs +425 -0
- package/dist/chunk-HYZ6BQPS.cjs.map +1 -0
- package/dist/chunk-ISCSZMYW.cjs +106 -0
- package/dist/chunk-ISCSZMYW.cjs.map +1 -0
- package/dist/chunk-IXFEFIDO.js +82 -0
- package/dist/chunk-IXFEFIDO.js.map +1 -0
- package/dist/chunk-JCJLN437.js +108 -0
- package/dist/chunk-JCJLN437.js.map +1 -0
- package/dist/chunk-JMKNNH63.cjs +982 -0
- package/dist/chunk-JMKNNH63.cjs.map +1 -0
- package/dist/chunk-JUBHQAA2.js +53 -0
- package/dist/chunk-JUBHQAA2.js.map +1 -0
- package/dist/chunk-K6G63EED.cjs +41 -0
- package/dist/chunk-K6G63EED.cjs.map +1 -0
- package/dist/chunk-KCWRCSI7.js +62 -0
- package/dist/chunk-KCWRCSI7.js.map +1 -0
- package/dist/chunk-KYM7NIJO.cjs +433 -0
- package/dist/chunk-KYM7NIJO.cjs.map +1 -0
- package/dist/chunk-L2L5CKC2.js +291 -0
- package/dist/chunk-L2L5CKC2.js.map +1 -0
- package/dist/chunk-M5CHZ5BA.js +124 -0
- package/dist/chunk-M5CHZ5BA.js.map +1 -0
- package/dist/chunk-MEK4RSGC.js +65 -0
- package/dist/chunk-MEK4RSGC.js.map +1 -0
- package/dist/chunk-MEKWH3GS.js +89 -0
- package/dist/chunk-MEKWH3GS.js.map +1 -0
- package/dist/chunk-MFTX2DDQ.js +27 -0
- package/dist/chunk-MFTX2DDQ.js.map +1 -0
- package/dist/chunk-MMC6M35Q.cjs +272 -0
- package/dist/chunk-MMC6M35Q.cjs.map +1 -0
- package/dist/chunk-NMH43BDC.js +130 -0
- package/dist/chunk-NMH43BDC.js.map +1 -0
- package/dist/chunk-NORDUD2T.cjs +135 -0
- package/dist/chunk-NORDUD2T.cjs.map +1 -0
- package/dist/chunk-NV4JOKWL.cjs +197 -0
- package/dist/chunk-NV4JOKWL.cjs.map +1 -0
- package/dist/chunk-O2JG7WY5.cjs +121 -0
- package/dist/chunk-O2JG7WY5.cjs.map +1 -0
- package/dist/chunk-ONO2FTV4.cjs +68 -0
- package/dist/chunk-ONO2FTV4.cjs.map +1 -0
- package/dist/chunk-OQB6HIUL.cjs +108 -0
- package/dist/chunk-OQB6HIUL.cjs.map +1 -0
- package/dist/chunk-OS6CMYAS.cjs +79 -0
- package/dist/chunk-OS6CMYAS.cjs.map +1 -0
- package/dist/chunk-PYURPUTV.js +402 -0
- package/dist/chunk-PYURPUTV.js.map +1 -0
- package/dist/chunk-RJ3HYZ7S.js +44 -0
- package/dist/chunk-RJ3HYZ7S.js.map +1 -0
- package/dist/chunk-RZNRIOLT.js +128 -0
- package/dist/chunk-RZNRIOLT.js.map +1 -0
- package/dist/chunk-S3T2L6NA.js +38 -0
- package/dist/chunk-S3T2L6NA.js.map +1 -0
- package/dist/chunk-S5IPJQZ3.cjs +161 -0
- package/dist/chunk-S5IPJQZ3.cjs.map +1 -0
- package/dist/chunk-SB5DSYR5.js +211 -0
- package/dist/chunk-SB5DSYR5.js.map +1 -0
- package/dist/chunk-SFXV2DUH.js +106 -0
- package/dist/chunk-SFXV2DUH.js.map +1 -0
- package/dist/chunk-SXEPGD4Z.cjs +152 -0
- package/dist/chunk-SXEPGD4Z.cjs.map +1 -0
- package/dist/chunk-SXWSOU3Y.js +89 -0
- package/dist/chunk-SXWSOU3Y.js.map +1 -0
- package/dist/chunk-SZMVOHT7.cjs +107 -0
- package/dist/chunk-SZMVOHT7.cjs.map +1 -0
- package/dist/chunk-TWJXOV4C.js +145 -0
- package/dist/chunk-TWJXOV4C.js.map +1 -0
- package/dist/chunk-U3ADRIVO.cjs +434 -0
- package/dist/chunk-U3ADRIVO.cjs.map +1 -0
- package/dist/chunk-U5FLLCGC.cjs +151 -0
- package/dist/chunk-U5FLLCGC.cjs.map +1 -0
- package/dist/chunk-UOZN45G4.cjs +130 -0
- package/dist/chunk-UOZN45G4.cjs.map +1 -0
- package/dist/chunk-VHLDOG74.cjs +167 -0
- package/dist/chunk-VHLDOG74.cjs.map +1 -0
- package/dist/chunk-YC5KLN6I.js +139 -0
- package/dist/chunk-YC5KLN6I.js.map +1 -0
- package/dist/chunk-YENXXYUV.cjs +111 -0
- package/dist/chunk-YENXXYUV.cjs.map +1 -0
- package/dist/chunk-YFQWC2PW.js +113 -0
- package/dist/chunk-YFQWC2PW.js.map +1 -0
- package/dist/chunk-Z2TY4A75.cjs +700 -0
- package/dist/chunk-Z2TY4A75.cjs.map +1 -0
- package/dist/chunk-Z56O7UEU.cjs +136 -0
- package/dist/chunk-Z56O7UEU.cjs.map +1 -0
- package/dist/chunk-ZBZDR4ZC.js +106 -0
- package/dist/chunk-ZBZDR4ZC.js.map +1 -0
- package/dist/components/charts/PartoAreaChart.cjs +15 -0
- package/dist/components/charts/PartoAreaChart.cjs.map +1 -0
- package/dist/components/charts/PartoAreaChart.d.cts +53 -0
- package/dist/components/charts/PartoAreaChart.d.ts +53 -0
- package/dist/components/charts/PartoAreaChart.js +6 -0
- package/dist/components/charts/PartoAreaChart.js.map +1 -0
- package/dist/components/charts/PartoBarChart.cjs +15 -0
- package/dist/components/charts/PartoBarChart.cjs.map +1 -0
- package/dist/components/charts/PartoBarChart.d.cts +61 -0
- package/dist/components/charts/PartoBarChart.d.ts +61 -0
- package/dist/components/charts/PartoBarChart.js +6 -0
- package/dist/components/charts/PartoBarChart.js.map +1 -0
- package/dist/components/charts/PartoLineChart.cjs +15 -0
- package/dist/components/charts/PartoLineChart.cjs.map +1 -0
- package/dist/components/charts/PartoLineChart.d.cts +57 -0
- package/dist/components/charts/PartoLineChart.d.ts +57 -0
- package/dist/components/charts/PartoLineChart.js +6 -0
- package/dist/components/charts/PartoLineChart.js.map +1 -0
- package/dist/components/charts/PartoPieChart.cjs +15 -0
- package/dist/components/charts/PartoPieChart.cjs.map +1 -0
- package/dist/components/charts/PartoPieChart.d.cts +52 -0
- package/dist/components/charts/PartoPieChart.d.ts +52 -0
- package/dist/components/charts/PartoPieChart.js +6 -0
- package/dist/components/charts/PartoPieChart.js.map +1 -0
- package/dist/components/ui/alert-rule-card.cjs +15 -0
- package/dist/components/ui/alert-rule-card.cjs.map +1 -0
- package/dist/components/ui/alert-rule-card.d.cts +38 -0
- package/dist/components/ui/alert-rule-card.d.ts +38 -0
- package/dist/components/ui/alert-rule-card.js +6 -0
- package/dist/components/ui/alert-rule-card.js.map +1 -0
- package/dist/components/ui/avatar.cjs +21 -0
- package/dist/components/ui/avatar.cjs.map +1 -0
- package/dist/components/ui/avatar.d.cts +18 -0
- package/dist/components/ui/avatar.d.ts +18 -0
- package/dist/components/ui/avatar.js +4 -0
- package/dist/components/ui/avatar.js.map +1 -0
- package/dist/components/ui/badge.cjs +17 -0
- package/dist/components/ui/badge.cjs.map +1 -0
- package/dist/components/ui/badge.d.cts +16 -0
- package/dist/components/ui/badge.d.ts +16 -0
- package/dist/components/ui/badge.js +4 -0
- package/dist/components/ui/badge.js.map +1 -0
- package/dist/components/ui/button.cjs +18 -0
- package/dist/components/ui/button.cjs.map +1 -0
- package/dist/components/ui/button.d.cts +37 -0
- package/dist/components/ui/button.d.ts +37 -0
- package/dist/components/ui/button.js +5 -0
- package/dist/components/ui/button.js.map +1 -0
- package/dist/components/ui/calendar.cjs +15 -0
- package/dist/components/ui/calendar.cjs.map +1 -0
- package/dist/components/ui/calendar.d.cts +17 -0
- package/dist/components/ui/calendar.d.ts +17 -0
- package/dist/components/ui/calendar.js +6 -0
- package/dist/components/ui/calendar.js.map +1 -0
- package/dist/components/ui/card.cjs +37 -0
- package/dist/components/ui/card.cjs.map +1 -0
- package/dist/components/ui/card.d.cts +18 -0
- package/dist/components/ui/card.d.ts +18 -0
- package/dist/components/ui/card.js +4 -0
- package/dist/components/ui/card.js.map +1 -0
- package/dist/components/ui/concept-card.cjs +18 -0
- package/dist/components/ui/concept-card.cjs.map +1 -0
- package/dist/components/ui/concept-card.d.cts +5 -0
- package/dist/components/ui/concept-card.d.ts +5 -0
- package/dist/components/ui/concept-card.js +9 -0
- package/dist/components/ui/concept-card.js.map +1 -0
- package/dist/components/ui/data-table.cjs +18 -0
- package/dist/components/ui/data-table.cjs.map +1 -0
- package/dist/components/ui/data-table.d.cts +181 -0
- package/dist/components/ui/data-table.d.ts +181 -0
- package/dist/components/ui/data-table.js +9 -0
- package/dist/components/ui/data-table.js.map +1 -0
- package/dist/components/ui/dialog.cjs +49 -0
- package/dist/components/ui/dialog.cjs.map +1 -0
- package/dist/components/ui/dialog.d.cts +22 -0
- package/dist/components/ui/dialog.d.ts +22 -0
- package/dist/components/ui/dialog.js +4 -0
- package/dist/components/ui/dialog.js.map +1 -0
- package/dist/components/ui/filter-provider.cjs +20 -0
- package/dist/components/ui/filter-provider.cjs.map +1 -0
- package/dist/components/ui/filter-provider.d.cts +49 -0
- package/dist/components/ui/filter-provider.d.ts +49 -0
- package/dist/components/ui/filter-provider.js +3 -0
- package/dist/components/ui/filter-provider.js.map +1 -0
- package/dist/components/ui/input.cjs +22 -0
- package/dist/components/ui/input.cjs.map +1 -0
- package/dist/components/ui/input.d.cts +16 -0
- package/dist/components/ui/input.d.ts +16 -0
- package/dist/components/ui/input.js +5 -0
- package/dist/components/ui/input.js.map +1 -0
- package/dist/components/ui/iran-province-heat.cjs +13 -0
- package/dist/components/ui/iran-province-heat.cjs.map +1 -0
- package/dist/components/ui/iran-province-heat.d.cts +64 -0
- package/dist/components/ui/iran-province-heat.d.ts +64 -0
- package/dist/components/ui/iran-province-heat.js +4 -0
- package/dist/components/ui/iran-province-heat.js.map +1 -0
- package/dist/components/ui/page-card.cjs +16 -0
- package/dist/components/ui/page-card.cjs.map +1 -0
- package/dist/components/ui/page-card.d.cts +6 -0
- package/dist/components/ui/page-card.d.ts +6 -0
- package/dist/components/ui/page-card.js +7 -0
- package/dist/components/ui/page-card.js.map +1 -0
- package/dist/components/ui/popover.cjs +25 -0
- package/dist/components/ui/popover.cjs.map +1 -0
- package/dist/components/ui/popover.d.cts +9 -0
- package/dist/components/ui/popover.d.ts +9 -0
- package/dist/components/ui/popover.js +4 -0
- package/dist/components/ui/popover.js.map +1 -0
- package/dist/components/ui/saved-query-card.cjs +15 -0
- package/dist/components/ui/saved-query-card.cjs.map +1 -0
- package/dist/components/ui/saved-query-card.d.cts +41 -0
- package/dist/components/ui/saved-query-card.d.ts +41 -0
- package/dist/components/ui/saved-query-card.js +6 -0
- package/dist/components/ui/saved-query-card.js.map +1 -0
- package/dist/components/ui/separator.cjs +13 -0
- package/dist/components/ui/separator.cjs.map +1 -0
- package/dist/components/ui/separator.d.cts +9 -0
- package/dist/components/ui/separator.d.ts +9 -0
- package/dist/components/ui/separator.js +4 -0
- package/dist/components/ui/separator.js.map +1 -0
- package/dist/components/ui/sheet.cjs +45 -0
- package/dist/components/ui/sheet.cjs.map +1 -0
- package/dist/components/ui/sheet.d.cts +44 -0
- package/dist/components/ui/sheet.d.ts +44 -0
- package/dist/components/ui/sheet.js +4 -0
- package/dist/components/ui/sheet.js.map +1 -0
- package/dist/components/ui/sparkline.cjs +13 -0
- package/dist/components/ui/sparkline.cjs.map +1 -0
- package/dist/components/ui/sparkline.d.cts +36 -0
- package/dist/components/ui/sparkline.d.ts +36 -0
- package/dist/components/ui/sparkline.js +4 -0
- package/dist/components/ui/sparkline.js.map +1 -0
- package/dist/components/ui/tooltip.cjs +25 -0
- package/dist/components/ui/tooltip.cjs.map +1 -0
- package/dist/components/ui/tooltip.d.cts +17 -0
- package/dist/components/ui/tooltip.d.ts +17 -0
- package/dist/components/ui/tooltip.js +4 -0
- package/dist/components/ui/tooltip.js.map +1 -0
- package/dist/concept-card-CcOBb2Nz.d.ts +83 -0
- package/dist/concept-card-RwPbqJ06.d.cts +83 -0
- package/dist/hooks/use-hotkey-registry.cjs +21 -0
- package/dist/hooks/use-hotkey-registry.cjs.map +1 -0
- package/dist/hooks/use-hotkey-registry.d.cts +65 -0
- package/dist/hooks/use-hotkey-registry.d.ts +65 -0
- package/dist/hooks/use-hotkey-registry.js +4 -0
- package/dist/hooks/use-hotkey-registry.js.map +1 -0
- package/dist/hooks/use-hotkeys.cjs +16 -0
- package/dist/hooks/use-hotkeys.cjs.map +1 -0
- package/dist/hooks/use-hotkeys.d.cts +66 -0
- package/dist/hooks/use-hotkeys.d.ts +66 -0
- package/dist/hooks/use-hotkeys.js +3 -0
- package/dist/hooks/use-hotkeys.js.map +1 -0
- package/dist/i18n-ArS3mqj0.d.ts +344 -0
- package/dist/i18n-CAd9wGOr.d.cts +344 -0
- package/dist/index.cjs +12195 -13224
- package/dist/index.cjs.map +1 -1
- package/dist/index.css +490 -34
- package/dist/index.d.cts +1635 -1263
- package/dist/index.d.ts +1635 -1263
- package/dist/index.js +10693 -12364
- package/dist/index.js.map +1 -1
- package/dist/page-card-CmShVqG-.d.cts +100 -0
- package/dist/page-card-HBn-cy4J.d.ts +100 -0
- package/dist/utils-DlXWmDZ-.d.cts +35 -0
- package/dist/utils-DlXWmDZ-.d.ts +35 -0
- package/package.json +160 -4
package/dist/index.d.cts
CHANGED
|
@@ -1,4 +1,7 @@
|
|
|
1
|
-
import {
|
|
1
|
+
import { S as SupportedLocale } from './utils-DlXWmDZ-.cjs';
|
|
2
|
+
export { c as cn, a as convertToLocalNumbers, e as formatAbsoluteTime, f as formatLargeNumber, b as formatNumber, d as formatRelativeTime } from './utils-DlXWmDZ-.cjs';
|
|
3
|
+
import { A as ActionStatusKey, a as ActionTypeKey, E as EntityHealthKey, J as JobStatusKey, b as EmotionKey, F as FlowKey, S as StageStatusKey, c as StatusKey, d as SeverityKey } from './i18n-CAd9wGOr.cjs';
|
|
4
|
+
export { p as ACTION_STATUS_KEYS, w as ACTION_TYPE_KEYS, f as EMOTION_KEYS, z as ENTITY_HEALTH_KEYS, h as FLOW_KEYS, m as JOB_STATUS_KEYS, L as Locale, u as STAGE_STATUS_KEYS, G as UIStringKeys, H as UIStrings, U as UI_STRINGS, q as actionStatusLabels, x as actionTypeLabels, y as actionTypeVerbs, g as emotionLabels, e as engagementUiTranslations, B as entityHealthLabels, C as entityHealthPriority, j as flowLabels, r as formatRelativeLocaleTime, t as formatTimeRemaining, I as getUIStrings, o as isActiveJobStatus, D as isCriticalEntityHealth, i as isRTL, n as jobStatusLabels, s as sentimentLabels, l as severityLabels, v as stageStatusLabels, k as statusLabels } from './i18n-CAd9wGOr.cjs';
|
|
2
5
|
import * as React$1 from 'react';
|
|
3
6
|
import { LucideIcon } from 'lucide-react';
|
|
4
7
|
import * as react_jsx_runtime from 'react/jsx-runtime';
|
|
@@ -6,34 +9,54 @@ import * as AccordionPrimitive from '@radix-ui/react-accordion';
|
|
|
6
9
|
import * as class_variance_authority_types from 'class-variance-authority/types';
|
|
7
10
|
import { VariantProps } from 'class-variance-authority';
|
|
8
11
|
import * as AlertDialogPrimitive from '@radix-ui/react-alert-dialog';
|
|
12
|
+
export { AlertChannel, AlertRuleCard, AlertRuleCardProps } from './components/ui/alert-rule-card.cjs';
|
|
9
13
|
import * as AspectRatioPrimitive from '@radix-ui/react-aspect-ratio';
|
|
10
|
-
|
|
11
|
-
|
|
12
|
-
import {
|
|
13
|
-
|
|
14
|
+
export { Avatar, AvatarFallback, AvatarImage } from './components/ui/avatar.cjs';
|
|
15
|
+
export { Badge, BadgeProps, badgeVariants } from './components/ui/badge.cjs';
|
|
16
|
+
import { Button, ButtonProps } from './components/ui/button.cjs';
|
|
17
|
+
export { ButtonVariantProps, LoadingVariantProps, buttonVariants } from './components/ui/button.cjs';
|
|
18
|
+
import { Separator } from './components/ui/separator.cjs';
|
|
19
|
+
export { Calendar, CalendarProps } from './components/ui/calendar.cjs';
|
|
20
|
+
export { Card, CardContent, CardDescription, CardFooter, CardHeader, CardProps, CardTitle, cardVariants } from './components/ui/card.cjs';
|
|
14
21
|
import useEmblaCarousel, { UseEmblaCarouselType } from 'embla-carousel-react';
|
|
15
22
|
import * as CheckboxPrimitive from '@radix-ui/react-checkbox';
|
|
16
23
|
import * as CollapsiblePrimitive from '@radix-ui/react-collapsible';
|
|
17
24
|
import { Command as Command$1 } from 'cmdk';
|
|
18
|
-
import
|
|
25
|
+
import { Dialog } from './components/ui/dialog.cjs';
|
|
26
|
+
export { DialogClose, DialogContent, DialogDescription, DialogFooter, DialogHeader, DialogOverlay, DialogPortal, DialogTitle, DialogTrigger } from './components/ui/dialog.cjs';
|
|
27
|
+
import { HotkeyCombo } from './hooks/use-hotkeys.cjs';
|
|
28
|
+
export { UseHotkeysOptions, formatHotkey, useHotkeys } from './hooks/use-hotkeys.cjs';
|
|
19
29
|
import * as ContextMenuPrimitive from '@radix-ui/react-context-menu';
|
|
30
|
+
import { S as SentimentData, F as FlowData } from './concept-card-RwPbqJ06.cjs';
|
|
31
|
+
export { C as ConceptCard, a as ConceptCardProps, b as FlowDistribution, c as FlowDistributionProps, d as SentimentDistribution, e as SentimentDistributionProps } from './concept-card-RwPbqJ06.cjs';
|
|
32
|
+
import { DateRange } from 'react-day-picker';
|
|
20
33
|
import { Drawer as Drawer$1 } from 'vaul';
|
|
21
34
|
import * as DropdownMenuPrimitive from '@radix-ui/react-dropdown-menu';
|
|
22
35
|
import * as LabelPrimitive from '@radix-ui/react-label';
|
|
36
|
+
import { FilterStateShape } from './components/ui/filter-provider.cjs';
|
|
37
|
+
export { FilterContextValue, FilterProvider, FilterProviderProps, useFilterState, useFilterStateOptional } from './components/ui/filter-provider.cjs';
|
|
23
38
|
import * as react_hook_form from 'react-hook-form';
|
|
24
39
|
import { FieldValues, FieldPath, ControllerProps } from 'react-hook-form';
|
|
25
40
|
import { Slot } from '@radix-ui/react-slot';
|
|
26
41
|
import * as HoverCardPrimitive from '@radix-ui/react-hover-card';
|
|
42
|
+
import { InputProps, Input, InputVariants } from './components/ui/input.cjs';
|
|
43
|
+
export { inputVariants } from './components/ui/input.cjs';
|
|
44
|
+
export { IranProvinceCell, IranProvinceHeat, IranProvinceHeatProps, IranProvinceHeatScale } from './components/ui/iran-province-heat.cjs';
|
|
27
45
|
import { OTPInput } from 'input-otp';
|
|
28
46
|
import * as MenubarPrimitive from '@radix-ui/react-menubar';
|
|
29
47
|
import * as NavigationMenuPrimitive from '@radix-ui/react-navigation-menu';
|
|
30
|
-
import
|
|
48
|
+
import { S as SocialPlatform } from './page-card-CmShVqG-.cjs';
|
|
49
|
+
export { f as BotDetectionData, e as BotDetectionKey, B as BotDetectionMeter, g as BotDetectionMeterProps, P as PageCard, a as PageCardContentMix, b as PageCardProps, c as SocialPlatformBadge, d as SocialPlatformBadgeProps, s as socialPlatformBadgeVariants } from './page-card-CmShVqG-.cjs';
|
|
50
|
+
export { Popover, PopoverAnchor, PopoverContent, PopoverTrigger } from './components/ui/popover.cjs';
|
|
31
51
|
import * as ProgressPrimitive from '@radix-ui/react-progress';
|
|
32
52
|
import * as RadioGroupPrimitive from '@radix-ui/react-radio-group';
|
|
33
53
|
import * as ResizablePrimitive from 'react-resizable-panels';
|
|
34
54
|
import * as ScrollAreaPrimitive from '@radix-ui/react-scroll-area';
|
|
35
55
|
import * as SelectPrimitive from '@radix-ui/react-select';
|
|
36
|
-
|
|
56
|
+
export { Sheet, SheetBody, SheetClose, SheetContent, SheetDescription, SheetFooter, SheetHeader, SheetTitle, SheetTrigger } from './components/ui/sheet.cjs';
|
|
57
|
+
import { TooltipContent } from './components/ui/tooltip.cjs';
|
|
58
|
+
export { Tooltip, TooltipProvider, TooltipTrigger } from './components/ui/tooltip.cjs';
|
|
59
|
+
export { Sparkline, SparklineProps, SparklineTrend, SparklineVariant } from './components/ui/sparkline.cjs';
|
|
37
60
|
import * as SliderPrimitive from '@radix-ui/react-slider';
|
|
38
61
|
import { ToasterProps } from 'sonner';
|
|
39
62
|
export { toast } from 'sonner';
|
|
@@ -41,38 +64,22 @@ import * as SwitchPrimitive from '@radix-ui/react-switch';
|
|
|
41
64
|
import * as TabsPrimitive from '@radix-ui/react-tabs';
|
|
42
65
|
import * as TogglePrimitive from '@radix-ui/react-toggle';
|
|
43
66
|
import * as ToggleGroupPrimitive from '@radix-ui/react-toggle-group';
|
|
44
|
-
|
|
45
|
-
|
|
46
|
-
|
|
47
|
-
|
|
48
|
-
|
|
49
|
-
|
|
50
|
-
|
|
51
|
-
|
|
52
|
-
|
|
53
|
-
|
|
54
|
-
|
|
55
|
-
|
|
56
|
-
|
|
57
|
-
|
|
58
|
-
|
|
59
|
-
|
|
60
|
-
* Format number to Instagram-style short format (English only).
|
|
61
|
-
* @example formatNumber(123456, 'short') => '123K'
|
|
62
|
-
* @example formatNumber(123456, 'exact') => '123,456'
|
|
63
|
-
*/
|
|
64
|
-
declare function formatNumber(num: number | undefined, format?: 'exact' | 'short'): string;
|
|
65
|
-
/**
|
|
66
|
-
* Format date to relative time with absolute on hover (Persian)
|
|
67
|
-
* @example formatRelativeTime(new Date()) => '۲ ساعت پیش'
|
|
68
|
-
*/
|
|
69
|
-
declare function formatRelativeTime(date: Date | string | number): string;
|
|
70
|
-
/**
|
|
71
|
-
* Format date to absolute format (Persian / Jalali)
|
|
72
|
-
* Uses date-fns-jalali for accurate Jalali conversion.
|
|
73
|
-
* @example formatAbsoluteTime(new Date()) => '۱۵ دی ۱۴۰۳، ۱۵:۳۰'
|
|
74
|
-
*/
|
|
75
|
-
declare function formatAbsoluteTime(date: Date | string | number): string;
|
|
67
|
+
import { DataTableColumn, DataTableColumnVisibility } from './components/ui/data-table.cjs';
|
|
68
|
+
export { DataTable, DataTableExpansion, DataTableMultiSort, DataTablePagination, DataTableProps, DataTableSelection, DataTableSort, SortDirection, SortRule } from './components/ui/data-table.cjs';
|
|
69
|
+
export { SavedQueryCard, SavedQueryCardProps, SavedQueryFilter } from './components/ui/saved-query-card.cjs';
|
|
70
|
+
export { PartoLineChart, PartoLineChartProps } from './components/charts/PartoLineChart.cjs';
|
|
71
|
+
export { PartoBarChart, PartoBarChartProps } from './components/charts/PartoBarChart.cjs';
|
|
72
|
+
export { PartoPieChart, PartoPieChartProps } from './components/charts/PartoPieChart.cjs';
|
|
73
|
+
export { PartoAreaChart, PartoAreaChartProps } from './components/charts/PartoAreaChart.cjs';
|
|
74
|
+
import { RegisteredHotkey } from './hooks/use-hotkey-registry.cjs';
|
|
75
|
+
export { HotkeyProvider, HotkeyProviderProps, useHotkey, useHotkeyRegistry } from './hooks/use-hotkey-registry.cjs';
|
|
76
|
+
import 'clsx';
|
|
77
|
+
import '@radix-ui/react-avatar';
|
|
78
|
+
import '@radix-ui/react-separator';
|
|
79
|
+
import 'react-day-picker/persian';
|
|
80
|
+
import '@radix-ui/react-dialog';
|
|
81
|
+
import '@radix-ui/react-popover';
|
|
82
|
+
import '@radix-ui/react-tooltip';
|
|
76
83
|
|
|
77
84
|
/**
|
|
78
85
|
* Persian (Jalali / Solar Hijri) calendar utilities.
|
|
@@ -201,346 +208,66 @@ declare function getFollowerGroup(followers: number): FollowerGroup;
|
|
|
201
208
|
declare function getEngagementRanges(followers: number, locale: SupportedLocale): EngagementRangeWithDisplay[];
|
|
202
209
|
declare function getCurrentRangeIndex(currentRate: number, ranges: EngagementRange[]): number;
|
|
203
210
|
|
|
204
|
-
type Locale = SupportedLocale;
|
|
205
|
-
/**
|
|
206
|
-
* Returns true for RTL locales (fa, ar).
|
|
207
|
-
*/
|
|
208
|
-
declare function isRTL(locale: SupportedLocale): boolean;
|
|
209
|
-
/**
|
|
210
|
-
* UI string translations used by the EngagementRate component.
|
|
211
|
-
* Centralised here to avoid duplication between components.
|
|
212
|
-
*/
|
|
213
|
-
declare const engagementUiTranslations: Record<SupportedLocale, {
|
|
214
|
-
yourCategory: string;
|
|
215
|
-
influencer: string;
|
|
216
|
-
followers: string;
|
|
217
|
-
over: string;
|
|
218
|
-
to: string;
|
|
219
|
-
and: string;
|
|
220
|
-
lessThan: string;
|
|
221
|
-
you: string;
|
|
222
|
-
criteria: string;
|
|
223
|
-
}>;
|
|
224
|
-
/**
|
|
225
|
-
* Sentiment label translations used by the SentimentBadge component.
|
|
226
|
-
*/
|
|
227
|
-
declare const sentimentLabels: Record<SupportedLocale, {
|
|
228
|
-
positive: string;
|
|
229
|
-
negative: string;
|
|
230
|
-
neutral: string;
|
|
231
|
-
mixed: string;
|
|
232
|
-
}>;
|
|
233
|
-
/**
|
|
234
|
-
* Canonical emotion keys — 9-class advanced sentiment scale used in افکارسنجی
|
|
235
|
-
* deep analysis. Coexists with the simple 3-class `Sentiment` above; they are
|
|
236
|
-
* NOT interchangeable. Choose the scale based on view density.
|
|
237
|
-
*/
|
|
238
|
-
type EmotionKey = 'anger' | 'anticipation' | 'joy' | 'trust' | 'fear' | 'surprise' | 'sadness' | 'disgust' | 'neutral';
|
|
239
|
-
declare const EMOTION_KEYS: readonly EmotionKey[];
|
|
240
|
-
/** Emotion label translations used by EmotionBadge / EmotionDistribution. */
|
|
241
|
-
declare const emotionLabels: Record<SupportedLocale, Record<EmotionKey, string>>;
|
|
242
|
-
/**
|
|
243
|
-
* Political flow keys — 5-class classification used in افکارسنجی clustering.
|
|
244
|
-
* A concept / post / page belongs to exactly one flow (primary) but usually
|
|
245
|
-
* also has secondary flow composition expressed as percentages.
|
|
246
|
-
*/
|
|
247
|
-
type FlowKey = 'pro-gov' | 'internal-critic' | 'internal-opponent' | 'external-opponent' | 'grey';
|
|
248
|
-
declare const FLOW_KEYS: readonly FlowKey[];
|
|
249
|
-
declare const flowLabels: Record<SupportedLocale, Record<FlowKey, string>>;
|
|
250
|
-
/** Operational status — visual state of a tracked entity. */
|
|
251
|
-
type StatusKey = 'critical' | 'warning' | 'normal';
|
|
252
|
-
declare const statusLabels: Record<SupportedLocale, Record<StatusKey, string>>;
|
|
253
|
-
/** Severity — urgency level. Independent from status. */
|
|
254
|
-
type SeverityKey = 'urgent' | 'high' | 'medium' | 'low';
|
|
255
|
-
declare const severityLabels: Record<SupportedLocale, Record<SeverityKey, string>>;
|
|
256
|
-
/**
|
|
257
|
-
* Job lifecycle — canonical states for async work (analyses, campaigns,
|
|
258
|
-
* evaluation runs, imports, exports, report generation).
|
|
259
|
-
*
|
|
260
|
-
* Terminal states: completed / failed / cancelled.
|
|
261
|
-
* Active states: queued / running / paused.
|
|
262
|
-
*/
|
|
263
|
-
type JobStatusKey = 'queued' | 'running' | 'paused' | 'completed' | 'failed' | 'cancelled';
|
|
264
|
-
declare const JOB_STATUS_KEYS: readonly JobStatusKey[];
|
|
265
|
-
declare const jobStatusLabels: Record<SupportedLocale, Record<JobStatusKey, string>>;
|
|
266
|
-
/** True iff a job is still active (not in a terminal state). */
|
|
267
|
-
declare function isActiveJobStatus(s: JobStatusKey): boolean;
|
|
268
|
-
/**
|
|
269
|
-
* Action status — discrete outcome for a single completed (or in-flight)
|
|
270
|
-
* action in an activity feed / audit timeline. Distinct from the richer
|
|
271
|
-
* job/stage lifecycles above: each event is atomic, so no "paused" here.
|
|
272
|
-
*/
|
|
273
|
-
type ActionStatusKey = 'success' | 'failed' | 'pending' | 'warning' | 'info';
|
|
274
|
-
declare const ACTION_STATUS_KEYS: readonly ActionStatusKey[];
|
|
275
|
-
declare const actionStatusLabels: Record<SupportedLocale, Record<ActionStatusKey, string>>;
|
|
276
|
-
/**
|
|
277
|
-
* Locale-aware relative time label producer. Used by ActionTimeline and any
|
|
278
|
-
* other component that wants trilingual "n minutes ago" strings. For absolute
|
|
279
|
-
* formatting see `formatAbsoluteTime`/`formatJalaliDate` in lib/utils.ts.
|
|
280
|
-
*/
|
|
281
|
-
declare function formatRelativeLocaleTime(date: Date | string | number, locale: SupportedLocale): string;
|
|
282
|
-
/**
|
|
283
|
-
* Locale-aware "time remaining" label — forward-looking companion to
|
|
284
|
-
* `formatRelativeLocaleTime`. Used by RateLimitBanner and any countdown UI.
|
|
285
|
-
*
|
|
286
|
-
* Input can be a Date, ISO string, or epoch ms. Past/zero remaining returns
|
|
287
|
-
* the locale-specific "now" / "any moment" marker.
|
|
288
|
-
*/
|
|
289
|
-
declare function formatTimeRemaining(target: Date | string | number, locale: SupportedLocale): string;
|
|
290
211
|
/**
|
|
291
|
-
*
|
|
212
|
+
* Iran's 31 provinces with trilingual labels and ISO 3166-2 codes.
|
|
292
213
|
*
|
|
293
|
-
*
|
|
294
|
-
*
|
|
295
|
-
*
|
|
296
|
-
|
|
297
|
-
type StageStatusKey = 'pending' | 'running' | 'completed' | 'failed' | 'skipped' | 'warning' | 'paused';
|
|
298
|
-
declare const STAGE_STATUS_KEYS: readonly StageStatusKey[];
|
|
299
|
-
declare const stageStatusLabels: Record<SupportedLocale, Record<StageStatusKey, string>>;
|
|
300
|
-
/**
|
|
301
|
-
* Action type — canonical set of social-media actions a worker/user can
|
|
302
|
-
* execute. Maps 1:1 to a CSS token family (`--action-type-*`) so each action
|
|
303
|
-
* has a distinct recognizable colour + icon across activity feeds, audit
|
|
304
|
-
* timelines, and rate-limit dashboards.
|
|
214
|
+
* Use as a stable identifier source for `IranProvinceHeat`, `RegionPicker`,
|
|
215
|
+
* and any public-opinion dashboard scoped by استان. The slug (`code`) is the
|
|
216
|
+
* canonical key — never rely on label string equality, since labels are
|
|
217
|
+
* locale-dependent and may evolve.
|
|
305
218
|
*
|
|
306
|
-
*
|
|
307
|
-
*
|
|
308
|
-
*
|
|
309
|
-
* - `share` — cross-post / retweet (future multi-platform)
|
|
219
|
+
* Codes follow ISO 3166-2:IR (e.g. 'IR-07' for Tehran). The slug is the
|
|
220
|
+
* lowercased, hyphenated English name without diacritics, suitable for URLs
|
|
221
|
+
* and CSS selectors. Use `getProvinceLabel(code, locale)` to resolve a label.
|
|
310
222
|
*/
|
|
311
|
-
|
|
312
|
-
|
|
313
|
-
|
|
223
|
+
|
|
224
|
+
interface IranProvince {
|
|
225
|
+
/** Stable URL-safe slug. The canonical key for province lookups. */
|
|
226
|
+
slug: string;
|
|
227
|
+
/** ISO 3166-2:IR code (e.g. 'IR-07'). */
|
|
228
|
+
iso: string;
|
|
229
|
+
/** Trilingual labels — fa is the canonical/native form. */
|
|
230
|
+
labels: Record<SupportedLocale, string>;
|
|
231
|
+
}
|
|
232
|
+
declare const IRAN_PROVINCES: readonly IranProvince[];
|
|
233
|
+
type IranProvinceSlug = (typeof IRAN_PROVINCES)[number]['slug'];
|
|
234
|
+
/** Look up a province by slug or ISO code. Returns undefined for unknown codes. */
|
|
235
|
+
declare function findProvince(codeOrSlug: string): IranProvince | undefined;
|
|
314
236
|
/**
|
|
315
|
-
*
|
|
316
|
-
*
|
|
317
|
-
*
|
|
237
|
+
* Resolve the locale-appropriate label for a province slug or ISO code.
|
|
238
|
+
* Falls back to fa for unknown locales and to the slug itself for unknown
|
|
239
|
+
* provinces (so the row still renders something instead of crashing).
|
|
318
240
|
*/
|
|
319
|
-
declare
|
|
241
|
+
declare function getProvinceLabel(codeOrSlug: string, locale?: SupportedLocale): string;
|
|
242
|
+
|
|
320
243
|
/**
|
|
321
|
-
*
|
|
322
|
-
* workers, tracked pages, data sources, monitored feeds. Ordered most-critical
|
|
323
|
-
* to most-positive so components can sort "worst first" deterministically.
|
|
244
|
+
* Curated country list with trilingual labels + flag emoji.
|
|
324
245
|
*
|
|
325
|
-
*
|
|
326
|
-
*
|
|
327
|
-
*
|
|
328
|
-
*
|
|
329
|
-
*
|
|
330
|
-
* `healthy` — stable, all checks pass.
|
|
246
|
+
* Scope: ISO 3166-1 alpha-2 codes for ~80 countries that recur in افکارسنجی
|
|
247
|
+
* and influencer dashboards we serve — neighbors of Iran, the Gulf, MENA,
|
|
248
|
+
* major Western markets, and Asian/African markets relevant to Persian-
|
|
249
|
+
* speaking audiences. The flag emoji is the regional-indicator pair for the
|
|
250
|
+
* code; modern OS fonts render it as a flag.
|
|
331
251
|
*
|
|
332
|
-
*
|
|
333
|
-
*
|
|
334
|
-
|
|
335
|
-
type EntityHealthKey = 'banned' | 'pending' | 'at-risk' | 'warning' | 'growing' | 'healthy';
|
|
336
|
-
declare const ENTITY_HEALTH_KEYS: readonly EntityHealthKey[];
|
|
337
|
-
declare const entityHealthLabels: Record<SupportedLocale, Record<EntityHealthKey, string>>;
|
|
338
|
-
/**
|
|
339
|
-
* Priority rank of each entity health state — higher number = more severe.
|
|
340
|
-
* Use to sort entity lists "worst first" without ad-hoc comparisons.
|
|
341
|
-
*/
|
|
342
|
-
declare const entityHealthPriority: Record<EntityHealthKey, number>;
|
|
343
|
-
/** True iff the entity needs immediate human attention. */
|
|
344
|
-
declare function isCriticalEntityHealth(s: EntityHealthKey): boolean;
|
|
345
|
-
/**
|
|
346
|
-
* Default UI strings for components that need localized text.
|
|
347
|
-
* Persian (fa) is the default locale for backward compatibility.
|
|
348
|
-
*/
|
|
349
|
-
declare const UI_STRINGS: {
|
|
350
|
-
readonly fa: {
|
|
351
|
-
readonly noResults: "نتیجهای یافت نشد";
|
|
352
|
-
readonly suggestions: "پیشنهادها";
|
|
353
|
-
readonly select: "انتخاب کنید";
|
|
354
|
-
readonly noOptionsFound: "موردی یافت نشد";
|
|
355
|
-
readonly search: "جستجو...";
|
|
356
|
-
readonly clearAll: "پاک کردن همه";
|
|
357
|
-
readonly selectDate: "انتخاب تاریخ";
|
|
358
|
-
readonly selectDateRange: "انتخاب بازه تاریخ";
|
|
359
|
-
readonly errorLoadingData: "خطا در بارگذاری دادهها";
|
|
360
|
-
readonly retry: "تلاش مجدد";
|
|
361
|
-
readonly remove: "حذف";
|
|
362
|
-
readonly noUsersFound: "کاربری یافت نشد";
|
|
363
|
-
readonly goToPreviousPage: "رفتن به صفحه قبلی";
|
|
364
|
-
readonly goToNextPage: "رفتن به صفحه بعدی";
|
|
365
|
-
readonly previous: "قبلی";
|
|
366
|
-
readonly next: "بعدی";
|
|
367
|
-
readonly actions: "عملیات";
|
|
368
|
-
readonly copy: "کپی";
|
|
369
|
-
readonly copied: "کپی شد";
|
|
370
|
-
readonly confirm: "تایید";
|
|
371
|
-
readonly cancel: "انصراف";
|
|
372
|
-
readonly areYouSure: "آیا مطمئن هستید؟";
|
|
373
|
-
readonly stepperLabel: "مراحل";
|
|
374
|
-
readonly stepCompleted: "تکمیل شده";
|
|
375
|
-
readonly stepCurrent: "مرحله فعلی";
|
|
376
|
-
readonly stepPending: "در انتظار";
|
|
377
|
-
readonly clearFilters: "پاک کردن فیلترها";
|
|
378
|
-
readonly activeFilters: "فیلترهای فعال";
|
|
379
|
-
readonly filters: "فیلترها";
|
|
380
|
-
readonly applyFilters: "اعمال";
|
|
381
|
-
readonly resetFilters: "پیشفرض";
|
|
382
|
-
readonly noFiltersActive: "فیلتر فعالی نیست";
|
|
383
|
-
readonly clearSection: "پاک کردن این بخش";
|
|
384
|
-
readonly goBack: "بازگشت";
|
|
385
|
-
readonly gridView: "نمای شبکهای";
|
|
386
|
-
readonly listView: "نمای لیستی";
|
|
387
|
-
readonly loading: "در حال بارگذاری...";
|
|
388
|
-
readonly unexpectedError: "خطای غیرمنتظرهای رخ داد";
|
|
389
|
-
readonly selectAll: "انتخاب همه";
|
|
390
|
-
readonly selectRow: "انتخاب ردیف";
|
|
391
|
-
readonly noDataToDisplay: "دادهای برای نمایش وجود ندارد";
|
|
392
|
-
readonly likesCount: "تعداد لایک";
|
|
393
|
-
readonly commentsCount: "تعداد کامنت";
|
|
394
|
-
readonly viewsCount: "تعداد بازدید";
|
|
395
|
-
readonly sharesCount: "تعداد اشتراک";
|
|
396
|
-
readonly postTypeLabel: "نوع پست";
|
|
397
|
-
readonly postTypePhoto: "عکس";
|
|
398
|
-
readonly postTypeVideo: "ویدیو";
|
|
399
|
-
readonly postTypeCarousel: "اسلاید";
|
|
400
|
-
readonly showMore: "بیشتر";
|
|
401
|
-
readonly showLess: "کمتر";
|
|
402
|
-
readonly noMediaAvailable: "رسانهای موجود نیست";
|
|
403
|
-
readonly commentAnalysis: "تحلیل کامنتها";
|
|
404
|
-
readonly commentAnalysisDisabled: "تحلیل کامنتها (غیرفعال)";
|
|
405
|
-
readonly booster: "بوستر";
|
|
406
|
-
readonly boosterDisabled: "بوستر (غیرفعال)";
|
|
407
|
-
readonly aiAnalysis: "تحلیل هوش مصنوعی";
|
|
408
|
-
readonly aiAnalysisDisabled: "تحلیل هوش مصنوعی (غیرفعال)";
|
|
409
|
-
readonly openOnInstagram: "باز کردن در اینستاگرام";
|
|
410
|
-
readonly openOnInstagramDisabled: "باز کردن در اینستاگرام (غیرفعال)";
|
|
411
|
-
};
|
|
412
|
-
readonly ar: {
|
|
413
|
-
readonly noResults: "لم يتم العثور على نتائج";
|
|
414
|
-
readonly suggestions: "اقتراحات";
|
|
415
|
-
readonly select: "اختر";
|
|
416
|
-
readonly noOptionsFound: "لم يتم العثور على خيارات";
|
|
417
|
-
readonly search: "بحث...";
|
|
418
|
-
readonly clearAll: "مسح الكل";
|
|
419
|
-
readonly selectDate: "اختر تاريخ";
|
|
420
|
-
readonly selectDateRange: "اختر نطاق التاريخ";
|
|
421
|
-
readonly errorLoadingData: "خطأ في تحميل البيانات";
|
|
422
|
-
readonly retry: "إعادة المحاولة";
|
|
423
|
-
readonly remove: "حذف";
|
|
424
|
-
readonly noUsersFound: "لم يتم العثور على مستخدمين";
|
|
425
|
-
readonly goToPreviousPage: "الانتقال إلى الصفحة السابقة";
|
|
426
|
-
readonly goToNextPage: "الانتقال إلى الصفحة التالية";
|
|
427
|
-
readonly previous: "السابق";
|
|
428
|
-
readonly next: "التالي";
|
|
429
|
-
readonly actions: "إجراءات";
|
|
430
|
-
readonly copy: "نسخ";
|
|
431
|
-
readonly copied: "تم النسخ";
|
|
432
|
-
readonly confirm: "تأكيد";
|
|
433
|
-
readonly cancel: "إلغاء";
|
|
434
|
-
readonly areYouSure: "هل أنت متأكد؟";
|
|
435
|
-
readonly stepperLabel: "الخطوات";
|
|
436
|
-
readonly stepCompleted: "مكتمل";
|
|
437
|
-
readonly stepCurrent: "الخطوة الحالية";
|
|
438
|
-
readonly stepPending: "قيد الانتظار";
|
|
439
|
-
readonly clearFilters: "مسح الفلاتر";
|
|
440
|
-
readonly activeFilters: "الفلاتر النشطة";
|
|
441
|
-
readonly filters: "الفلاتر";
|
|
442
|
-
readonly applyFilters: "تطبيق";
|
|
443
|
-
readonly resetFilters: "الافتراضي";
|
|
444
|
-
readonly noFiltersActive: "لا توجد فلاتر نشطة";
|
|
445
|
-
readonly clearSection: "مسح هذا القسم";
|
|
446
|
-
readonly goBack: "رجوع";
|
|
447
|
-
readonly gridView: "عرض شبكي";
|
|
448
|
-
readonly listView: "عرض قائمة";
|
|
449
|
-
readonly loading: "جارٍ التحميل...";
|
|
450
|
-
readonly unexpectedError: "حدث خطأ غير متوقع";
|
|
451
|
-
readonly selectAll: "تحديد الكل";
|
|
452
|
-
readonly selectRow: "تحديد الصف";
|
|
453
|
-
readonly noDataToDisplay: "لا توجد بيانات للعرض";
|
|
454
|
-
readonly likesCount: "عدد الإعجابات";
|
|
455
|
-
readonly commentsCount: "عدد التعليقات";
|
|
456
|
-
readonly viewsCount: "عدد المشاهدات";
|
|
457
|
-
readonly sharesCount: "عدد المشاركات";
|
|
458
|
-
readonly postTypeLabel: "نوع المنشور";
|
|
459
|
-
readonly postTypePhoto: "صورة";
|
|
460
|
-
readonly postTypeVideo: "فيديو";
|
|
461
|
-
readonly postTypeCarousel: "شرائح";
|
|
462
|
-
readonly showMore: "المزيد";
|
|
463
|
-
readonly showLess: "أقل";
|
|
464
|
-
readonly noMediaAvailable: "لا توجد وسائط";
|
|
465
|
-
readonly commentAnalysis: "تحليل التعليقات";
|
|
466
|
-
readonly commentAnalysisDisabled: "تحليل التعليقات (معطل)";
|
|
467
|
-
readonly booster: "تعزيز";
|
|
468
|
-
readonly boosterDisabled: "تعزيز (معطل)";
|
|
469
|
-
readonly aiAnalysis: "تحليل الذكاء الاصطناعي";
|
|
470
|
-
readonly aiAnalysisDisabled: "تحليل الذكاء الاصطناعي (معطل)";
|
|
471
|
-
readonly openOnInstagram: "فتح في إنستاجرام";
|
|
472
|
-
readonly openOnInstagramDisabled: "فتح في إنستاجرام (معطل)";
|
|
473
|
-
};
|
|
474
|
-
readonly en: {
|
|
475
|
-
readonly noResults: "No results found";
|
|
476
|
-
readonly suggestions: "Suggestions";
|
|
477
|
-
readonly select: "Select";
|
|
478
|
-
readonly noOptionsFound: "No options found";
|
|
479
|
-
readonly search: "Search...";
|
|
480
|
-
readonly clearAll: "Clear all";
|
|
481
|
-
readonly selectDate: "Select date";
|
|
482
|
-
readonly selectDateRange: "Select date range";
|
|
483
|
-
readonly errorLoadingData: "Error loading data";
|
|
484
|
-
readonly retry: "Retry";
|
|
485
|
-
readonly remove: "Remove";
|
|
486
|
-
readonly noUsersFound: "No users found";
|
|
487
|
-
readonly goToPreviousPage: "Go to previous page";
|
|
488
|
-
readonly goToNextPage: "Go to next page";
|
|
489
|
-
readonly previous: "Previous";
|
|
490
|
-
readonly next: "Next";
|
|
491
|
-
readonly actions: "Actions";
|
|
492
|
-
readonly copy: "Copy";
|
|
493
|
-
readonly copied: "Copied";
|
|
494
|
-
readonly confirm: "Confirm";
|
|
495
|
-
readonly cancel: "Cancel";
|
|
496
|
-
readonly areYouSure: "Are you sure?";
|
|
497
|
-
readonly stepperLabel: "Steps";
|
|
498
|
-
readonly stepCompleted: "Completed";
|
|
499
|
-
readonly stepCurrent: "Current step";
|
|
500
|
-
readonly stepPending: "Pending";
|
|
501
|
-
readonly clearFilters: "Clear filters";
|
|
502
|
-
readonly activeFilters: "Active filters";
|
|
503
|
-
readonly filters: "Filters";
|
|
504
|
-
readonly applyFilters: "Apply";
|
|
505
|
-
readonly resetFilters: "Reset";
|
|
506
|
-
readonly noFiltersActive: "No active filters";
|
|
507
|
-
readonly clearSection: "Clear this section";
|
|
508
|
-
readonly goBack: "Go back";
|
|
509
|
-
readonly gridView: "Grid view";
|
|
510
|
-
readonly listView: "List view";
|
|
511
|
-
readonly loading: "Loading...";
|
|
512
|
-
readonly unexpectedError: "An unexpected error occurred";
|
|
513
|
-
readonly selectAll: "Select all";
|
|
514
|
-
readonly selectRow: "Select row";
|
|
515
|
-
readonly noDataToDisplay: "No data to display";
|
|
516
|
-
readonly likesCount: "Likes";
|
|
517
|
-
readonly commentsCount: "Comments";
|
|
518
|
-
readonly viewsCount: "Views";
|
|
519
|
-
readonly sharesCount: "Shares";
|
|
520
|
-
readonly postTypeLabel: "Post type";
|
|
521
|
-
readonly postTypePhoto: "Photo";
|
|
522
|
-
readonly postTypeVideo: "Video";
|
|
523
|
-
readonly postTypeCarousel: "Carousel";
|
|
524
|
-
readonly showMore: "More";
|
|
525
|
-
readonly showLess: "Less";
|
|
526
|
-
readonly noMediaAvailable: "No media available";
|
|
527
|
-
readonly commentAnalysis: "Comment Analysis";
|
|
528
|
-
readonly commentAnalysisDisabled: "Comment Analysis (disabled)";
|
|
529
|
-
readonly booster: "Booster";
|
|
530
|
-
readonly boosterDisabled: "Booster (disabled)";
|
|
531
|
-
readonly aiAnalysis: "AI Analysis";
|
|
532
|
-
readonly aiAnalysisDisabled: "AI Analysis (disabled)";
|
|
533
|
-
readonly openOnInstagram: "Open on Instagram";
|
|
534
|
-
readonly openOnInstagramDisabled: "Open on Instagram (disabled)";
|
|
535
|
-
};
|
|
536
|
-
};
|
|
537
|
-
type UIStringKeys = keyof (typeof UI_STRINGS)['fa'];
|
|
538
|
-
type UIStrings = Record<UIStringKeys, string>;
|
|
539
|
-
/**
|
|
540
|
-
* Get UI strings for a given locale.
|
|
541
|
-
* Falls back to 'fa' for unknown locales.
|
|
252
|
+
* This is NOT an exhaustive ISO 3166 dataset — for country-level analytics
|
|
253
|
+
* outside this scope, consumers should pass their own list to `CountryPicker`
|
|
254
|
+
* via the `options` prop.
|
|
542
255
|
*/
|
|
543
|
-
|
|
256
|
+
|
|
257
|
+
interface Country {
|
|
258
|
+
/** ISO 3166-1 alpha-2 code (uppercase). The canonical key. */
|
|
259
|
+
code: string;
|
|
260
|
+
/** Trilingual labels — fa is the canonical/native form. */
|
|
261
|
+
labels: Record<SupportedLocale, string>;
|
|
262
|
+
}
|
|
263
|
+
/** Convert an ISO 3166-1 alpha-2 code to its flag-emoji pair. */
|
|
264
|
+
declare function countryFlag(code: string): string;
|
|
265
|
+
declare const COUNTRIES: readonly Country[];
|
|
266
|
+
type CountryCode = (typeof COUNTRIES)[number]['code'];
|
|
267
|
+
/** Look up a country by ISO 3166-1 alpha-2 code. Returns undefined for unknown codes. */
|
|
268
|
+
declare function findCountry(code: string): Country | undefined;
|
|
269
|
+
/** Resolve the locale-appropriate label for a country code. */
|
|
270
|
+
declare function getCountryLabel(code: string, locale: SupportedLocale): string;
|
|
544
271
|
|
|
545
272
|
/**
|
|
546
273
|
* Standard size scale used across the design system.
|
|
@@ -689,38 +416,6 @@ declare function AlertDialogDescription({ className, ...props }: React$1.Compone
|
|
|
689
416
|
declare const AlertDialogAction: React$1.ForwardRefExoticComponent<Omit<AlertDialogPrimitive.AlertDialogActionProps & React$1.RefAttributes<HTMLButtonElement>, "ref"> & React$1.RefAttributes<HTMLButtonElement>>;
|
|
690
417
|
declare const AlertDialogCancel: React$1.ForwardRefExoticComponent<Omit<AlertDialogPrimitive.AlertDialogCancelProps & React$1.RefAttributes<HTMLButtonElement>, "ref"> & React$1.RefAttributes<HTMLButtonElement>>;
|
|
691
418
|
|
|
692
|
-
/**
|
|
693
|
-
* AlertRuleCard — saved alert-rule definition. Shows trigger summary,
|
|
694
|
-
* threshold, severity tag, target channels, and an active/inactive toggle.
|
|
695
|
-
*
|
|
696
|
-
* Designed for "Alert Rules" management pages — a list of these cards lets
|
|
697
|
-
* an analyst quickly scan + tweak which alerts are running.
|
|
698
|
-
*/
|
|
699
|
-
type AlertChannel = 'email' | 'sms' | 'telegram' | 'in-app' | 'webhook';
|
|
700
|
-
interface AlertRuleCardProps extends React$1.HTMLAttributes<HTMLDivElement> {
|
|
701
|
-
/** Rule name (e.g., "افزایش ناگهانی منفی") */
|
|
702
|
-
name: React$1.ReactNode;
|
|
703
|
-
/** Trigger description in plain language (e.g., "هرگاه نرخ منفی > ۲۰٪ شد") */
|
|
704
|
-
trigger: React$1.ReactNode;
|
|
705
|
-
/** Threshold value display (e.g., "≥ ۲۰٪", "> ۱۰۰۰ mentions") */
|
|
706
|
-
threshold?: React$1.ReactNode;
|
|
707
|
-
/** Severity that this alert raises */
|
|
708
|
-
severity?: SeverityKey;
|
|
709
|
-
/** Channels this rule fires through */
|
|
710
|
-
channels?: AlertChannel[];
|
|
711
|
-
/** Active state (master switch) */
|
|
712
|
-
active: boolean;
|
|
713
|
-
/** Called when the user toggles the switch */
|
|
714
|
-
onActiveChange: (next: boolean) => void;
|
|
715
|
-
/** Last-fired timestamp display (e.g., "۲ ساعت پیش") */
|
|
716
|
-
lastFired?: React$1.ReactNode;
|
|
717
|
-
/** Optional total fire count */
|
|
718
|
-
fireCount?: number;
|
|
719
|
-
/** Locale @default 'fa' */
|
|
720
|
-
locale?: SupportedLocale;
|
|
721
|
-
}
|
|
722
|
-
declare const AlertRuleCard: React$1.ForwardRefExoticComponent<AlertRuleCardProps & React$1.RefAttributes<HTMLDivElement>>;
|
|
723
|
-
|
|
724
419
|
interface AutocompleteItem {
|
|
725
420
|
value: string;
|
|
726
421
|
label: string;
|
|
@@ -956,19 +651,6 @@ declare namespace AspectRatio {
|
|
|
956
651
|
var displayName: string;
|
|
957
652
|
}
|
|
958
653
|
|
|
959
|
-
declare function Avatar({ className, ...props }: React$1.ComponentProps<typeof AvatarPrimitive.Root>): react_jsx_runtime.JSX.Element;
|
|
960
|
-
declare namespace Avatar {
|
|
961
|
-
var displayName: string;
|
|
962
|
-
}
|
|
963
|
-
declare function AvatarImage({ className, ...props }: React$1.ComponentProps<typeof AvatarPrimitive.Image>): react_jsx_runtime.JSX.Element;
|
|
964
|
-
declare namespace AvatarImage {
|
|
965
|
-
var displayName: string;
|
|
966
|
-
}
|
|
967
|
-
declare function AvatarFallback({ className, ...props }: React$1.ComponentProps<typeof AvatarPrimitive.Fallback>): react_jsx_runtime.JSX.Element;
|
|
968
|
-
declare namespace AvatarFallback {
|
|
969
|
-
var displayName: string;
|
|
970
|
-
}
|
|
971
|
-
|
|
972
654
|
declare const avatarGroupVariants: (props?: ({
|
|
973
655
|
size?: "sm" | "md" | "lg" | null | undefined;
|
|
974
656
|
} & class_variance_authority_types.ClassProp) | undefined) => string;
|
|
@@ -985,17 +667,6 @@ interface AvatarGroupProps extends React$1.HTMLAttributes<HTMLDivElement>, Varia
|
|
|
985
667
|
}
|
|
986
668
|
declare const AvatarGroup: React$1.ForwardRefExoticComponent<AvatarGroupProps & React$1.RefAttributes<HTMLDivElement>>;
|
|
987
669
|
|
|
988
|
-
declare const badgeVariants: (props?: ({
|
|
989
|
-
variant?: "warning" | "success" | "default" | "outline" | "destructive" | "secondary" | "brand" | null | undefined;
|
|
990
|
-
size?: "xs" | "sm" | "md" | "lg" | "small" | "large" | "tiny" | null | undefined;
|
|
991
|
-
dot?: boolean | null | undefined;
|
|
992
|
-
} & class_variance_authority_types.ClassProp) | undefined) => string;
|
|
993
|
-
interface BadgeProps extends React$1.HTMLAttributes<HTMLSpanElement>, VariantProps<typeof badgeVariants> {
|
|
994
|
-
dot?: boolean;
|
|
995
|
-
dotPosition?: 'start' | 'end';
|
|
996
|
-
}
|
|
997
|
-
declare const Badge: React$1.ForwardRefExoticComponent<BadgeProps & React$1.RefAttributes<HTMLSpanElement>>;
|
|
998
|
-
|
|
999
670
|
declare const bannerVariants: (props?: ({
|
|
1000
671
|
variant?: "neutral" | "warning" | "success" | "info" | "destructive" | null | undefined;
|
|
1001
672
|
} & class_variance_authority_types.ClassProp) | undefined) => string;
|
|
@@ -1042,43 +713,6 @@ declare namespace BreadcrumbEllipsis {
|
|
|
1042
713
|
var displayName: string;
|
|
1043
714
|
}
|
|
1044
715
|
|
|
1045
|
-
type ButtonVariantProps = VariantProps<typeof buttonVariants>;
|
|
1046
|
-
declare const buttonVariants: (props?: ({
|
|
1047
|
-
variant?: "warning" | "link" | "text" | "default" | "outline" | "dashed" | "destructive" | "primary" | "secondary" | "danger" | "ghost" | null | undefined;
|
|
1048
|
-
block?: boolean | null | undefined;
|
|
1049
|
-
size?: "xs" | "sm" | "md" | "lg" | "xl" | "default" | "icon" | null | undefined;
|
|
1050
|
-
disabled?: boolean | null | undefined;
|
|
1051
|
-
rounded?: boolean | null | undefined;
|
|
1052
|
-
} & class_variance_authority_types.ClassProp) | undefined) => string;
|
|
1053
|
-
type LoadingVariantProps = VariantProps<typeof loadingVariants>;
|
|
1054
|
-
declare const loadingVariants: (props?: ({
|
|
1055
|
-
variant?: "warning" | "link" | "text" | "default" | "outline" | "dashed" | "destructive" | "primary" | "secondary" | "danger" | "ghost" | null | undefined;
|
|
1056
|
-
loading?: boolean | "default" | null | undefined;
|
|
1057
|
-
} & class_variance_authority_types.ClassProp) | undefined) => string;
|
|
1058
|
-
interface ButtonProps extends Omit<React.ButtonHTMLAttributes<HTMLButtonElement>, 'type'>, Omit<ButtonVariantProps, 'disabled'>, Omit<LoadingVariantProps, 'variant'> {
|
|
1059
|
-
asChild?: boolean;
|
|
1060
|
-
type?: ButtonVariantProps['variant'] | React.ButtonHTMLAttributes<HTMLButtonElement>['type'];
|
|
1061
|
-
htmlType?: React.ButtonHTMLAttributes<HTMLButtonElement>['type'];
|
|
1062
|
-
icon?: React.ReactNode;
|
|
1063
|
-
iconStart?: React.ReactNode;
|
|
1064
|
-
iconEnd?: React.ReactNode;
|
|
1065
|
-
/** @deprecated Use iconStart instead */
|
|
1066
|
-
iconLeft?: React.ReactNode;
|
|
1067
|
-
/** @deprecated Use iconEnd instead */
|
|
1068
|
-
iconRight?: React.ReactNode;
|
|
1069
|
-
isLoading?: boolean;
|
|
1070
|
-
/** @deprecated Use `isLoading` instead */
|
|
1071
|
-
loading?: boolean;
|
|
1072
|
-
block?: boolean;
|
|
1073
|
-
rounded?: boolean;
|
|
1074
|
-
}
|
|
1075
|
-
declare const Button: React$1.ForwardRefExoticComponent<ButtonProps & React$1.RefAttributes<HTMLButtonElement>>;
|
|
1076
|
-
|
|
1077
|
-
interface SeparatorProps extends React$1.ComponentPropsWithoutRef<typeof SeparatorPrimitive.Root> {
|
|
1078
|
-
children?: React$1.ReactNode;
|
|
1079
|
-
}
|
|
1080
|
-
declare const Separator: React$1.ForwardRefExoticComponent<SeparatorProps & React$1.RefAttributes<HTMLDivElement>>;
|
|
1081
|
-
|
|
1082
716
|
declare const buttonGroupVariants: (props?: ({
|
|
1083
717
|
orientation?: "horizontal" | "vertical" | null | undefined;
|
|
1084
718
|
} & class_variance_authority_types.ClassProp) | undefined) => string;
|
|
@@ -1097,30 +731,6 @@ declare namespace ButtonGroupSeparator {
|
|
|
1097
731
|
var displayName: string;
|
|
1098
732
|
}
|
|
1099
733
|
|
|
1100
|
-
type CalendarProps = {
|
|
1101
|
-
usePersianCalendar?: boolean;
|
|
1102
|
-
className?: string;
|
|
1103
|
-
classNames?: Partial<Record<string, string>>;
|
|
1104
|
-
showOutsideDays?: boolean;
|
|
1105
|
-
} & (React$1.ComponentProps<typeof DayPicker> | React$1.ComponentProps<typeof DayPicker$1>);
|
|
1106
|
-
declare function Calendar({ className, classNames, showOutsideDays, usePersianCalendar, ...props }: CalendarProps): react_jsx_runtime.JSX.Element;
|
|
1107
|
-
declare namespace Calendar {
|
|
1108
|
-
var displayName: string;
|
|
1109
|
-
}
|
|
1110
|
-
|
|
1111
|
-
declare const cardVariants: (props?: ({
|
|
1112
|
-
variant?: "default" | "outlined" | "elevated" | "interactive" | "glass" | null | undefined;
|
|
1113
|
-
size?: "sm" | "md" | "lg" | null | undefined;
|
|
1114
|
-
} & class_variance_authority_types.ClassProp) | undefined) => string;
|
|
1115
|
-
interface CardProps extends React$1.HTMLAttributes<HTMLDivElement>, VariantProps<typeof cardVariants> {
|
|
1116
|
-
}
|
|
1117
|
-
declare const Card: React$1.ForwardRefExoticComponent<CardProps & React$1.RefAttributes<HTMLDivElement>>;
|
|
1118
|
-
declare const CardHeader: React$1.ForwardRefExoticComponent<React$1.HTMLAttributes<HTMLDivElement> & React$1.RefAttributes<HTMLDivElement>>;
|
|
1119
|
-
declare const CardTitle: React$1.ForwardRefExoticComponent<React$1.HTMLAttributes<HTMLHeadingElement> & React$1.RefAttributes<HTMLParagraphElement>>;
|
|
1120
|
-
declare const CardDescription: React$1.ForwardRefExoticComponent<React$1.HTMLAttributes<HTMLParagraphElement> & React$1.RefAttributes<HTMLParagraphElement>>;
|
|
1121
|
-
declare const CardContent: React$1.ForwardRefExoticComponent<React$1.HTMLAttributes<HTMLDivElement> & React$1.RefAttributes<HTMLDivElement>>;
|
|
1122
|
-
declare const CardFooter: React$1.ForwardRefExoticComponent<React$1.HTMLAttributes<HTMLDivElement> & React$1.RefAttributes<HTMLDivElement>>;
|
|
1123
|
-
|
|
1124
734
|
type CarouselApi = UseEmblaCarouselType[1];
|
|
1125
735
|
type UseCarouselParameters = Parameters<typeof useEmblaCarousel>;
|
|
1126
736
|
type CarouselOptions = UseCarouselParameters[0];
|
|
@@ -1187,23 +797,6 @@ declare namespace CollapsibleContent {
|
|
|
1187
797
|
var displayName: string;
|
|
1188
798
|
}
|
|
1189
799
|
|
|
1190
|
-
declare const Dialog: React$1.FC<DialogPrimitive.DialogProps>;
|
|
1191
|
-
declare const DialogTrigger: React$1.ForwardRefExoticComponent<DialogPrimitive.DialogTriggerProps & React$1.RefAttributes<HTMLButtonElement>>;
|
|
1192
|
-
declare const DialogPortal: React$1.FC<DialogPrimitive.DialogPortalProps>;
|
|
1193
|
-
declare const DialogClose: React$1.ForwardRefExoticComponent<Omit<DialogPrimitive.DialogCloseProps & React$1.RefAttributes<HTMLButtonElement>, "ref"> & React$1.RefAttributes<HTMLButtonElement>>;
|
|
1194
|
-
declare const DialogOverlay: React$1.ForwardRefExoticComponent<Omit<DialogPrimitive.DialogOverlayProps & React$1.RefAttributes<HTMLDivElement>, "ref"> & React$1.RefAttributes<HTMLDivElement>>;
|
|
1195
|
-
declare const DialogContent: React$1.ForwardRefExoticComponent<Omit<DialogPrimitive.DialogContentProps & React$1.RefAttributes<HTMLDivElement>, "ref"> & React$1.RefAttributes<HTMLDivElement>>;
|
|
1196
|
-
declare const DialogHeader: {
|
|
1197
|
-
({ className, ...props }: React$1.HTMLAttributes<HTMLDivElement>): react_jsx_runtime.JSX.Element;
|
|
1198
|
-
displayName: string;
|
|
1199
|
-
};
|
|
1200
|
-
declare const DialogFooter: {
|
|
1201
|
-
({ className, ...props }: React$1.HTMLAttributes<HTMLDivElement>): react_jsx_runtime.JSX.Element;
|
|
1202
|
-
displayName: string;
|
|
1203
|
-
};
|
|
1204
|
-
declare const DialogTitle: React$1.ForwardRefExoticComponent<Omit<DialogPrimitive.DialogTitleProps & React$1.RefAttributes<HTMLHeadingElement>, "ref"> & React$1.RefAttributes<HTMLHeadingElement>>;
|
|
1205
|
-
declare const DialogDescription: React$1.ForwardRefExoticComponent<Omit<DialogPrimitive.DialogDescriptionProps & React$1.RefAttributes<HTMLParagraphElement>, "ref"> & React$1.RefAttributes<HTMLParagraphElement>>;
|
|
1206
|
-
|
|
1207
800
|
declare function Command({ className, ...props }: React$1.ComponentProps<typeof Command$1>): react_jsx_runtime.JSX.Element;
|
|
1208
801
|
declare namespace Command {
|
|
1209
802
|
var displayName: string;
|
|
@@ -1245,69 +838,6 @@ declare namespace CommandShortcut {
|
|
|
1245
838
|
var displayName: string;
|
|
1246
839
|
}
|
|
1247
840
|
|
|
1248
|
-
/**
|
|
1249
|
-
* Hotkey string grammar:
|
|
1250
|
-
*
|
|
1251
|
-
* <part>[+<part>]*
|
|
1252
|
-
*
|
|
1253
|
-
* where each <part> is one of:
|
|
1254
|
-
* mod — Cmd on macOS, Ctrl on everything else (recommended)
|
|
1255
|
-
* ctrl / cmd — explicit, cross-platform tokens
|
|
1256
|
-
* shift | alt | meta
|
|
1257
|
-
* <single key> — lowercase character, 'space', 'enter', 'escape', 'tab',
|
|
1258
|
-
* arrow{up,down,left,right}, 'slash', 'backspace', etc.
|
|
1259
|
-
*
|
|
1260
|
-
* Examples:
|
|
1261
|
-
* 'mod+k' — ⌘K on macOS, CtrlK elsewhere
|
|
1262
|
-
* 'mod+shift+p'
|
|
1263
|
-
* 'escape'
|
|
1264
|
-
* 'ctrl+k' — explicit Ctrl (no Cmd fallback on macOS)
|
|
1265
|
-
*
|
|
1266
|
-
* Passing an array of strings is treated as an OR — any combo fires the handler.
|
|
1267
|
-
*/
|
|
1268
|
-
type HotkeyCombo = string | readonly string[];
|
|
1269
|
-
interface UseHotkeysOptions {
|
|
1270
|
-
/**
|
|
1271
|
-
* When true, `event.preventDefault()` is called on matched combos.
|
|
1272
|
-
* Default: true. Useful to allow the browser's native 'mod+k' (address bar)
|
|
1273
|
-
* to keep working — set to false if the handler only does something conditionally.
|
|
1274
|
-
*/
|
|
1275
|
-
preventDefault?: boolean;
|
|
1276
|
-
/**
|
|
1277
|
-
* Skip the handler when focus is inside an editable control (input, textarea,
|
|
1278
|
-
* contenteditable). The exception: combos that include a modifier (mod/ctrl/
|
|
1279
|
-
* cmd/alt) still fire — they are unambiguous shortcuts, not typing.
|
|
1280
|
-
* Default: true.
|
|
1281
|
-
*/
|
|
1282
|
-
ignoreWhenTyping?: boolean;
|
|
1283
|
-
/**
|
|
1284
|
-
* When false, the hook unregisters its listener. Useful for conditionally
|
|
1285
|
-
* enabling shortcuts (e.g., only while a panel is open).
|
|
1286
|
-
* Default: true.
|
|
1287
|
-
*/
|
|
1288
|
-
enabled?: boolean;
|
|
1289
|
-
/**
|
|
1290
|
-
* DOM target. Defaults to `document`. Pass a ref for scoped shortcuts (e.g.,
|
|
1291
|
-
* only when a specific panel has focus within).
|
|
1292
|
-
*/
|
|
1293
|
-
target?: React$1.RefObject<HTMLElement | null> | HTMLElement | Document | null;
|
|
1294
|
-
}
|
|
1295
|
-
/**
|
|
1296
|
-
* Register a keyboard shortcut. Handler fires when the combo matches, respecting
|
|
1297
|
-
* `ignoreWhenTyping` (default true) — except when a modifier is part of the combo,
|
|
1298
|
-
* which always wins. Returns nothing; cleanup is automatic.
|
|
1299
|
-
*
|
|
1300
|
-
* @example
|
|
1301
|
-
* useHotkeys('mod+k', () => setOpen((v) => !v))
|
|
1302
|
-
* useHotkeys(['escape', 'mod+w'], close, { enabled: open })
|
|
1303
|
-
*/
|
|
1304
|
-
declare function useHotkeys(combo: HotkeyCombo, handler: (event: KeyboardEvent) => void, options?: UseHotkeysOptions): void;
|
|
1305
|
-
/**
|
|
1306
|
-
* Render-helper: returns a platform-appropriate display string for a combo.
|
|
1307
|
-
* 'mod+k' → '⌘K' on macOS, 'Ctrl+K' elsewhere. Useful for `<CommandShortcut>`.
|
|
1308
|
-
*/
|
|
1309
|
-
declare function formatHotkey(combo: string): string;
|
|
1310
|
-
|
|
1311
841
|
interface CommandPaletteItem {
|
|
1312
842
|
/** Stable identifier. Used as the cmdk value and the recents key — MUST be unique across the whole items list. */
|
|
1313
843
|
id: string;
|
|
@@ -1403,9 +933,20 @@ interface PartoRadarChartProps {
|
|
|
1403
933
|
};
|
|
1404
934
|
/** Custom tooltip formatter */
|
|
1405
935
|
tooltipFormatter?: (name: string, value: number) => React$1.ReactNode;
|
|
936
|
+
/**
|
|
937
|
+
* Locale for digit formatting in tooltips and angle-axis labels. fa/ar
|
|
938
|
+
* convert embedded digits to Persian/Arabic; en uses Latin. Default: 'fa'.
|
|
939
|
+
*/
|
|
940
|
+
locale?: SupportedLocale;
|
|
1406
941
|
className?: string;
|
|
1407
942
|
isLoading?: boolean;
|
|
1408
943
|
ariaLabel?: string;
|
|
944
|
+
/**
|
|
945
|
+
* Render a legend below the radar that names each series. Recommended when
|
|
946
|
+
* more than one Radar fill is drawn — overlapping color-only fills are
|
|
947
|
+
* unreadable for colorblind users (WCAG 1.4.1). @default `false`
|
|
948
|
+
*/
|
|
949
|
+
legend?: boolean;
|
|
1409
950
|
}
|
|
1410
951
|
declare const PartoRadarChart: React$1.ForwardRefExoticComponent<PartoRadarChartProps & React$1.RefAttributes<HTMLDivElement>>;
|
|
1411
952
|
|
|
@@ -1874,84 +1415,6 @@ declare namespace ContextMenuShortcut {
|
|
|
1874
1415
|
var displayName: string;
|
|
1875
1416
|
}
|
|
1876
1417
|
|
|
1877
|
-
type FlowData = Partial<Record<FlowKey, number>>;
|
|
1878
|
-
interface FlowDistributionProps extends React$1.HTMLAttributes<HTMLDivElement> {
|
|
1879
|
-
/** Flow counts (auto-normalized). Missing keys treated as 0. */
|
|
1880
|
-
data: FlowData;
|
|
1881
|
-
/** Display mode */
|
|
1882
|
-
variant?: 'bars' | 'stacked' | 'compact';
|
|
1883
|
-
/** Show numeric counts alongside percent */
|
|
1884
|
-
showCounts?: boolean;
|
|
1885
|
-
/** Show percentages */
|
|
1886
|
-
showPercent?: boolean;
|
|
1887
|
-
/** Locale */
|
|
1888
|
-
locale?: SupportedLocale;
|
|
1889
|
-
/** Loading skeleton */
|
|
1890
|
-
isLoading?: boolean;
|
|
1891
|
-
}
|
|
1892
|
-
declare const FlowDistribution: React$1.ForwardRefExoticComponent<FlowDistributionProps & React$1.RefAttributes<HTMLDivElement>>;
|
|
1893
|
-
|
|
1894
|
-
interface SentimentData {
|
|
1895
|
-
positive: number;
|
|
1896
|
-
negative: number;
|
|
1897
|
-
neutral: number;
|
|
1898
|
-
mixed?: number;
|
|
1899
|
-
}
|
|
1900
|
-
interface SentimentDistributionProps extends React$1.HTMLAttributes<HTMLDivElement> {
|
|
1901
|
-
/** Sentiment counts (will be auto-normalized to 100%) */
|
|
1902
|
-
data: SentimentData;
|
|
1903
|
-
/** Display mode */
|
|
1904
|
-
variant?: 'bars' | 'stacked' | 'compact';
|
|
1905
|
-
/** Show numeric count labels */
|
|
1906
|
-
showCounts?: boolean;
|
|
1907
|
-
/** Show percentage labels */
|
|
1908
|
-
showPercent?: boolean;
|
|
1909
|
-
/** Locale for number/label formatting */
|
|
1910
|
-
locale?: SupportedLocale;
|
|
1911
|
-
/** Show loading skeleton */
|
|
1912
|
-
isLoading?: boolean;
|
|
1913
|
-
}
|
|
1914
|
-
declare const SentimentDistribution: React$1.ForwardRefExoticComponent<SentimentDistributionProps & React$1.RefAttributes<HTMLDivElement>>;
|
|
1915
|
-
|
|
1916
|
-
/**
|
|
1917
|
-
* ConceptCard — افکارسنجی-flavored headline tile for clustering dashboards.
|
|
1918
|
-
* Composes: status badge, severity badge, flow composition bar, sentiment
|
|
1919
|
-
* distribution, sparkline trend, AI summary snippet, optional comparison
|
|
1920
|
-
* checkbox. Built for government dashboards where each "concept" needs
|
|
1921
|
-
* to fit in a card grid with rich, comparable signals.
|
|
1922
|
-
*/
|
|
1923
|
-
interface ConceptCardProps extends Omit<React$1.HTMLAttributes<HTMLDivElement>, 'title'> {
|
|
1924
|
-
/** Concept name (e.g., "افزایش قیمت بنزین") */
|
|
1925
|
-
title: React$1.ReactNode;
|
|
1926
|
-
/** Short subtitle (e.g., "خوشه ۴ — ۱۲۰ پست") */
|
|
1927
|
-
subtitle?: React$1.ReactNode;
|
|
1928
|
-
/** Operational status */
|
|
1929
|
-
status?: StatusKey;
|
|
1930
|
-
/** Criticality of the concept (urgent/high/medium/low) */
|
|
1931
|
-
severity?: SeverityKey;
|
|
1932
|
-
/** Flow composition breakdown (5-class political) */
|
|
1933
|
-
flow?: FlowData;
|
|
1934
|
-
/** Sentiment composition (3-class) */
|
|
1935
|
-
sentiment?: SentimentData;
|
|
1936
|
-
/** Trend sparkline values (e.g., last 14 days mention volume) */
|
|
1937
|
-
trend?: number[];
|
|
1938
|
-
/** AI-generated short summary (1-2 sentences) */
|
|
1939
|
-
aiSummary?: React$1.ReactNode;
|
|
1940
|
-
/** Total mentions / size — shown as a stat */
|
|
1941
|
-
totalCount?: number;
|
|
1942
|
-
/** Comparison checkbox state. When provided, renders the checkbox in the header */
|
|
1943
|
-
comparison?: {
|
|
1944
|
-
selected: boolean;
|
|
1945
|
-
onSelectionChange: (next: boolean) => void;
|
|
1946
|
-
label?: React$1.ReactNode;
|
|
1947
|
-
};
|
|
1948
|
-
/** Make the entire card clickable (cursor + hover/focus ring) */
|
|
1949
|
-
interactive?: boolean;
|
|
1950
|
-
/** Locale @default 'fa' */
|
|
1951
|
-
locale?: SupportedLocale;
|
|
1952
|
-
}
|
|
1953
|
-
declare const ConceptCard: React$1.ForwardRefExoticComponent<ConceptCardProps & React$1.RefAttributes<HTMLDivElement>>;
|
|
1954
|
-
|
|
1955
1418
|
interface CopyButtonProps extends Omit<ButtonProps, 'onClick'> {
|
|
1956
1419
|
/** The text value to copy to clipboard */
|
|
1957
1420
|
value: string;
|
|
@@ -2264,6 +1727,32 @@ declare const EmptyTitle: React$1.ForwardRefExoticComponent<Omit<React$1.Detaile
|
|
|
2264
1727
|
declare const EmptyDescription: React$1.ForwardRefExoticComponent<Omit<React$1.DetailedHTMLProps<React$1.HTMLAttributes<HTMLParagraphElement>, HTMLParagraphElement>, "ref"> & React$1.RefAttributes<HTMLParagraphElement>>;
|
|
2265
1728
|
declare const EmptyAction: React$1.ForwardRefExoticComponent<Omit<React$1.DetailedHTMLProps<React$1.HTMLAttributes<HTMLDivElement>, HTMLDivElement>, "ref"> & React$1.RefAttributes<HTMLDivElement>>;
|
|
2266
1729
|
|
|
1730
|
+
/**
|
|
1731
|
+
* SVG illustrations for empty / error / forbidden / first-run / no-results
|
|
1732
|
+
* states. All use `currentColor` so consumers can color them via
|
|
1733
|
+
* `text-foreground-muted` (default) or any token class. RTL-safe — no
|
|
1734
|
+
* directional cues built in.
|
|
1735
|
+
*
|
|
1736
|
+
* Usage with the Empty primitive:
|
|
1737
|
+
*
|
|
1738
|
+
* <Empty>
|
|
1739
|
+
* <NoResultsIllustration className="size-32 text-foreground-muted" />
|
|
1740
|
+
* <EmptyTitle>نتیجهای یافت نشد</EmptyTitle>
|
|
1741
|
+
* <EmptyDescription>عبارت دیگری امتحان کنید یا فیلترها را پاک کنید</EmptyDescription>
|
|
1742
|
+
* </Empty>
|
|
1743
|
+
*
|
|
1744
|
+
* The illustrations sit at ~120×120 viewBox and scale with `size-*` classes.
|
|
1745
|
+
* Stroke-only line work keeps them theme-agnostic (no tinting needed for
|
|
1746
|
+
* dark mode) and tarball-cheap (each ~600 bytes after gzip).
|
|
1747
|
+
*/
|
|
1748
|
+
|
|
1749
|
+
type SVGProps = React$1.SVGProps<SVGSVGElement>;
|
|
1750
|
+
declare const NoResultsIllustration: React$1.ForwardRefExoticComponent<Omit<SVGProps, "ref"> & React$1.RefAttributes<SVGSVGElement>>;
|
|
1751
|
+
declare const NoDataIllustration: React$1.ForwardRefExoticComponent<Omit<SVGProps, "ref"> & React$1.RefAttributes<SVGSVGElement>>;
|
|
1752
|
+
declare const FirstRunIllustration: React$1.ForwardRefExoticComponent<Omit<SVGProps, "ref"> & React$1.RefAttributes<SVGSVGElement>>;
|
|
1753
|
+
declare const ErrorIllustration: React$1.ForwardRefExoticComponent<Omit<SVGProps, "ref"> & React$1.RefAttributes<SVGSVGElement>>;
|
|
1754
|
+
declare const ForbiddenIllustration: React$1.ForwardRefExoticComponent<Omit<SVGProps, "ref"> & React$1.RefAttributes<SVGSVGElement>>;
|
|
1755
|
+
|
|
2267
1756
|
interface ErrorStateProps extends React$1.HTMLAttributes<HTMLDivElement> {
|
|
2268
1757
|
/** Error message displayed below the icon */
|
|
2269
1758
|
message?: string;
|
|
@@ -2475,16 +1964,48 @@ declare namespace HoverCardContent {
|
|
|
2475
1964
|
var displayName: string;
|
|
2476
1965
|
}
|
|
2477
1966
|
|
|
2478
|
-
|
|
2479
|
-
|
|
2480
|
-
|
|
2481
|
-
/**
|
|
2482
|
-
|
|
2483
|
-
|
|
2484
|
-
|
|
2485
|
-
|
|
1967
|
+
interface NumberInputLocaleProps extends Omit<React$1.ComponentProps<'input'>, 'type' | 'value' | 'defaultValue' | 'onChange' | 'size'> {
|
|
1968
|
+
/** Current numeric value. Use `null` for empty. */
|
|
1969
|
+
value?: number | null;
|
|
1970
|
+
/** Initial value (uncontrolled). */
|
|
1971
|
+
defaultValue?: number | null;
|
|
1972
|
+
/** Called when the parsed numeric value changes. `null` means cleared. */
|
|
1973
|
+
onValueChange?: (next: number | null) => void;
|
|
1974
|
+
/**
|
|
1975
|
+
* Locale for digit display + parse. Persian/Arabic input is auto-normalised
|
|
1976
|
+
* to Latin before parsing; output digits match the locale.
|
|
1977
|
+
* @default 'fa'
|
|
1978
|
+
*/
|
|
1979
|
+
locale?: SupportedLocale;
|
|
1980
|
+
/** Optional unit suffix shown on the inline-end side (e.g. "%", "تومان"). */
|
|
1981
|
+
unit?: React$1.ReactNode;
|
|
1982
|
+
/** Min value (inclusive). */
|
|
1983
|
+
min?: number;
|
|
1984
|
+
/** Max value (inclusive). */
|
|
1985
|
+
max?: number;
|
|
1986
|
+
/** Number of fractional digits. @default 0 (integer) */
|
|
1987
|
+
decimals?: number;
|
|
1988
|
+
/** Show grouping separator (1,234) in display. @default true */
|
|
1989
|
+
thousandSeparator?: boolean;
|
|
1990
|
+
/** Allow negative numbers. @default true */
|
|
1991
|
+
allowNegative?: boolean;
|
|
2486
1992
|
}
|
|
2487
|
-
|
|
1993
|
+
/**
|
|
1994
|
+
* Locale-aware number input. Accepts Persian, Arabic, or Latin digits;
|
|
1995
|
+
* always emits a parsed JS `number` (or `null` for empty) via `onValueChange`.
|
|
1996
|
+
* Display digits match `locale` (Persian by default).
|
|
1997
|
+
*
|
|
1998
|
+
* - While the input is focused, the value renders as the user typed (raw
|
|
1999
|
+
* sanitized buffer), so editing mid-string doesn't snap the caret.
|
|
2000
|
+
* - On blur, value is re-formatted to the locale display (with thousand
|
|
2001
|
+
* separators + decimals padded to spec).
|
|
2002
|
+
* - `min`/`max` clamp on blur, never mid-edit.
|
|
2003
|
+
*
|
|
2004
|
+
* @example
|
|
2005
|
+
* const [n, setN] = useState<number | null>(null)
|
|
2006
|
+
* <NumberInputLocale value={n} onValueChange={setN} unit="تومان" thousandSeparator />
|
|
2007
|
+
*/
|
|
2008
|
+
declare const NumberInputLocale: React$1.ForwardRefExoticComponent<Omit<NumberInputLocaleProps, "ref"> & React$1.RefAttributes<HTMLInputElement>>;
|
|
2488
2009
|
|
|
2489
2010
|
interface InputWithIconProps extends InputProps {
|
|
2490
2011
|
/** Icon rendered at the start (inline-start, respects RTL) */
|
|
@@ -2510,11 +2031,54 @@ interface TagInputProps extends Omit<React$1.HTMLAttributes<HTMLDivElement>, 'on
|
|
|
2510
2031
|
prefix?: string;
|
|
2511
2032
|
/** Locale for sr-only remove label @default "fa" */
|
|
2512
2033
|
locale?: SupportedLocale;
|
|
2034
|
+
/** Form `name` attribute forwarded to the inner `<input>` (for React Hook Form / native forms). */
|
|
2035
|
+
name?: string;
|
|
2036
|
+
/** HTML5 `required` attribute forwarded to the inner `<input>`. */
|
|
2037
|
+
required?: boolean;
|
|
2513
2038
|
}
|
|
2514
2039
|
declare const TagInput: React$1.ForwardRefExoticComponent<TagInputProps & React$1.RefAttributes<HTMLDivElement>>;
|
|
2515
2040
|
|
|
2516
2041
|
declare const HashtagInput: React$1.ForwardRefExoticComponent<TagInputProps & React$1.RefAttributes<HTMLDivElement>>;
|
|
2517
2042
|
|
|
2043
|
+
interface HashtagPerformanceData {
|
|
2044
|
+
/** Hashtag without the leading `#` — the component renders the marker. */
|
|
2045
|
+
tag: string;
|
|
2046
|
+
/** Mention frequency (count of posts using the tag). */
|
|
2047
|
+
frequency: number;
|
|
2048
|
+
/** Engagement rate (%) for posts that used this tag. */
|
|
2049
|
+
engagementRate?: number;
|
|
2050
|
+
/** Trend sparkline values (e.g. last 7-14 days frequency). */
|
|
2051
|
+
trend?: number[];
|
|
2052
|
+
/** Optional explicit delta (% vs previous period). When omitted, derived from `trend`. */
|
|
2053
|
+
delta?: number;
|
|
2054
|
+
}
|
|
2055
|
+
interface HashtagPerformanceRowProps extends Omit<React$1.HTMLAttributes<HTMLDivElement>, 'onClick'> {
|
|
2056
|
+
data: HashtagPerformanceData;
|
|
2057
|
+
/** Make the row clickable (opens an analytics drill-down on the consumer side). */
|
|
2058
|
+
onRowClick?: (data: HashtagPerformanceData) => void;
|
|
2059
|
+
/** Show ranking number at the start of the row (1, 2, 3, …). */
|
|
2060
|
+
rank?: number;
|
|
2061
|
+
/** Density compact (28px) vs comfortable (40px). @default 'comfortable' */
|
|
2062
|
+
density?: 'compact' | 'comfortable';
|
|
2063
|
+
/** Locale for digit + label formatting. @default 'fa' */
|
|
2064
|
+
locale?: SupportedLocale;
|
|
2065
|
+
}
|
|
2066
|
+
/**
|
|
2067
|
+
* Single row in a hashtag-performance table — hashtag + frequency +
|
|
2068
|
+
* engagement + sparkline trend + delta. Designed to drop straight into a
|
|
2069
|
+
* `<DataTable>` cell renderer or a vertical list of top hashtags.
|
|
2070
|
+
*
|
|
2071
|
+
* @example
|
|
2072
|
+
* <DataTable
|
|
2073
|
+
* columns={[{
|
|
2074
|
+
* id: 'hashtag', header: 'هشتگ',
|
|
2075
|
+
* cell: (row) => <HashtagPerformanceRow data={row} rank={row.rank} />,
|
|
2076
|
+
* }]}
|
|
2077
|
+
* data={hashtags}
|
|
2078
|
+
* />
|
|
2079
|
+
*/
|
|
2080
|
+
declare const HashtagPerformanceRow: React$1.ForwardRefExoticComponent<HashtagPerformanceRowProps & React$1.RefAttributes<HTMLDivElement>>;
|
|
2081
|
+
|
|
2518
2082
|
type CardSize = 'sm' | 'md' | 'lg';
|
|
2519
2083
|
interface EntityHealthCardProps extends React$1.HTMLAttributes<HTMLDivElement> {
|
|
2520
2084
|
/** Current health state — drives colour, icon, and default narrative framing */
|
|
@@ -2784,7 +2348,207 @@ declare namespace KbdGroup {
|
|
|
2784
2348
|
var displayName: string;
|
|
2785
2349
|
}
|
|
2786
2350
|
|
|
2787
|
-
declare
|
|
2351
|
+
declare const labelChipVariants: (props?: ({
|
|
2352
|
+
tone?: "neutral" | "warning" | "success" | "destructive" | "brand" | "ai" | null | undefined;
|
|
2353
|
+
size?: "sm" | "md" | null | undefined;
|
|
2354
|
+
} & class_variance_authority_types.ClassProp) | undefined) => string;
|
|
2355
|
+
interface LabelChipProps extends Omit<React$1.HTMLAttributes<HTMLSpanElement>, 'onClick'>, VariantProps<typeof labelChipVariants> {
|
|
2356
|
+
/** Visible label text. */
|
|
2357
|
+
children: React$1.ReactNode;
|
|
2358
|
+
/** When set, renders an inline pencil button that opens an editor on consumer side. */
|
|
2359
|
+
onEdit?: () => void;
|
|
2360
|
+
/** When set, renders an inline ✕ button to dismiss/remove the label. */
|
|
2361
|
+
onRemove?: () => void;
|
|
2362
|
+
/**
|
|
2363
|
+
* Mark the chip as AI-generated — adds a subtle ✦ prefix and the `ai` tone
|
|
2364
|
+
* (unless tone is explicitly overridden). Used by AI-labeled clustering
|
|
2365
|
+
* dashboards to distinguish auto-tagged from human-curated labels.
|
|
2366
|
+
*/
|
|
2367
|
+
aiGenerated?: boolean;
|
|
2368
|
+
/** Confidence (0–1) for AI labels — rendered as a small `(۸۰%)` suffix when set. */
|
|
2369
|
+
confidence?: number;
|
|
2370
|
+
/** Whole chip click handler — useful for filter-by-label flows. */
|
|
2371
|
+
onSelect?: () => void;
|
|
2372
|
+
}
|
|
2373
|
+
declare const LabelChip: React$1.ForwardRefExoticComponent<LabelChipProps & React$1.RefAttributes<HTMLSpanElement>>;
|
|
2374
|
+
|
|
2375
|
+
interface LabelEditDialogProps {
|
|
2376
|
+
/** Controlled open state. */
|
|
2377
|
+
open: boolean;
|
|
2378
|
+
onOpenChange: (open: boolean) => void;
|
|
2379
|
+
/** Initial value of the label being edited. */
|
|
2380
|
+
initialValue?: string;
|
|
2381
|
+
/** Whether this label was originally AI-generated (controls the AI-flag toggle default). */
|
|
2382
|
+
aiGenerated?: boolean;
|
|
2383
|
+
/** Existing labels — surfaced as quick-pick suggestions during edit. */
|
|
2384
|
+
suggestions?: string[];
|
|
2385
|
+
/** Save handler. Called with the new value + the AI-generated flag (consumer persists). */
|
|
2386
|
+
onSave: (value: string, aiGenerated: boolean) => void;
|
|
2387
|
+
/**
|
|
2388
|
+
* Optional handler for the "Delete label" destructive action. When set, a
|
|
2389
|
+
* `Button variant="destructive"` shows up in the footer; omit to hide.
|
|
2390
|
+
*/
|
|
2391
|
+
onDelete?: () => void;
|
|
2392
|
+
/** Locale for default strings. @default 'fa' */
|
|
2393
|
+
locale?: SupportedLocale;
|
|
2394
|
+
}
|
|
2395
|
+
/**
|
|
2396
|
+
* Edit dialog for AI-labeled clustering. Pairs with `<LabelChip>` — when
|
|
2397
|
+
* users click the pencil affordance on a chip, this dialog opens with the
|
|
2398
|
+
* current value pre-filled, an AI-generated toggle, and a list of
|
|
2399
|
+
* suggestions (typically other labels already in use).
|
|
2400
|
+
*
|
|
2401
|
+
* Stateless wrt persistence: consumer wires `onSave` to whatever backend.
|
|
2402
|
+
*/
|
|
2403
|
+
declare const LabelEditDialog: React$1.ForwardRefExoticComponent<LabelEditDialogProps & React$1.RefAttributes<HTMLDivElement>>;
|
|
2404
|
+
|
|
2405
|
+
interface MarkdownRendererProps extends Omit<React$1.HTMLAttributes<HTMLDivElement>, 'children'> {
|
|
2406
|
+
/** Raw markdown source. Safe by default — raw HTML is escaped, scripts are never executed. */
|
|
2407
|
+
children: string;
|
|
2408
|
+
/**
|
|
2409
|
+
* Enables permissive link schemes. By default only `http`, `https`, and `mailto` are kept;
|
|
2410
|
+
* everything else (including `javascript:`) is dropped.
|
|
2411
|
+
*/
|
|
2412
|
+
allowedLinkSchemes?: ReadonlyArray<string>;
|
|
2413
|
+
/** Compact density tightens vertical rhythm — useful for inline AI summaries. */
|
|
2414
|
+
density?: 'compact' | 'comfortable';
|
|
2415
|
+
}
|
|
2416
|
+
/**
|
|
2417
|
+
* Lightweight, dependency-free markdown renderer for AI narratives, report
|
|
2418
|
+
* sections, and bulletin bodies. Safe by default — raw HTML in the source is
|
|
2419
|
+
* rendered as text (never injected), and `javascript:` links are dropped.
|
|
2420
|
+
*
|
|
2421
|
+
* Supports: ATX headings (`#`..`######`), paragraphs, **bold**, *italic*,
|
|
2422
|
+
* ~~strike~~, `inline code`, fenced ``` code blocks ```, blockquotes, ordered
|
|
2423
|
+
* + unordered lists (flat), `[links](url)`, horizontal rules, hard line breaks.
|
|
2424
|
+
*
|
|
2425
|
+
* Intentional non-features (v1): tables, nested lists, footnotes, images. If
|
|
2426
|
+
* you need any of those, lift to a heavier renderer (TipTap / react-markdown).
|
|
2427
|
+
*/
|
|
2428
|
+
declare const MarkdownRenderer: React$1.ForwardRefExoticComponent<MarkdownRendererProps & React$1.RefAttributes<HTMLDivElement>>;
|
|
2429
|
+
|
|
2430
|
+
interface TaskListGroup {
|
|
2431
|
+
/** Stable group identifier — used to bucket items and as a React key. */
|
|
2432
|
+
id: string;
|
|
2433
|
+
/** Heading shown above the column / group section. */
|
|
2434
|
+
label: React$1.ReactNode;
|
|
2435
|
+
/** Optional accent token CSS variable (e.g. `--status-warning`) for the column rail. */
|
|
2436
|
+
accent?: string;
|
|
2437
|
+
/** Optional override for the empty state inside this group. */
|
|
2438
|
+
emptyState?: React$1.ReactNode;
|
|
2439
|
+
}
|
|
2440
|
+
interface TaskListProps<T> extends Omit<React$1.HTMLAttributes<HTMLDivElement>, 'children' | 'onSelect'> {
|
|
2441
|
+
/** Items to render. Order is preserved within each group. */
|
|
2442
|
+
items: ReadonlyArray<T>;
|
|
2443
|
+
/**
|
|
2444
|
+
* Layout — `kanban` renders one column per group with horizontal scroll;
|
|
2445
|
+
* `flat` renders a single ordered list with sticky group headings.
|
|
2446
|
+
* @default 'kanban'
|
|
2447
|
+
*/
|
|
2448
|
+
variant?: 'kanban' | 'flat';
|
|
2449
|
+
/**
|
|
2450
|
+
* Explicit group definitions. When omitted, groups are auto-derived from the
|
|
2451
|
+
* unique `groupBy(item)` values in document order. Pass an array to control
|
|
2452
|
+
* column ordering, labels, or to render columns with no items today.
|
|
2453
|
+
*/
|
|
2454
|
+
groups?: ReadonlyArray<TaskListGroup>;
|
|
2455
|
+
/** Function returning the group id for an item. */
|
|
2456
|
+
groupBy: (item: T) => string;
|
|
2457
|
+
/** Renders a single item card. Receives the resolved group for context. */
|
|
2458
|
+
renderItem: (item: T, group: TaskListGroup) => React$1.ReactNode;
|
|
2459
|
+
/** Stable React key per item. */
|
|
2460
|
+
getItemKey: (item: T, index: number) => React$1.Key;
|
|
2461
|
+
/** Default empty state when a group has no items. */
|
|
2462
|
+
emptyState?: React$1.ReactNode;
|
|
2463
|
+
/**
|
|
2464
|
+
* Show the item count next to each group heading. @default true.
|
|
2465
|
+
*/
|
|
2466
|
+
showCounts?: boolean;
|
|
2467
|
+
/** Locale for default empty / count strings. @default 'fa' */
|
|
2468
|
+
locale?: SupportedLocale;
|
|
2469
|
+
}
|
|
2470
|
+
declare const TaskList: <T>(props: TaskListProps<T> & {
|
|
2471
|
+
ref?: React$1.ForwardedRef<HTMLDivElement>;
|
|
2472
|
+
}) => React$1.ReactElement;
|
|
2473
|
+
|
|
2474
|
+
type RegionPickerKey = 'slug' | 'iso';
|
|
2475
|
+
interface RegionPickerProps {
|
|
2476
|
+
/** Selected province identifiers (slug or iso, depending on `keyBy`). */
|
|
2477
|
+
value?: ReadonlyArray<string>;
|
|
2478
|
+
onValueChange?: (next: string[]) => void;
|
|
2479
|
+
/**
|
|
2480
|
+
* Which identifier to read/write — `slug` (e.g. `tehran`) is URL-friendly,
|
|
2481
|
+
* `iso` (`IR-07`) is the ISO 3166-2 standard. @default 'slug'
|
|
2482
|
+
*/
|
|
2483
|
+
keyBy?: RegionPickerKey;
|
|
2484
|
+
/** Locale for province labels + UI strings. @default 'fa' */
|
|
2485
|
+
locale?: SupportedLocale;
|
|
2486
|
+
/** Restrict the choosable list (e.g. only show provinces with bureaus). */
|
|
2487
|
+
includeSlugs?: ReadonlyArray<IranProvinceSlug>;
|
|
2488
|
+
/** Excluded slugs — applied after `includeSlugs`. */
|
|
2489
|
+
excludeSlugs?: ReadonlyArray<IranProvinceSlug>;
|
|
2490
|
+
/** Trigger placeholder. */
|
|
2491
|
+
placeholder?: string;
|
|
2492
|
+
/** Search-input placeholder. */
|
|
2493
|
+
searchPlaceholder?: string;
|
|
2494
|
+
/** Empty-state message when search yields no results. */
|
|
2495
|
+
emptyMessage?: string;
|
|
2496
|
+
/** Cap on selections — e.g. `1` to make it a single-province picker. */
|
|
2497
|
+
maxSelected?: number;
|
|
2498
|
+
/** How many selected chips to render before collapsing into a "+N" badge. */
|
|
2499
|
+
maxDisplayed?: number;
|
|
2500
|
+
disabled?: boolean;
|
|
2501
|
+
className?: string;
|
|
2502
|
+
}
|
|
2503
|
+
/**
|
|
2504
|
+
* Multi-select picker over Iran's 31 provinces. Source of truth is
|
|
2505
|
+
* `IRAN_PROVINCES`; the picker projects it through the active locale and
|
|
2506
|
+
* surfaces it via `MultiSelect`.
|
|
2507
|
+
*
|
|
2508
|
+
* Pair with `IranProvinceHeat` for province-scoped افکارسنجی dashboards. A
|
|
2509
|
+
* proper SVG geomap selector is deferred (Phase 5.4).
|
|
2510
|
+
*/
|
|
2511
|
+
declare const RegionPicker: React$1.ForwardRefExoticComponent<RegionPickerProps & React$1.RefAttributes<HTMLDivElement>>;
|
|
2512
|
+
|
|
2513
|
+
interface CountryPickerProps {
|
|
2514
|
+
/** Selected ISO 3166-1 alpha-2 codes (uppercase). */
|
|
2515
|
+
value?: ReadonlyArray<string>;
|
|
2516
|
+
onValueChange?: (next: string[]) => void;
|
|
2517
|
+
/**
|
|
2518
|
+
* Override the country list. Defaults to the curated 80-country roster in
|
|
2519
|
+
* `lib/countries.ts`. Pass your own when you need a fuller ISO 3166 set or
|
|
2520
|
+
* a sub-region (e.g. only EU members).
|
|
2521
|
+
*/
|
|
2522
|
+
options?: ReadonlyArray<Country>;
|
|
2523
|
+
/** Restrict the curated default list to these codes. */
|
|
2524
|
+
includeCodes?: ReadonlyArray<string>;
|
|
2525
|
+
/** Excluded codes — applied after `includeCodes`. */
|
|
2526
|
+
excludeCodes?: ReadonlyArray<string>;
|
|
2527
|
+
/** Show flag emoji prefix on each option. @default true */
|
|
2528
|
+
showFlag?: boolean;
|
|
2529
|
+
/** Locale for labels + UI strings. @default 'fa' */
|
|
2530
|
+
locale?: SupportedLocale;
|
|
2531
|
+
placeholder?: string;
|
|
2532
|
+
searchPlaceholder?: string;
|
|
2533
|
+
emptyMessage?: string;
|
|
2534
|
+
/** Cap on selections — e.g. `1` for a single-country picker. */
|
|
2535
|
+
maxSelected?: number;
|
|
2536
|
+
/** Selected chips before collapsing into "+N" badge. */
|
|
2537
|
+
maxDisplayed?: number;
|
|
2538
|
+
disabled?: boolean;
|
|
2539
|
+
className?: string;
|
|
2540
|
+
}
|
|
2541
|
+
/**
|
|
2542
|
+
* Multi-select picker over a curated country list. Defaults to the 80
|
|
2543
|
+
* countries that recur in افکارسنجی + influencer dashboards we serve; pass
|
|
2544
|
+
* `options` to replace the dataset with your own.
|
|
2545
|
+
*
|
|
2546
|
+
* Returns ISO 3166-1 alpha-2 codes (uppercase). Pair with platform tokens +
|
|
2547
|
+
* the audience graph for influencer geographic breakdowns.
|
|
2548
|
+
*/
|
|
2549
|
+
declare const CountryPicker: React$1.ForwardRefExoticComponent<CountryPickerProps & React$1.RefAttributes<HTMLDivElement>>;
|
|
2550
|
+
|
|
2551
|
+
declare function Menubar({ className, dir, ...props }: React$1.ComponentProps<typeof MenubarPrimitive.Root>): react_jsx_runtime.JSX.Element;
|
|
2788
2552
|
declare namespace Menubar {
|
|
2789
2553
|
var displayName: string;
|
|
2790
2554
|
}
|
|
@@ -2928,7 +2692,7 @@ declare namespace NativeSelectOptGroup {
|
|
|
2928
2692
|
var displayName: string;
|
|
2929
2693
|
}
|
|
2930
2694
|
|
|
2931
|
-
declare function NavigationMenu({ className, children, viewport, ...props }: React$1.ComponentProps<typeof NavigationMenuPrimitive.Root> & {
|
|
2695
|
+
declare function NavigationMenu({ className, children, viewport, dir, ...props }: React$1.ComponentProps<typeof NavigationMenuPrimitive.Root> & {
|
|
2932
2696
|
viewport?: boolean;
|
|
2933
2697
|
}): react_jsx_runtime.JSX.Element;
|
|
2934
2698
|
declare namespace NavigationMenu {
|
|
@@ -2964,100 +2728,6 @@ declare namespace NavigationMenuIndicator {
|
|
|
2964
2728
|
var displayName: string;
|
|
2965
2729
|
}
|
|
2966
2730
|
|
|
2967
|
-
type SocialPlatform = 'instagram' | 'twitter' | 'tiktok' | 'youtube' | 'linkedin' | 'telegram' | 'threads';
|
|
2968
|
-
interface SocialPlatformBadgeProps extends React$1.HTMLAttributes<HTMLSpanElement> {
|
|
2969
|
-
/** The social media platform to display */
|
|
2970
|
-
platform: SocialPlatform;
|
|
2971
|
-
/** Size of the badge */
|
|
2972
|
-
size?: 'xs' | 'sm' | 'md' | 'lg';
|
|
2973
|
-
/** Show the platform name label */
|
|
2974
|
-
showLabel?: boolean;
|
|
2975
|
-
/** Visual style of the badge */
|
|
2976
|
-
variant?: 'flat' | 'badge';
|
|
2977
|
-
}
|
|
2978
|
-
declare const socialPlatformBadgeVariants: (props?: ({
|
|
2979
|
-
size?: "xs" | "sm" | "md" | "lg" | null | undefined;
|
|
2980
|
-
variant?: "flat" | "badge" | null | undefined;
|
|
2981
|
-
} & class_variance_authority_types.ClassProp) | undefined) => string;
|
|
2982
|
-
declare const SocialPlatformBadge: React$1.ForwardRefExoticComponent<SocialPlatformBadgeProps & React$1.RefAttributes<HTMLSpanElement>>;
|
|
2983
|
-
|
|
2984
|
-
type BotDetectionKey = 'real' | 'suspicious' | 'bot';
|
|
2985
|
-
interface BotDetectionData {
|
|
2986
|
-
/** Confirmed real / human accounts */
|
|
2987
|
-
real: number;
|
|
2988
|
-
/** Suspicious — insufficient signal, possibly bot */
|
|
2989
|
-
suspicious: number;
|
|
2990
|
-
/** Confirmed bot / automated */
|
|
2991
|
-
bot: number;
|
|
2992
|
-
}
|
|
2993
|
-
interface BotDetectionMeterProps extends React$1.HTMLAttributes<HTMLDivElement> {
|
|
2994
|
-
/** Counts — auto-normalised to percentages that sum to exactly 100 */
|
|
2995
|
-
data: BotDetectionData;
|
|
2996
|
-
/** Display mode @default "stacked" */
|
|
2997
|
-
variant?: 'stacked' | 'bars' | 'compact';
|
|
2998
|
-
/** Show numeric count labels */
|
|
2999
|
-
showCounts?: boolean;
|
|
3000
|
-
/** Show percentage labels @default true */
|
|
3001
|
-
showPercent?: boolean;
|
|
3002
|
-
/** Show the top "Real-account rate" summary line (stacked variant only) @default true */
|
|
3003
|
-
showSummary?: boolean;
|
|
3004
|
-
/** Size of the stacked bar or individual bars */
|
|
3005
|
-
size?: 'sm' | 'md' | 'lg';
|
|
3006
|
-
/** Locale for digits + default labels @default "fa" */
|
|
3007
|
-
locale?: SupportedLocale;
|
|
3008
|
-
}
|
|
3009
|
-
declare const BotDetectionMeter: React$1.ForwardRefExoticComponent<BotDetectionMeterProps & React$1.RefAttributes<HTMLDivElement>>;
|
|
3010
|
-
|
|
3011
|
-
/**
|
|
3012
|
-
* PageCard (government-flavor) — tracked-account tile for افکارسنجی pages
|
|
3013
|
-
* dashboards. Composes: avatar + handle + platform badge, status (healthy/
|
|
3014
|
-
* degrading/at-risk via StatusKey), follower trend sparkline, engagement
|
|
3015
|
-
* stats, content-type mix, bot-detection percentages.
|
|
3016
|
-
*
|
|
3017
|
-
* Distinct from `ProfileCard` which is influencer-flavored (focus on
|
|
3018
|
-
* engagement tier, follower count, avatar). PageCard is for **tracked
|
|
3019
|
-
* accounts** in monitoring — health and trust signals matter most.
|
|
3020
|
-
*/
|
|
3021
|
-
interface PageCardContentMix {
|
|
3022
|
-
/** Photo posts in window (count or %) */
|
|
3023
|
-
photo?: number;
|
|
3024
|
-
/** Video posts in window */
|
|
3025
|
-
video?: number;
|
|
3026
|
-
/** Carousel posts */
|
|
3027
|
-
carousel?: number;
|
|
3028
|
-
/** Story / reel count */
|
|
3029
|
-
story?: number;
|
|
3030
|
-
}
|
|
3031
|
-
interface PageCardProps extends React$1.HTMLAttributes<HTMLDivElement> {
|
|
3032
|
-
/** Account handle / display name (e.g., "@news_agency") */
|
|
3033
|
-
handle: React$1.ReactNode;
|
|
3034
|
-
/** Optional secondary subtitle (e.g., page category) */
|
|
3035
|
-
subtitle?: React$1.ReactNode;
|
|
3036
|
-
/** Avatar URL */
|
|
3037
|
-
avatarSrc?: string;
|
|
3038
|
-
/** Platform — drives the platform badge */
|
|
3039
|
-
platform?: SocialPlatform;
|
|
3040
|
-
/** Operational status (healthy/degrading/at-risk) — uses StatusKey */
|
|
3041
|
-
status?: StatusKey;
|
|
3042
|
-
/** Total followers (current snapshot) */
|
|
3043
|
-
followers?: number;
|
|
3044
|
-
/** Follower-trend sparkline values */
|
|
3045
|
-
followerTrend?: number[];
|
|
3046
|
-
/** Engagement rate (%) */
|
|
3047
|
-
engagementRate?: number;
|
|
3048
|
-
/** Posts per week (recent average) */
|
|
3049
|
-
postsPerWeek?: number;
|
|
3050
|
-
/** Content-type mix (counts or percents) */
|
|
3051
|
-
contentMix?: PageCardContentMix;
|
|
3052
|
-
/** Bot-detection breakdown (real / suspicious / bot) */
|
|
3053
|
-
botDetection?: BotDetectionData;
|
|
3054
|
-
/** Make the entire card clickable */
|
|
3055
|
-
interactive?: boolean;
|
|
3056
|
-
/** Locale @default 'fa' */
|
|
3057
|
-
locale?: SupportedLocale;
|
|
3058
|
-
}
|
|
3059
|
-
declare const PageCard: React$1.ForwardRefExoticComponent<PageCardProps & React$1.RefAttributes<HTMLDivElement>>;
|
|
3060
|
-
|
|
3061
2731
|
interface PageHeaderProps extends React$1.HTMLAttributes<HTMLDivElement> {
|
|
3062
2732
|
/** Page title */
|
|
3063
2733
|
title: string;
|
|
@@ -3163,11 +2833,6 @@ interface PaginationControlledProps {
|
|
|
3163
2833
|
*/
|
|
3164
2834
|
declare const PaginationControlled: React$1.ForwardRefExoticComponent<PaginationControlledProps & React$1.RefAttributes<HTMLElement>>;
|
|
3165
2835
|
|
|
3166
|
-
declare const Popover: React$1.FC<PopoverPrimitive.PopoverProps>;
|
|
3167
|
-
declare const PopoverTrigger: React$1.ForwardRefExoticComponent<PopoverPrimitive.PopoverTriggerProps & React$1.RefAttributes<HTMLButtonElement>>;
|
|
3168
|
-
declare const PopoverAnchor: React$1.ForwardRefExoticComponent<PopoverPrimitive.PopoverAnchorProps & React$1.RefAttributes<HTMLDivElement>>;
|
|
3169
|
-
declare const PopoverContent: React$1.ForwardRefExoticComponent<Omit<PopoverPrimitive.PopoverContentProps & React$1.RefAttributes<HTMLDivElement>, "ref"> & React$1.RefAttributes<HTMLDivElement>>;
|
|
3170
|
-
|
|
3171
2836
|
/**
|
|
3172
2837
|
* PartoHeatMap — brand-tinted heatmap with rounded cells, clean axis,
|
|
3173
2838
|
* glassmorphic tooltip, and locale-aware formatting.
|
|
@@ -3212,6 +2877,15 @@ interface PartoHeatMapProps {
|
|
|
3212
2877
|
yAxisLabel?: string;
|
|
3213
2878
|
/** Filter which x-axis ticks to show */
|
|
3214
2879
|
xTickFilter?: (value: string | number, index: number) => boolean;
|
|
2880
|
+
/**
|
|
2881
|
+
* Render a continuous-gradient legend below the heatmap that maps the
|
|
2882
|
+
* color intensity to a [min, max] value range. The bar uses the same
|
|
2883
|
+
* `colorScale` the cells use, so the gradient matches the data exactly.
|
|
2884
|
+
* @default `false`
|
|
2885
|
+
*/
|
|
2886
|
+
legend?: boolean;
|
|
2887
|
+
/** Caption shown above the gradient bar when `legend` is on (e.g. "تراکم انتشار"). */
|
|
2888
|
+
legendCaption?: React$1.ReactNode;
|
|
3215
2889
|
}
|
|
3216
2890
|
declare const PartoHeatMap: React$1.ForwardRefExoticComponent<PartoHeatMapProps & React$1.RefAttributes<HTMLDivElement>>;
|
|
3217
2891
|
|
|
@@ -3274,64 +2948,162 @@ interface PostingFrequencyHeatmapProps extends Omit<React$1.HTMLAttributes<HTMLD
|
|
|
3274
2948
|
declare const PostingFrequencyHeatmap: React$1.ForwardRefExoticComponent<PostingFrequencyHeatmapProps & React$1.RefAttributes<HTMLDivElement>>;
|
|
3275
2949
|
|
|
3276
2950
|
/**
|
|
3277
|
-
*
|
|
3278
|
-
*
|
|
3279
|
-
*
|
|
2951
|
+
* The full set of sources a post can originate from in Parto's social-listening +
|
|
2952
|
+
* افکارسنجی pipeline. Extends `SocialPlatform` (7 social networks) with broadcast
|
|
2953
|
+
* (tv, radio) and editorial (press, web) sources.
|
|
2954
|
+
*/
|
|
2955
|
+
type PostSource = SocialPlatform | 'tv' | 'radio' | 'press' | 'web';
|
|
2956
|
+
/** High-level grouping that drives header layout and default metric ordering. */
|
|
2957
|
+
type PostSourceCategory = 'social' | 'broadcast' | 'editorial';
|
|
2958
|
+
/**
|
|
2959
|
+
* Derive the source category from a `PostSource` value.
|
|
2960
|
+
* Used internally by `<PostHeader>`, metric label helpers, and default-actions config.
|
|
2961
|
+
*/
|
|
2962
|
+
declare function sourceCategory(source: PostSource): PostSourceCategory;
|
|
2963
|
+
/**
|
|
2964
|
+
* @deprecated Use {@link PostSource} for new code. `PostPlatform` is retained with its
|
|
2965
|
+
* historical meaning (the 7 social networks only) so existing components that target
|
|
2966
|
+
* social-specific APIs (e.g. `<SocialPlatformBadge>`) keep their narrow contract.
|
|
2967
|
+
* `PostSource` is the expanded superset (adds tv / radio / press / web).
|
|
3280
2968
|
*/
|
|
3281
2969
|
type PostPlatform = SocialPlatform;
|
|
2970
|
+
/**
|
|
2971
|
+
* `view` is the canonical PostList render mode. `compact` and `comfortable` are the
|
|
2972
|
+
* pre-existing densities; `grid` is the new magazine/visual layout.
|
|
2973
|
+
*/
|
|
2974
|
+
type PostView = 'compact' | 'comfortable' | 'grid';
|
|
2975
|
+
/**
|
|
2976
|
+
* @deprecated Use {@link PostView} instead. `density` is the legacy two-value alias
|
|
2977
|
+
* (compact | comfortable) kept for backward compatibility with PostCard / PostList.
|
|
2978
|
+
*/
|
|
3282
2979
|
type PostDensity = 'compact' | 'comfortable';
|
|
3283
2980
|
type PostSentiment = 'positive' | 'negative' | 'neutral' | 'mixed';
|
|
2981
|
+
type PostEmotion = 'anger' | 'anticipation' | 'joy' | 'trust' | 'fear' | 'surprise' | 'sadness' | 'disgust' | 'neutral';
|
|
2982
|
+
/** Political flow classification — see CLAUDE.md domain concepts. */
|
|
2983
|
+
type PostFlow = 'pro-gov' | 'internal-critic' | 'internal-opponent' | 'external-opponent' | 'grey';
|
|
2984
|
+
type PostSeverity = 'low' | 'medium' | 'high' | 'critical';
|
|
2985
|
+
type PostStatus = 'normal' | 'warning' | 'critical';
|
|
2986
|
+
type PostAuthorityTier = 'nano' | 'micro' | 'macro' | 'mega';
|
|
3284
2987
|
interface PostAuthor {
|
|
3285
2988
|
name: string;
|
|
3286
2989
|
handle?: string;
|
|
3287
2990
|
avatarUrl?: string;
|
|
3288
2991
|
verified?: boolean;
|
|
3289
|
-
/** Optional follower / subscriber count
|
|
2992
|
+
/** Optional follower / subscriber count. */
|
|
3290
2993
|
followers?: number;
|
|
3291
|
-
|
|
3292
|
-
|
|
3293
|
-
|
|
3294
|
-
|
|
3295
|
-
comments?: number;
|
|
3296
|
-
shares?: number;
|
|
3297
|
-
/** Estimated reach / potential audience. */
|
|
3298
|
-
reach?: number;
|
|
3299
|
-
/** Engagement rate as a 0..1 decimal (e.g. 0.034 = 3.4%). */
|
|
3300
|
-
engagementRate?: number;
|
|
3301
|
-
}
|
|
3302
|
-
interface PostTag {
|
|
3303
|
-
id: string;
|
|
3304
|
-
label: string;
|
|
3305
|
-
/** Optional CSS var (e.g. `--chart-1`) or hex color. Auto-assigned from label if omitted. */
|
|
3306
|
-
color?: string;
|
|
2994
|
+
/** Influence score 0..100 — used to render the authority chip on the card. */
|
|
2995
|
+
authorityScore?: number;
|
|
2996
|
+
/** Categorical author tier inferred from follower count + engagement. */
|
|
2997
|
+
authorityTier?: PostAuthorityTier;
|
|
3307
2998
|
}
|
|
3308
2999
|
/**
|
|
3309
|
-
*
|
|
3310
|
-
*
|
|
3000
|
+
* Editorial / broadcast actor. Used when the post originates from press, web, tv, radio
|
|
3001
|
+
* instead of an individual social-platform account.
|
|
3311
3002
|
*/
|
|
3312
|
-
interface
|
|
3313
|
-
|
|
3314
|
-
|
|
3315
|
-
|
|
3316
|
-
|
|
3003
|
+
interface PostOutlet {
|
|
3004
|
+
name: string;
|
|
3005
|
+
logoUrl?: string;
|
|
3006
|
+
/** Editorial only: web domain ("hamshahrionline.ir"). */
|
|
3007
|
+
domain?: string;
|
|
3008
|
+
/** Editorial only: 0..100 SEO/credibility signal. */
|
|
3009
|
+
domainAuthority?: number;
|
|
3010
|
+
/** Broadcast only: TV channel or radio station ("شبکه ۱", "رادیو پیام"). */
|
|
3011
|
+
channel?: string;
|
|
3012
|
+
/** Broadcast only: program / show name. */
|
|
3013
|
+
program?: string;
|
|
3014
|
+
/** Editorial only: byline / journalist name. */
|
|
3015
|
+
reporterName?: string;
|
|
3317
3016
|
}
|
|
3017
|
+
/**
|
|
3018
|
+
* Per-item ingestion status. Drives how `<PostMedia>` renders each item:
|
|
3019
|
+
* - `ready`: image/video/audio is downloaded and viewable.
|
|
3020
|
+
* - `loading`: the panel is fetching the media right now — render a shimmer.
|
|
3021
|
+
* - `failed`: download failed — render retry placeholder.
|
|
3022
|
+
* - `unavailable`: source has media but we never captured it — render "ذخیره نشده" placeholder.
|
|
3023
|
+
*/
|
|
3024
|
+
type PostMediaStatus = 'ready' | 'loading' | 'failed' | 'unavailable';
|
|
3025
|
+
/** Sensitive-content classifications. Used at media-level and post-level. */
|
|
3026
|
+
type PostMediaSensitivity = 'nsfw' | 'graphic' | 'spoiler';
|
|
3318
3027
|
interface PostMediaItem {
|
|
3319
3028
|
url: string;
|
|
3320
3029
|
thumbnailUrl?: string;
|
|
3321
|
-
/** Natural aspect ratio (width / height).
|
|
3030
|
+
/** Natural aspect ratio (width / height). Defaults to 1. */
|
|
3322
3031
|
aspectRatio?: number;
|
|
3323
3032
|
alt?: string;
|
|
3324
|
-
type?: 'image' | 'video';
|
|
3325
|
-
/** Duration in seconds for video. */
|
|
3033
|
+
type?: 'image' | 'video' | 'audio';
|
|
3034
|
+
/** Duration in seconds for video / audio. */
|
|
3326
3035
|
duration?: number;
|
|
3036
|
+
/** Ingestion status. Defaults to 'ready'. */
|
|
3037
|
+
status?: PostMediaStatus;
|
|
3038
|
+
/** Sensitivity tag — if set, the renderer blurs the media until revealed. */
|
|
3039
|
+
sensitivity?: PostMediaSensitivity;
|
|
3040
|
+
/** Audio only: URL of a waveform peaks file or a pre-rendered SVG / inline data URI. */
|
|
3041
|
+
waveformUrl?: string;
|
|
3042
|
+
}
|
|
3043
|
+
/** Open Graph–style URL preview embedded inside a text body. */
|
|
3044
|
+
interface PostUrlPreview {
|
|
3045
|
+
url: string;
|
|
3046
|
+
domain: string;
|
|
3047
|
+
title?: string;
|
|
3048
|
+
description?: string;
|
|
3049
|
+
thumbnailUrl?: string;
|
|
3050
|
+
}
|
|
3051
|
+
/**
|
|
3052
|
+
* Sticker overlays found on Instagram stories (mentions, polls, location, music, etc.).
|
|
3053
|
+
* Captured to preserve story context after crawling. Coordinates are normalized 0..1.
|
|
3054
|
+
*/
|
|
3055
|
+
interface StoryStickerOverlay {
|
|
3056
|
+
/** Type of sticker — drives the icon and label in `<PostMediaStory>`. */
|
|
3057
|
+
type: 'mention' | 'location' | 'hashtag' | 'music' | 'poll' | 'question' | 'time' | 'link' | 'other';
|
|
3058
|
+
/** Human-readable label (e.g. "@digikala", "Tehran", "#خرید_آنلاین"). */
|
|
3059
|
+
label: string;
|
|
3060
|
+
/** Optional secondary text — for polls/questions, the question text. */
|
|
3061
|
+
secondaryText?: string;
|
|
3062
|
+
/** Normalized x/y position on the story canvas (0..1). */
|
|
3063
|
+
x?: number;
|
|
3064
|
+
y?: number;
|
|
3065
|
+
}
|
|
3066
|
+
/** Per-story metadata extracted at crawl time. */
|
|
3067
|
+
interface StoryItem {
|
|
3068
|
+
/** The captured media (image or video). */
|
|
3069
|
+
media: PostMediaItem;
|
|
3070
|
+
/** OCR-extracted text from the story canvas (visible Persian/English text). */
|
|
3071
|
+
ocrText?: string;
|
|
3072
|
+
/** Transcript for video stories. */
|
|
3073
|
+
transcript?: string;
|
|
3074
|
+
/** Story sticker overlays (mentions, polls, location, etc.). */
|
|
3075
|
+
stickers?: StoryStickerOverlay[];
|
|
3076
|
+
/** Story publication time — distinct from the post wrapper's timestamp. */
|
|
3077
|
+
publishedAt?: Date | string | number;
|
|
3078
|
+
/** Outbound "swipe up" / link sticker URL. */
|
|
3079
|
+
swipeUpUrl?: string;
|
|
3080
|
+
/** Story view count (Stories use viewers, not likes). */
|
|
3081
|
+
viewCount?: number;
|
|
3327
3082
|
}
|
|
3083
|
+
/**
|
|
3084
|
+
* Discriminated union of body shapes. The renderer in `<PostBody>` switches on `type`.
|
|
3085
|
+
*
|
|
3086
|
+
* Story-related variants:
|
|
3087
|
+
* - `story` — single ephemeral story (9:16, OCR text overlay, optional swipe-up link)
|
|
3088
|
+
* - `highlight` — saved-story collection under a titled cover; renders as a strip of stories
|
|
3089
|
+
* Other social media coverage:
|
|
3090
|
+
* - `media-grid`, `media-carousel`, `video`, `audio`, `text` — generic
|
|
3091
|
+
* Failure states:
|
|
3092
|
+
* - `missing-media`, `source-removed`
|
|
3093
|
+
*/
|
|
3328
3094
|
type PostBodyData = {
|
|
3329
3095
|
type: 'text';
|
|
3330
3096
|
text: string;
|
|
3097
|
+
urlPreview?: PostUrlPreview;
|
|
3331
3098
|
} | {
|
|
3332
3099
|
type: 'media-single';
|
|
3333
3100
|
media: PostMediaItem;
|
|
3334
3101
|
caption?: string;
|
|
3102
|
+
urlPreview?: PostUrlPreview;
|
|
3103
|
+
} | {
|
|
3104
|
+
type: 'media-grid';
|
|
3105
|
+
items: PostMediaItem[];
|
|
3106
|
+
caption?: string;
|
|
3335
3107
|
} | {
|
|
3336
3108
|
type: 'media-carousel';
|
|
3337
3109
|
items: PostMediaItem[];
|
|
@@ -3340,85 +3112,141 @@ type PostBodyData = {
|
|
|
3340
3112
|
type: 'video';
|
|
3341
3113
|
media: PostMediaItem;
|
|
3342
3114
|
caption?: string;
|
|
3115
|
+
} | {
|
|
3116
|
+
type: 'audio';
|
|
3117
|
+
media: PostMediaItem;
|
|
3118
|
+
caption?: string;
|
|
3119
|
+
} | {
|
|
3120
|
+
type: 'story';
|
|
3121
|
+
story: StoryItem;
|
|
3122
|
+
caption?: string;
|
|
3123
|
+
} | {
|
|
3124
|
+
type: 'highlight';
|
|
3125
|
+
title: string;
|
|
3126
|
+
coverUrl?: string;
|
|
3127
|
+
stories: StoryItem[];
|
|
3128
|
+
caption?: string;
|
|
3343
3129
|
} | {
|
|
3344
3130
|
type: 'missing-media';
|
|
3345
3131
|
caption?: string;
|
|
3346
3132
|
reason?: string;
|
|
3133
|
+
} | {
|
|
3134
|
+
type: 'source-removed';
|
|
3135
|
+
archivedAt?: Date | string | number;
|
|
3136
|
+
archiveUrl?: string;
|
|
3137
|
+
caption?: string;
|
|
3347
3138
|
};
|
|
3348
|
-
|
|
3349
|
-
|
|
3350
|
-
|
|
3351
|
-
|
|
3352
|
-
|
|
3353
|
-
|
|
3354
|
-
|
|
3355
|
-
|
|
3356
|
-
|
|
3357
|
-
|
|
3358
|
-
/**
|
|
3359
|
-
|
|
3360
|
-
/**
|
|
3361
|
-
|
|
3362
|
-
/**
|
|
3363
|
-
|
|
3364
|
-
/**
|
|
3365
|
-
|
|
3139
|
+
/**
|
|
3140
|
+
* Unified metric envelope. Labels are platform-aware via `getMetricLabel(source, key, locale)`;
|
|
3141
|
+
* the same `views` field is rendered as "بازدید" (Instagram/YouTube), "تماشا" (TikTok),
|
|
3142
|
+
* "نمایش" (X), "بیننده" (TV), "شنونده" (Radio) depending on the post's source.
|
|
3143
|
+
*/
|
|
3144
|
+
interface PostMetrics {
|
|
3145
|
+
/** Generic "consumption" metric — viewers / impressions / plays / page-views. */
|
|
3146
|
+
views?: number;
|
|
3147
|
+
likes?: number;
|
|
3148
|
+
comments?: number;
|
|
3149
|
+
/** Generic share count. */
|
|
3150
|
+
shares?: number;
|
|
3151
|
+
/** Reposts: X retweets, Threads reposts, Telegram forwards. */
|
|
3152
|
+
reposts?: number;
|
|
3153
|
+
/** Quote-with-comment: X quote-tweets, Threads quotes. */
|
|
3154
|
+
quotes?: number;
|
|
3155
|
+
/** Saves/bookmarks: IG, TikTok, LinkedIn. */
|
|
3156
|
+
saves?: number;
|
|
3157
|
+
/** Estimated reach / potential audience. */
|
|
3158
|
+
reach?: number;
|
|
3159
|
+
/** Engagement rate as 0..1 decimal (e.g. 0.034 = 3.4%). */
|
|
3160
|
+
engagementRate?: number;
|
|
3161
|
+
/** Broadcast: TV viewers / Radio listeners. Editorial: readers. One field, label per source. */
|
|
3162
|
+
audience?: number;
|
|
3163
|
+
/** Editorial: actual page-views distinct from `views`. */
|
|
3164
|
+
reads?: number;
|
|
3165
|
+
/** Editorial: SEO domain authority signal — also surfaced via `PostOutlet.domainAuthority`. */
|
|
3166
|
+
domainAuthority?: number;
|
|
3167
|
+
/** Reaction breakdown (Telegram emoji, LinkedIn 7-type, Facebook-style). */
|
|
3168
|
+
reactions?: ReactionBreakdown;
|
|
3366
3169
|
}
|
|
3367
|
-
|
|
3170
|
+
/**
|
|
3171
|
+
* Typed reaction breakdown. Sparse — only platforms that emit a given reaction fill it.
|
|
3172
|
+
* LinkedIn fills like/celebrate/support/love/insightful/funny.
|
|
3173
|
+
* Facebook fills like/love/care/haha/wow/sad/angry.
|
|
3174
|
+
* Telegram fills `emoji` with the raw map.
|
|
3175
|
+
*/
|
|
3176
|
+
interface ReactionBreakdown {
|
|
3177
|
+
like?: number;
|
|
3178
|
+
love?: number;
|
|
3179
|
+
celebrate?: number;
|
|
3180
|
+
support?: number;
|
|
3181
|
+
insightful?: number;
|
|
3182
|
+
funny?: number;
|
|
3183
|
+
/** Facebook-only — empathy reaction. */
|
|
3184
|
+
care?: number;
|
|
3185
|
+
/** Facebook-only — laughing reaction. */
|
|
3186
|
+
haha?: number;
|
|
3187
|
+
/** Facebook-only — surprised reaction. */
|
|
3188
|
+
wow?: number;
|
|
3189
|
+
/** Facebook-only — sad reaction. */
|
|
3190
|
+
sad?: number;
|
|
3191
|
+
/** Facebook-only — anger reaction. */
|
|
3192
|
+
angry?: number;
|
|
3193
|
+
/** Raw emoji → count map (Telegram channel reactions). */
|
|
3194
|
+
emoji?: Record<string, number>;
|
|
3195
|
+
}
|
|
3196
|
+
interface PostTag {
|
|
3368
3197
|
id: string;
|
|
3369
3198
|
label: string;
|
|
3370
|
-
|
|
3371
|
-
|
|
3372
|
-
onClick: (post: PostData) => void;
|
|
3373
|
-
disabled?: boolean;
|
|
3374
|
-
hidden?: boolean;
|
|
3199
|
+
/** Optional CSS var (e.g. `--chart-1`) or hex color. Auto-assigned from label if omitted. */
|
|
3200
|
+
color?: string;
|
|
3375
3201
|
}
|
|
3376
|
-
|
|
3377
|
-
|
|
3378
|
-
|
|
3379
|
-
|
|
3380
|
-
|
|
3202
|
+
/**
|
|
3203
|
+
* Flags indicate which enrichments the product has attached to this post.
|
|
3204
|
+
* Consumers set these to show the matching chip in `<PostHeader>`.
|
|
3205
|
+
*/
|
|
3206
|
+
interface PostEnrichmentFlags {
|
|
3207
|
+
ocr?: boolean;
|
|
3208
|
+
transcript?: boolean;
|
|
3209
|
+
aiAnalysis?: boolean;
|
|
3210
|
+
commentCount?: number;
|
|
3381
3211
|
}
|
|
3382
|
-
|
|
3383
|
-
|
|
3384
|
-
|
|
3385
|
-
|
|
3386
|
-
timestamp: Date | string | number;
|
|
3387
|
-
sentiment?: PostSentiment;
|
|
3388
|
-
likes?: number;
|
|
3389
|
-
replies?: PostComment[];
|
|
3390
|
-
/** Pinned by post author (Instagram, YouTube). */
|
|
3212
|
+
/**
|
|
3213
|
+
* Contextual flags surfaced as chips or banners on the card. Independent of media-level status.
|
|
3214
|
+
*/
|
|
3215
|
+
interface PostFlags {
|
|
3391
3216
|
pinned?: boolean;
|
|
3392
|
-
|
|
3393
|
-
|
|
3394
|
-
|
|
3395
|
-
|
|
3396
|
-
|
|
3397
|
-
|
|
3398
|
-
|
|
3399
|
-
|
|
3400
|
-
|
|
3401
|
-
|
|
3402
|
-
|
|
3403
|
-
|
|
3404
|
-
|
|
3405
|
-
|
|
3406
|
-
|
|
3407
|
-
|
|
3408
|
-
|
|
3409
|
-
|
|
3410
|
-
|
|
3411
|
-
|
|
3412
|
-
|
|
3413
|
-
|
|
3414
|
-
|
|
3415
|
-
|
|
3416
|
-
|
|
3417
|
-
|
|
3418
|
-
|
|
3419
|
-
|
|
3217
|
+
edited?: boolean;
|
|
3218
|
+
/** Optional edit count, surfaced in tooltip. */
|
|
3219
|
+
editCount?: number;
|
|
3220
|
+
sponsored?: boolean;
|
|
3221
|
+
/** Post was deleted at source after we ingested it. */
|
|
3222
|
+
deletedAtSource?: boolean;
|
|
3223
|
+
/** Snapshot URL to our archived copy. */
|
|
3224
|
+
archivedSnapshotUrl?: string;
|
|
3225
|
+
/** Post-level sensitivity (distinct from per-media `sensitivity`). */
|
|
3226
|
+
sensitive?: PostMediaSensitivity;
|
|
3227
|
+
}
|
|
3228
|
+
/** Cluster / topic membership — links the post to a parent analytical grouping. */
|
|
3229
|
+
interface PostCluster {
|
|
3230
|
+
id: string;
|
|
3231
|
+
label: string;
|
|
3232
|
+
tone?: 'brand' | 'neutral' | 'warning';
|
|
3233
|
+
}
|
|
3234
|
+
/** "X reposted at Y" wrapper info. */
|
|
3235
|
+
interface PostRepostInfo {
|
|
3236
|
+
by: PostAuthor;
|
|
3237
|
+
at: Date | string | number;
|
|
3238
|
+
/** Optional retweet-with-comment / Telegram forward note. */
|
|
3239
|
+
comment?: string;
|
|
3240
|
+
}
|
|
3241
|
+
/** Position info when a post belongs to a multi-post thread. */
|
|
3242
|
+
interface PostThreadInfo {
|
|
3243
|
+
threadId: string;
|
|
3244
|
+
/** 1-indexed position in the thread. */
|
|
3245
|
+
position: number;
|
|
3246
|
+
total: number;
|
|
3247
|
+
/** Optional id of the next thread post — used to draw the connector to the next visible card. */
|
|
3248
|
+
nextId?: string;
|
|
3420
3249
|
}
|
|
3421
|
-
/** Platform-specific metadata, discriminated by `platform` (matches `PostData.source`). */
|
|
3422
3250
|
type PlatformMetadata = {
|
|
3423
3251
|
platform: 'instagram';
|
|
3424
3252
|
postType?: 'feed' | 'reel' | 'story' | 'carousel' | 'igtv';
|
|
@@ -3429,7 +3257,6 @@ type PlatformMetadata = {
|
|
|
3429
3257
|
};
|
|
3430
3258
|
saveCount?: number;
|
|
3431
3259
|
collaborators?: string[];
|
|
3432
|
-
/** Hashtags used in the post. */
|
|
3433
3260
|
hashtags?: string[];
|
|
3434
3261
|
} | {
|
|
3435
3262
|
platform: 'twitter';
|
|
@@ -3440,7 +3267,6 @@ type PlatformMetadata = {
|
|
|
3440
3267
|
quoteCount?: number;
|
|
3441
3268
|
bookmarkCount?: number;
|
|
3442
3269
|
isThread?: boolean;
|
|
3443
|
-
/** Count of additional posts in the thread. */
|
|
3444
3270
|
threadLength?: number;
|
|
3445
3271
|
} | {
|
|
3446
3272
|
platform: 'youtube';
|
|
@@ -3485,7 +3311,184 @@ type PlatformMetadata = {
|
|
|
3485
3311
|
replyControls?: 'anyone' | 'followed' | 'mentioned';
|
|
3486
3312
|
repostCount?: number;
|
|
3487
3313
|
quoteCount?: number;
|
|
3314
|
+
} | {
|
|
3315
|
+
platform: 'facebook';
|
|
3316
|
+
postType?: 'post' | 'photo' | 'video' | 'reel' | 'story' | 'event' | 'shared';
|
|
3317
|
+
reactions?: {
|
|
3318
|
+
like?: number;
|
|
3319
|
+
love?: number;
|
|
3320
|
+
care?: number;
|
|
3321
|
+
haha?: number;
|
|
3322
|
+
wow?: number;
|
|
3323
|
+
sad?: number;
|
|
3324
|
+
angry?: number;
|
|
3325
|
+
};
|
|
3326
|
+
shareCount?: number;
|
|
3327
|
+
/** Page name if posted on behalf of a page (vs personal profile). */
|
|
3328
|
+
pageName?: string;
|
|
3329
|
+
pageFollowers?: number;
|
|
3330
|
+
} | {
|
|
3331
|
+
platform: 'tv';
|
|
3332
|
+
airDate?: Date | string | number;
|
|
3333
|
+
durationSec?: number;
|
|
3334
|
+
programType?: 'news' | 'talk-show' | 'documentary' | 'interview' | 'live' | 'other';
|
|
3335
|
+
viewers?: number;
|
|
3336
|
+
replays?: number;
|
|
3337
|
+
} | {
|
|
3338
|
+
platform: 'radio';
|
|
3339
|
+
airDate?: Date | string | number;
|
|
3340
|
+
durationSec?: number;
|
|
3341
|
+
programType?: 'news' | 'talk-show' | 'music' | 'interview' | 'live' | 'other';
|
|
3342
|
+
listeners?: number;
|
|
3343
|
+
} | {
|
|
3344
|
+
platform: 'press';
|
|
3345
|
+
printedAt?: Date | string | number;
|
|
3346
|
+
/** Print edition: issue / page reference. */
|
|
3347
|
+
issue?: string;
|
|
3348
|
+
pageNumber?: number;
|
|
3349
|
+
/** Optional AVE (Ad Value Equivalent) — common press metric. */
|
|
3350
|
+
adValueEquivalent?: number;
|
|
3351
|
+
hashtags?: string[];
|
|
3352
|
+
} | {
|
|
3353
|
+
platform: 'web';
|
|
3354
|
+
contentType?: 'blog' | 'forum' | 'news' | 'review' | 'comment' | 'other';
|
|
3355
|
+
/** Reference to a parent thread / discussion if part of one. */
|
|
3356
|
+
threadUrl?: string;
|
|
3357
|
+
hashtags?: string[];
|
|
3488
3358
|
};
|
|
3359
|
+
interface PostData {
|
|
3360
|
+
id: string;
|
|
3361
|
+
/**
|
|
3362
|
+
* Source platform — full 11-source taxonomy (social + broadcast + editorial).
|
|
3363
|
+
* Header layout and metric labels dispatch on this value via `sourceCategory(source)`.
|
|
3364
|
+
*/
|
|
3365
|
+
source: PostSource;
|
|
3366
|
+
/** Headline (editorial), program/segment (broadcast), video title (YouTube). */
|
|
3367
|
+
title?: string;
|
|
3368
|
+
/** Present for social posts; optional for editorial/broadcast where `outlet` is the actor. */
|
|
3369
|
+
author?: PostAuthor;
|
|
3370
|
+
/** Editorial/broadcast outlet — used for press, web, tv, radio header variants. */
|
|
3371
|
+
outlet?: PostOutlet;
|
|
3372
|
+
body: PostBodyData;
|
|
3373
|
+
/** Post creation / publish / air time. Accepts Date, ISO string, or unix ms. */
|
|
3374
|
+
timestamp: Date | string | number;
|
|
3375
|
+
metrics?: PostMetrics;
|
|
3376
|
+
sentiment?: PostSentiment;
|
|
3377
|
+
/** Dominant emotion (9-class) — surfaced as a chip on the card. */
|
|
3378
|
+
emotion?: PostEmotion;
|
|
3379
|
+
/** Political flow classification — surfaced as a chip on the card. */
|
|
3380
|
+
flow?: PostFlow;
|
|
3381
|
+
severity?: PostSeverity;
|
|
3382
|
+
enrichments?: PostEnrichmentFlags;
|
|
3383
|
+
flags?: PostFlags;
|
|
3384
|
+
cluster?: PostCluster;
|
|
3385
|
+
/** User-defined category tags. */
|
|
3386
|
+
tags?: PostTag[];
|
|
3387
|
+
/** @deprecated Use `author.authorityScore` instead. Kept for backward compat. */
|
|
3388
|
+
authorityScore?: number;
|
|
3389
|
+
/** ISO language code detected for the post. */
|
|
3390
|
+
language?: string;
|
|
3391
|
+
/** URL to the post at the source platform. */
|
|
3392
|
+
sourceUrl?: string;
|
|
3393
|
+
/** Quoted/embedded post (X quote-tweets, Threads quotes, Telegram forwards-with-comment). */
|
|
3394
|
+
quoted?: PostData;
|
|
3395
|
+
/** Parent post when this is a reply. */
|
|
3396
|
+
parent?: PostData;
|
|
3397
|
+
/** Repost wrapper info — when present, render "X reposted" header strip above the card. */
|
|
3398
|
+
reposted?: PostRepostInfo;
|
|
3399
|
+
/** Thread position info — when present, draw the thread-connector hairline. */
|
|
3400
|
+
thread?: PostThreadInfo;
|
|
3401
|
+
/** Platform-specific metadata block (discriminated by source). */
|
|
3402
|
+
platformMeta?: PlatformMetadata;
|
|
3403
|
+
}
|
|
3404
|
+
interface PostAction {
|
|
3405
|
+
id: string;
|
|
3406
|
+
label: string;
|
|
3407
|
+
icon: LucideIcon;
|
|
3408
|
+
variant?: 'default' | 'danger';
|
|
3409
|
+
onClick: (post: PostData) => void;
|
|
3410
|
+
disabled?: boolean;
|
|
3411
|
+
hidden?: boolean;
|
|
3412
|
+
}
|
|
3413
|
+
/** Bulk action surfaced in the floating bottom bar when posts are selected. */
|
|
3414
|
+
interface PostBulkAction {
|
|
3415
|
+
id: string;
|
|
3416
|
+
label: string;
|
|
3417
|
+
icon: LucideIcon;
|
|
3418
|
+
variant?: 'default' | 'danger' | 'brand';
|
|
3419
|
+
/** Optional sub-options — rendered as dropdown menu when present. */
|
|
3420
|
+
options?: Array<{
|
|
3421
|
+
id: string;
|
|
3422
|
+
label: string;
|
|
3423
|
+
icon?: LucideIcon;
|
|
3424
|
+
}>;
|
|
3425
|
+
onClick: (selectedIds: string[], optionId?: string) => void;
|
|
3426
|
+
disabled?: boolean;
|
|
3427
|
+
hidden?: boolean;
|
|
3428
|
+
}
|
|
3429
|
+
interface PostCommentAuthor {
|
|
3430
|
+
name: string;
|
|
3431
|
+
handle?: string;
|
|
3432
|
+
avatarUrl?: string;
|
|
3433
|
+
verified?: boolean;
|
|
3434
|
+
/** Optional badge: "Moderator", "Subscriber", "Author", etc. — surfaced as a chip next to the name. */
|
|
3435
|
+
badge?: string;
|
|
3436
|
+
}
|
|
3437
|
+
interface PostComment {
|
|
3438
|
+
id: string;
|
|
3439
|
+
author: PostCommentAuthor;
|
|
3440
|
+
text: string;
|
|
3441
|
+
timestamp: Date | string | number;
|
|
3442
|
+
sentiment?: PostSentiment;
|
|
3443
|
+
likes?: number;
|
|
3444
|
+
replies?: PostComment[];
|
|
3445
|
+
/**
|
|
3446
|
+
* Total reply count (may exceed `replies.length` if pagination caps the nested
|
|
3447
|
+
* replies). Drives the "نمایش ۲۳ پاسخ" affordance.
|
|
3448
|
+
*/
|
|
3449
|
+
replyCount?: number;
|
|
3450
|
+
/** Pinned by post author (Instagram, YouTube). */
|
|
3451
|
+
pinned?: boolean;
|
|
3452
|
+
/** Indicates this is a reply from the original post author. */
|
|
3453
|
+
authorReply?: boolean;
|
|
3454
|
+
/** Comment was edited at source — show ویرایششده chip. */
|
|
3455
|
+
edited?: boolean;
|
|
3456
|
+
/** ISO language code; enables translation toggle when different from current locale. */
|
|
3457
|
+
language?: string;
|
|
3458
|
+
/** Hidden by source moderator / shadow-banned. */
|
|
3459
|
+
hiddenByModerator?: boolean;
|
|
3460
|
+
/** Typed reaction breakdown (Facebook 7-type, LinkedIn 7-type, YouTube hearts, etc.). */
|
|
3461
|
+
reactions?: ReactionBreakdown;
|
|
3462
|
+
/** AI-detected toxicity / hate-speech / spam score (0..1). Surfaces a flag chip when set. */
|
|
3463
|
+
toxicityScore?: number;
|
|
3464
|
+
/** Pre-translated body (if cached). */
|
|
3465
|
+
translatedText?: string;
|
|
3466
|
+
}
|
|
3467
|
+
type PostIntent = 'complaint' | 'praise' | 'question' | 'announcement' | 'comparison' | 'opinion' | 'info';
|
|
3468
|
+
interface PostAiEntity {
|
|
3469
|
+
text: string;
|
|
3470
|
+
type: 'person' | 'brand' | 'place' | 'product' | 'event' | 'organization';
|
|
3471
|
+
}
|
|
3472
|
+
interface PostAiAnalysis {
|
|
3473
|
+
/** Auto-generated summary of the post. */
|
|
3474
|
+
summary?: string;
|
|
3475
|
+
/** Key topics mentioned in the post. */
|
|
3476
|
+
topics?: string[];
|
|
3477
|
+
/** Named entities detected. */
|
|
3478
|
+
entities?: PostAiEntity[];
|
|
3479
|
+
/** Primary intent classification. */
|
|
3480
|
+
intent?: PostIntent;
|
|
3481
|
+
/** 9-class emotion distribution (raw counts or normalized). */
|
|
3482
|
+
emotions?: Partial<Record<PostEmotion, number>>;
|
|
3483
|
+
/** Flagged risks / sensitive content categories. */
|
|
3484
|
+
risks?: string[];
|
|
3485
|
+
/** Influence tier estimate for the author. */
|
|
3486
|
+
influenceTier?: PostAuthorityTier;
|
|
3487
|
+
/** Model confidence 0..1 for overall analysis. */
|
|
3488
|
+
confidence?: number;
|
|
3489
|
+
/** Analysis generation timestamp. */
|
|
3490
|
+
generatedAt?: Date | string | number;
|
|
3491
|
+
}
|
|
3489
3492
|
/** Extended post details — optionally attached to PostData when fetching full view. */
|
|
3490
3493
|
interface PostDetails {
|
|
3491
3494
|
comments?: PostComment[];
|
|
@@ -3498,25 +3501,34 @@ interface PostDetails {
|
|
|
3498
3501
|
platformMeta?: PlatformMetadata;
|
|
3499
3502
|
}
|
|
3500
3503
|
|
|
3504
|
+
declare function defaultActions(handlers?: {
|
|
3505
|
+
onOpenDetails?: (post: PostData) => void;
|
|
3506
|
+
}): PostAction[];
|
|
3501
3507
|
declare const postCardVariants: (props?: ({
|
|
3502
|
-
|
|
3508
|
+
view?: "grid" | "compact" | "comfortable" | null | undefined;
|
|
3503
3509
|
selected?: boolean | null | undefined;
|
|
3510
|
+
active?: boolean | null | undefined;
|
|
3504
3511
|
} & class_variance_authority_types.ClassProp) | undefined) => string;
|
|
3505
3512
|
interface PostCardProps extends Omit<React$1.HTMLAttributes<HTMLDivElement>, 'onSelect'>, VariantProps<typeof postCardVariants> {
|
|
3506
3513
|
post: PostData;
|
|
3514
|
+
/** Layout mode. Replaces the legacy `density` prop. */
|
|
3515
|
+
view?: PostView;
|
|
3516
|
+
/** @deprecated Use `view` instead. */
|
|
3507
3517
|
density?: PostDensity;
|
|
3508
3518
|
selected?: boolean;
|
|
3519
|
+
/** True when the card represents the post currently open in the details drawer. */
|
|
3520
|
+
active?: boolean;
|
|
3509
3521
|
read?: boolean;
|
|
3510
3522
|
actions?: PostAction[];
|
|
3523
|
+
selectable?: boolean;
|
|
3511
3524
|
onOpen?: (post: PostData) => void;
|
|
3512
3525
|
onSelect?: (post: PostData, selected: boolean) => void;
|
|
3513
|
-
selectable?: boolean;
|
|
3514
|
-
/** Fired when user clicks the details action (Maximize2 icon). Wires up the default details action. */
|
|
3515
3526
|
onOpenDetails?: (post: PostData) => void;
|
|
3527
|
+
onOpenQuoted?: (post: PostData) => void;
|
|
3528
|
+
onRetryMedia?: (item: PostMediaItem) => void;
|
|
3529
|
+
onClusterClick?: (cluster: NonNullable<PostData['cluster']>) => void;
|
|
3530
|
+
onAuthorClick?: (authorId: string | undefined) => void;
|
|
3516
3531
|
}
|
|
3517
|
-
declare function defaultActions(handlers?: {
|
|
3518
|
-
onOpenDetails?: (post: PostData) => void;
|
|
3519
|
-
}): PostAction[];
|
|
3520
3532
|
declare const PostCard: React$1.ForwardRefExoticComponent<PostCardProps & React$1.RefAttributes<HTMLDivElement>>;
|
|
3521
3533
|
|
|
3522
3534
|
declare const postHeaderVariants: (props?: ({
|
|
@@ -3534,6 +3546,25 @@ interface PostHeaderProps extends Omit<React$1.HTMLAttributes<HTMLDivElement>, '
|
|
|
3534
3546
|
}
|
|
3535
3547
|
declare const PostHeader: React$1.ForwardRefExoticComponent<PostHeaderProps & React$1.RefAttributes<HTMLDivElement>>;
|
|
3536
3548
|
|
|
3549
|
+
interface PostHeaderBroadcastProps extends React$1.HTMLAttributes<HTMLDivElement> {
|
|
3550
|
+
source: 'tv' | 'radio';
|
|
3551
|
+
outlet: PostOutlet;
|
|
3552
|
+
timestamp: Date | string | number;
|
|
3553
|
+
enrichments?: PostEnrichmentFlags;
|
|
3554
|
+
density?: PostDensity;
|
|
3555
|
+
}
|
|
3556
|
+
declare const PostHeaderBroadcast: React$1.ForwardRefExoticComponent<PostHeaderBroadcastProps & React$1.RefAttributes<HTMLDivElement>>;
|
|
3557
|
+
interface PostHeaderEditorialProps extends React$1.HTMLAttributes<HTMLDivElement> {
|
|
3558
|
+
source: 'press' | 'web';
|
|
3559
|
+
outlet: PostOutlet;
|
|
3560
|
+
timestamp: Date | string | number;
|
|
3561
|
+
enrichments?: PostEnrichmentFlags;
|
|
3562
|
+
density?: PostDensity;
|
|
3563
|
+
/** Optional author byline (for press articles authored by an individual journalist). */
|
|
3564
|
+
byline?: PostAuthor;
|
|
3565
|
+
}
|
|
3566
|
+
declare const PostHeaderEditorial: React$1.ForwardRefExoticComponent<PostHeaderEditorialProps & React$1.RefAttributes<HTMLDivElement>>;
|
|
3567
|
+
|
|
3537
3568
|
/**
|
|
3538
3569
|
* Aspect-ratio helpers for post media.
|
|
3539
3570
|
*
|
|
@@ -3560,6 +3591,98 @@ interface PostBodyProps extends React$1.HTMLAttributes<HTMLDivElement> {
|
|
|
3560
3591
|
}
|
|
3561
3592
|
declare const PostBody: React$1.ForwardRefExoticComponent<PostBodyProps & React$1.RefAttributes<HTMLDivElement>>;
|
|
3562
3593
|
|
|
3594
|
+
/**
|
|
3595
|
+
* Rule: never vertically center an `<img>` with `mx-auto` + `h-full`. `<img>` is
|
|
3596
|
+
* `display: inline` by default so `mx-auto` is a no-op and the image rests on the
|
|
3597
|
+
* text baseline. Use the centered-container pattern below.
|
|
3598
|
+
*/
|
|
3599
|
+
declare const CENTERED_CONTAINER_CLS = "relative w-full overflow-hidden rounded-md bg-muted flex items-center justify-center";
|
|
3600
|
+
/**
|
|
3601
|
+
* Foreground image classes. `block` removes the baseline inline behavior;
|
|
3602
|
+
* `max-*` + `w-auto h-auto` + `object-contain` fit naturally inside the container.
|
|
3603
|
+
*/
|
|
3604
|
+
declare const FOREGROUND_IMG_CLS = "relative block max-h-full max-w-full w-auto h-auto object-contain";
|
|
3605
|
+
declare const BlurBackdrop: React$1.FC<{
|
|
3606
|
+
src?: string;
|
|
3607
|
+
}>;
|
|
3608
|
+
type PostMediaPlaceholderVariant = 'loading' | 'failed' | 'unavailable';
|
|
3609
|
+
interface PostMediaPlaceholderProps {
|
|
3610
|
+
variant: PostMediaPlaceholderVariant;
|
|
3611
|
+
/** Optional reason / human note. */
|
|
3612
|
+
reason?: string;
|
|
3613
|
+
/** CSS aspect ratio for the placeholder box (e.g. `"4 / 5"`). Defaults to `"4 / 5"`. */
|
|
3614
|
+
aspectRatio?: string;
|
|
3615
|
+
/** Optional cap. */
|
|
3616
|
+
maxHeight?: string;
|
|
3617
|
+
/** Retry handler — only rendered when `variant === 'failed'`. */
|
|
3618
|
+
onRetry?: () => void;
|
|
3619
|
+
className?: string;
|
|
3620
|
+
}
|
|
3621
|
+
declare const PostMediaPlaceholder: React$1.ForwardRefExoticComponent<PostMediaPlaceholderProps & React$1.RefAttributes<HTMLDivElement>>;
|
|
3622
|
+
interface PostMediaSourceRemovedProps {
|
|
3623
|
+
/** Optional URL to our archive snapshot. */
|
|
3624
|
+
archiveUrl?: string;
|
|
3625
|
+
/** Optional date the snapshot was taken. */
|
|
3626
|
+
archivedAt?: Date | string | number;
|
|
3627
|
+
className?: string;
|
|
3628
|
+
}
|
|
3629
|
+
declare const PostMediaSourceRemoved: React$1.ForwardRefExoticComponent<PostMediaSourceRemovedProps & React$1.RefAttributes<HTMLDivElement>>;
|
|
3630
|
+
declare const SENSITIVITY_LABEL: Record<string, string>;
|
|
3631
|
+
declare const PostMediaSensitiveOverlay: React$1.FC<{
|
|
3632
|
+
sensitivity: NonNullable<PostMediaItem['sensitivity']>;
|
|
3633
|
+
onReveal: () => void;
|
|
3634
|
+
}>;
|
|
3635
|
+
declare const PostMediaSingle: React$1.FC<{
|
|
3636
|
+
item: PostMediaItem;
|
|
3637
|
+
context: AspectContext;
|
|
3638
|
+
onRetry?: (item: PostMediaItem) => void;
|
|
3639
|
+
className?: string;
|
|
3640
|
+
}>;
|
|
3641
|
+
declare const PostMediaGrid: React$1.FC<{
|
|
3642
|
+
items: PostMediaItem[];
|
|
3643
|
+
context: AspectContext;
|
|
3644
|
+
onRetry?: (item: PostMediaItem) => void;
|
|
3645
|
+
className?: string;
|
|
3646
|
+
}>;
|
|
3647
|
+
declare const PostMediaCarousel: React$1.FC<{
|
|
3648
|
+
items: PostMediaItem[];
|
|
3649
|
+
context: AspectContext;
|
|
3650
|
+
onRetry?: (item: PostMediaItem) => void;
|
|
3651
|
+
className?: string;
|
|
3652
|
+
}>;
|
|
3653
|
+
declare const PostMediaVideo: React$1.FC<{
|
|
3654
|
+
item: PostMediaItem;
|
|
3655
|
+
context: AspectContext;
|
|
3656
|
+
onRetry?: (item: PostMediaItem) => void;
|
|
3657
|
+
className?: string;
|
|
3658
|
+
}>;
|
|
3659
|
+
declare const PostMediaAudio: React$1.FC<{
|
|
3660
|
+
item: PostMediaItem;
|
|
3661
|
+
context: AspectContext;
|
|
3662
|
+
className?: string;
|
|
3663
|
+
}>;
|
|
3664
|
+
declare const PostMediaStory: React$1.FC<{
|
|
3665
|
+
story: StoryItem;
|
|
3666
|
+
context: AspectContext;
|
|
3667
|
+
/** When true, no fixed 9:16 frame — used inside Highlight strip cells. */
|
|
3668
|
+
fillCell?: boolean;
|
|
3669
|
+
className?: string;
|
|
3670
|
+
}>;
|
|
3671
|
+
declare const PostMediaHighlight: React$1.FC<{
|
|
3672
|
+
title: string;
|
|
3673
|
+
coverUrl?: string;
|
|
3674
|
+
stories: StoryItem[];
|
|
3675
|
+
context: AspectContext;
|
|
3676
|
+
className?: string;
|
|
3677
|
+
}>;
|
|
3678
|
+
interface PostMediaProps extends React$1.HTMLAttributes<HTMLDivElement> {
|
|
3679
|
+
body: PostBodyData;
|
|
3680
|
+
context: AspectContext;
|
|
3681
|
+
/** Retry callback for failed media items. */
|
|
3682
|
+
onRetry?: (item: PostMediaItem) => void;
|
|
3683
|
+
}
|
|
3684
|
+
declare const PostMedia: React$1.ForwardRefExoticComponent<PostMediaProps & React$1.RefAttributes<HTMLDivElement>>;
|
|
3685
|
+
|
|
3563
3686
|
interface PostActionsProps extends React$1.HTMLAttributes<HTMLDivElement> {
|
|
3564
3687
|
post: PostData;
|
|
3565
3688
|
actions: PostAction[];
|
|
@@ -3579,10 +3702,94 @@ interface PostMetadataProps extends React$1.HTMLAttributes<HTMLDivElement> {
|
|
|
3579
3702
|
}
|
|
3580
3703
|
declare const PostMetadata: React$1.ForwardRefExoticComponent<PostMetadataProps & React$1.RefAttributes<HTMLDivElement>>;
|
|
3581
3704
|
|
|
3705
|
+
interface PostSignalsProps extends React$1.HTMLAttributes<HTMLDivElement> {
|
|
3706
|
+
sentiment?: PostSentiment;
|
|
3707
|
+
emotion?: EmotionKey;
|
|
3708
|
+
flow?: FlowKey;
|
|
3709
|
+
severity?: PostSeverity;
|
|
3710
|
+
cluster?: PostCluster;
|
|
3711
|
+
/** ISO language code (rendered as uppercase chip when not 'fa'). */
|
|
3712
|
+
language?: string;
|
|
3713
|
+
/** When true, hide emotion + flow + cluster + language to keep the row scannable in compact density. */
|
|
3714
|
+
compact?: boolean;
|
|
3715
|
+
/** Click handler on the cluster chip — typically filters the list. */
|
|
3716
|
+
onClusterClick?: (cluster: PostCluster) => void;
|
|
3717
|
+
}
|
|
3718
|
+
/**
|
|
3719
|
+
* Domain-signal chip row: sentiment, emotion, flow, severity, cluster, language.
|
|
3720
|
+
* Rendered in the `<PostCard>` footer. Designed to wrap when narrow.
|
|
3721
|
+
*/
|
|
3722
|
+
declare const PostSignals: React$1.ForwardRefExoticComponent<PostSignalsProps & React$1.RefAttributes<HTMLDivElement>>;
|
|
3723
|
+
|
|
3724
|
+
interface PostRepostHeaderProps extends React$1.HTMLAttributes<HTMLDivElement> {
|
|
3725
|
+
reposted: PostRepostInfo;
|
|
3726
|
+
/** Optional click handler on the reposter chip — typically opens the reposter's profile. */
|
|
3727
|
+
onAuthorClick?: (authorId: string | undefined) => void;
|
|
3728
|
+
}
|
|
3729
|
+
/**
|
|
3730
|
+
* Slim wrapper strip rendered above a `<PostCard>` when the post is surfaced through
|
|
3731
|
+
* a repost / retweet / forward. Matches the X, Threads, Telegram-channel-forward UX.
|
|
3732
|
+
*/
|
|
3733
|
+
declare const PostRepostHeader: React$1.ForwardRefExoticComponent<PostRepostHeaderProps & React$1.RefAttributes<HTMLDivElement>>;
|
|
3734
|
+
|
|
3735
|
+
interface PostQuotedEmbedProps extends React$1.HTMLAttributes<HTMLDivElement> {
|
|
3736
|
+
/** The post being quoted / referenced. */
|
|
3737
|
+
post: PostData;
|
|
3738
|
+
/** Click handler — typically navigates to the quoted post's details surface. */
|
|
3739
|
+
onOpen?: (post: PostData) => void;
|
|
3740
|
+
}
|
|
3741
|
+
/**
|
|
3742
|
+
* Nested compact card rendered inside a `<PostCard>` body when the post quotes,
|
|
3743
|
+
* embeds, or replies to another post. Read-only — no metrics, no action buttons,
|
|
3744
|
+
* no recursive embeds. Matches the X quote-tweet stacking pattern.
|
|
3745
|
+
*
|
|
3746
|
+
* RTL: indented from the inline-start via `ms-*` (visually right-indent in RTL).
|
|
3747
|
+
*/
|
|
3748
|
+
declare const PostQuotedEmbed: React$1.ForwardRefExoticComponent<PostQuotedEmbedProps & React$1.RefAttributes<HTMLDivElement>>;
|
|
3749
|
+
|
|
3750
|
+
interface PostThreadConnectorProps extends React$1.HTMLAttributes<HTMLDivElement> {
|
|
3751
|
+
thread: PostThreadInfo;
|
|
3752
|
+
/** When true, draws the connecting hairline that visually links this card to the next thread post. */
|
|
3753
|
+
showLine?: boolean;
|
|
3754
|
+
}
|
|
3755
|
+
/**
|
|
3756
|
+
* Renders the thread-position chip and the optional vertical hairline that connects
|
|
3757
|
+
* consecutive posts in the same thread. The hairline is positioned on the inline-start
|
|
3758
|
+
* edge of the card (right edge in RTL) and is purely visual — no interaction.
|
|
3759
|
+
*
|
|
3760
|
+
* The parent `<PostCard>` is responsible for rendering this in a `relative` container
|
|
3761
|
+
* so the absolute hairline can anchor to the card's full height.
|
|
3762
|
+
*/
|
|
3763
|
+
declare const PostThreadConnector: React$1.ForwardRefExoticComponent<PostThreadConnectorProps & React$1.RefAttributes<HTMLDivElement>>;
|
|
3764
|
+
|
|
3765
|
+
interface PostCrisisBannerProps extends React$1.HTMLAttributes<HTMLDivElement> {
|
|
3766
|
+
severity: PostSeverity;
|
|
3767
|
+
/** Optional override label — defaults to the Persian severity name. */
|
|
3768
|
+
label?: string;
|
|
3769
|
+
}
|
|
3770
|
+
/**
|
|
3771
|
+
* Slim banner strip rendered at the top of a `<PostCard>` to call attention to a
|
|
3772
|
+
* crisis / high-severity mention. Animates a pulse dot for `critical`. Subtle
|
|
3773
|
+
* by design — not a full-card red bleed, so the post stays scannable.
|
|
3774
|
+
*/
|
|
3775
|
+
declare const PostCrisisBanner: React$1.ForwardRefExoticComponent<PostCrisisBannerProps & React$1.RefAttributes<HTMLDivElement>>;
|
|
3776
|
+
|
|
3777
|
+
interface PostUrlPreviewProps extends React$1.HTMLAttributes<HTMLAnchorElement> {
|
|
3778
|
+
preview: PostUrlPreview;
|
|
3779
|
+
/** Compact layout (no description, smaller thumbnail). */
|
|
3780
|
+
compact?: boolean;
|
|
3781
|
+
}
|
|
3782
|
+
|
|
3783
|
+
type PostGroupBy = 'none' | 'platform' | 'sentiment' | 'date';
|
|
3784
|
+
type PostSortBy = 'newest' | 'oldest' | 'engagement' | 'authority' | 'severity';
|
|
3582
3785
|
interface PostListProps extends Omit<React$1.HTMLAttributes<HTMLDivElement>, 'onSelect'> {
|
|
3583
3786
|
posts: PostData[];
|
|
3584
|
-
/** Controlled
|
|
3787
|
+
/** Controlled view. If omitted, the list manages its own state (persisted to localStorage). */
|
|
3788
|
+
view?: PostView;
|
|
3789
|
+
onViewChange?: (view: PostView) => void;
|
|
3790
|
+
/** @deprecated Use `view` instead. */
|
|
3585
3791
|
density?: PostDensity;
|
|
3792
|
+
/** @deprecated Use `onViewChange` instead. */
|
|
3586
3793
|
onDensityChange?: (density: PostDensity) => void;
|
|
3587
3794
|
/** ID of the currently open/selected post (for URL deep-linking). */
|
|
3588
3795
|
activeId?: string;
|
|
@@ -3594,16 +3801,105 @@ interface PostListProps extends Omit<React$1.HTMLAttributes<HTMLDivElement>, 'on
|
|
|
3594
3801
|
onOpen?: (post: PostData) => void;
|
|
3595
3802
|
/** Fired when the user triggers the default "view details" action on any card. */
|
|
3596
3803
|
onOpenDetails?: (post: PostData) => void;
|
|
3804
|
+
onOpenQuoted?: (post: PostData) => void;
|
|
3805
|
+
onRetryMedia?: (item: PostMediaItem) => void;
|
|
3806
|
+
onClusterClick?: (cluster: NonNullable<PostData['cluster']>) => void;
|
|
3597
3807
|
/** Per-post action set. If omitted, each card uses its defaults. */
|
|
3598
3808
|
actions?: PostAction[];
|
|
3599
|
-
/**
|
|
3809
|
+
/** Bulk actions surfaced in the floating bar when posts are selected. */
|
|
3810
|
+
bulkActions?: PostBulkAction[];
|
|
3811
|
+
/** Group rendering: split the list into sticky-header sections. */
|
|
3812
|
+
groupBy?: PostGroupBy;
|
|
3813
|
+
/** Client-side sort applied to `posts` before render. */
|
|
3814
|
+
sortBy?: PostSortBy;
|
|
3815
|
+
/** Soft search filter — matches body text or title (case-insensitive). */
|
|
3816
|
+
searchQuery?: string;
|
|
3817
|
+
/** Render the toolbar (view toggle + extras). Defaults to true. */
|
|
3600
3818
|
showToolbar?: boolean;
|
|
3601
|
-
/** Custom toolbar content rendered next to the
|
|
3819
|
+
/** Custom toolbar content rendered next to the view toggle. */
|
|
3602
3820
|
toolbarExtra?: React$1.ReactNode;
|
|
3821
|
+
/** Loading state — replaces list with skeleton or custom node. */
|
|
3822
|
+
isLoading?: boolean;
|
|
3823
|
+
loadingState?: React$1.ReactNode;
|
|
3824
|
+
/** Error state — replaces list when set. */
|
|
3825
|
+
error?: unknown;
|
|
3826
|
+
errorState?: React$1.ReactNode;
|
|
3827
|
+
/** Empty state — shown when `posts.length === 0` after filtering. */
|
|
3828
|
+
emptyState?: React$1.ReactNode;
|
|
3829
|
+
/** Hide the floating bulk action bar even when posts are selected. */
|
|
3830
|
+
hideBulkBar?: boolean;
|
|
3603
3831
|
}
|
|
3604
3832
|
declare const PostList: React$1.ForwardRefExoticComponent<PostListProps & React$1.RefAttributes<HTMLDivElement>>;
|
|
3605
3833
|
|
|
3606
|
-
|
|
3834
|
+
interface PostBulkActionBarProps extends Omit<React$1.HTMLAttributes<HTMLDivElement>, 'onClick'> {
|
|
3835
|
+
selectedCount: number;
|
|
3836
|
+
selectedIds: string[];
|
|
3837
|
+
actions?: PostBulkAction[];
|
|
3838
|
+
onClear?: () => void;
|
|
3839
|
+
}
|
|
3840
|
+
/**
|
|
3841
|
+
* Floating bulk-action bar — appears at the bottom of the viewport when one or
|
|
3842
|
+
* more posts are selected in `<PostList>`. Matches the Gmail / Linear / Notion
|
|
3843
|
+
* selection bar pattern. Dismiss with Esc or by clicking the clear button.
|
|
3844
|
+
*/
|
|
3845
|
+
declare const PostBulkActionBar: React$1.ForwardRefExoticComponent<PostBulkActionBarProps & React$1.RefAttributes<HTMLDivElement>>;
|
|
3846
|
+
|
|
3847
|
+
/**
|
|
3848
|
+
* Extended platform set: social media + government broadcast/print sources
|
|
3849
|
+
* (TV, Radio, Press). Use this for cross-platform feeds where a tracked
|
|
3850
|
+
* topic surfaces in both an Instagram post AND a TV broadcast.
|
|
3851
|
+
*/
|
|
3852
|
+
type ExtendedPlatform = SocialPlatform | 'tv' | 'radio' | 'press';
|
|
3853
|
+
/**
|
|
3854
|
+
* Metrics shape varies by platform — social posts have likes/comments,
|
|
3855
|
+
* TV/radio clips have viewers/listeners, news articles often just have
|
|
3856
|
+
* a share count or comment-thread total. All optional.
|
|
3857
|
+
*/
|
|
3858
|
+
interface MultiPlatformMetrics {
|
|
3859
|
+
likes?: number;
|
|
3860
|
+
comments?: number;
|
|
3861
|
+
shares?: number;
|
|
3862
|
+
views?: number;
|
|
3863
|
+
/** TV viewers OR radio listeners (different display label, same number type) */
|
|
3864
|
+
audience?: number;
|
|
3865
|
+
}
|
|
3866
|
+
interface MultiPlatformPostData {
|
|
3867
|
+
/** Stable id for keys + analytics */
|
|
3868
|
+
id: string;
|
|
3869
|
+
platform: ExtendedPlatform;
|
|
3870
|
+
/** Outlet/account display name (e.g. "BBC فارسی", "@news_ir", "صدا و سیما"). */
|
|
3871
|
+
sourceName: string;
|
|
3872
|
+
/** Optional headline — typical for news + TV/radio segments, often absent on social. */
|
|
3873
|
+
title?: React$1.ReactNode;
|
|
3874
|
+
/** Body text or transcript excerpt. */
|
|
3875
|
+
body: React$1.ReactNode;
|
|
3876
|
+
/** Publication / broadcast time. Date or ISO string. */
|
|
3877
|
+
publishedAt: Date | string;
|
|
3878
|
+
/** Optional thumbnail (post image, article hero, video still). */
|
|
3879
|
+
thumbnailUrl?: string;
|
|
3880
|
+
/**
|
|
3881
|
+
* Optional clip duration in **seconds** — only meaningful for TV / radio /
|
|
3882
|
+
* video. Rendered as `MM:SS` or `HH:MM:SS`.
|
|
3883
|
+
*/
|
|
3884
|
+
durationSec?: number;
|
|
3885
|
+
metrics?: MultiPlatformMetrics;
|
|
3886
|
+
/** Optional URL to the source. When set, the card gains an "open at source" affordance. */
|
|
3887
|
+
sourceUrl?: string;
|
|
3888
|
+
/** Optional language tag for the body. Renders a small chip when set. */
|
|
3889
|
+
language?: string;
|
|
3890
|
+
}
|
|
3891
|
+
interface MultiPlatformPostCardProps extends Omit<React$1.HTMLAttributes<HTMLElement>, 'onClick'> {
|
|
3892
|
+
post: MultiPlatformPostData;
|
|
3893
|
+
/** Make the entire card clickable (opens sourceUrl in new tab if not custom) */
|
|
3894
|
+
onCardClick?: (post: MultiPlatformPostData) => void;
|
|
3895
|
+
/** Compact density hides body excerpt + thumbnail */
|
|
3896
|
+
density?: 'compact' | 'comfortable';
|
|
3897
|
+
/** Locale for labels + relative-time formatting */
|
|
3898
|
+
locale?: SupportedLocale;
|
|
3899
|
+
}
|
|
3900
|
+
declare const MultiPlatformPostCard: React$1.ForwardRefExoticComponent<MultiPlatformPostCardProps & React$1.RefAttributes<HTMLElement>>;
|
|
3901
|
+
|
|
3902
|
+
type PostDetailsTab$1 = 'post' | 'comments' | 'analysis' | 'transcript';
|
|
3607
3903
|
interface PostDetailsModalProps {
|
|
3608
3904
|
/** Controls modal open state. */
|
|
3609
3905
|
open: boolean;
|
|
@@ -3621,7 +3917,7 @@ interface PostDetailsModalProps {
|
|
|
3621
3917
|
/** Fires when user clicks "retry" on the error panel. */
|
|
3622
3918
|
onRetry?: () => void;
|
|
3623
3919
|
/** Which tab to open first @default "post" */
|
|
3624
|
-
defaultTab?: PostDetailsTab;
|
|
3920
|
+
defaultTab?: PostDetailsTab$1;
|
|
3625
3921
|
/** Dialog size. @default "lg" (~1024px) */
|
|
3626
3922
|
size?: 'md' | 'lg' | 'xl';
|
|
3627
3923
|
/** Show the bookmark toggle. When `onBookmark` is set, the button appears. */
|
|
@@ -3634,6 +3930,99 @@ interface PostDetailsModalProps {
|
|
|
3634
3930
|
}
|
|
3635
3931
|
declare const PostDetailsModal: React$1.FC<PostDetailsModalProps>;
|
|
3636
3932
|
|
|
3933
|
+
type PostDetailsTab = 'post' | 'comments' | 'analysis' | 'transcript';
|
|
3934
|
+
interface PostDetailsDrawerProps {
|
|
3935
|
+
open?: boolean;
|
|
3936
|
+
onOpenChange?: (open: boolean) => void;
|
|
3937
|
+
post: PostData;
|
|
3938
|
+
details?: PostDetails;
|
|
3939
|
+
/** Details are being fetched asynchronously — show loading state in tabs. */
|
|
3940
|
+
isLoadingDetails?: boolean;
|
|
3941
|
+
bookmarked?: boolean;
|
|
3942
|
+
onBookmark?: (post: PostData, next: boolean) => void;
|
|
3943
|
+
onCopyLink?: (post: PostData, url: string) => void;
|
|
3944
|
+
onOpenSource?: (post: PostData) => void;
|
|
3945
|
+
onRetryMedia?: (item: PostMediaItem) => void;
|
|
3946
|
+
/** Navigate to the next post in the parent list (fires when j is pressed). */
|
|
3947
|
+
onNext?: () => void;
|
|
3948
|
+
/** Navigate to the previous post in the parent list (fires when k is pressed). */
|
|
3949
|
+
onPrevious?: () => void;
|
|
3950
|
+
defaultTab?: PostDetailsTab;
|
|
3951
|
+
/** Custom action node rendered next to the default header actions. */
|
|
3952
|
+
extraActions?: React$1.ReactNode;
|
|
3953
|
+
/** Optional translation handler. When provided, a "نمایش ترجمه" toggle appears on the post tab. */
|
|
3954
|
+
onTranslate?: (post: PostData) => Promise<string> | string;
|
|
3955
|
+
/** Optional like-comment handler. */
|
|
3956
|
+
onLikeComment?: (commentId: string) => void;
|
|
3957
|
+
}
|
|
3958
|
+
/**
|
|
3959
|
+
* Right-aligned side panel for inspecting a post in depth. Replaces the legacy
|
|
3960
|
+
* `<PostDetailsModal>` as the canonical detail surface on desktop. The modal
|
|
3961
|
+
* stays as a mobile-only fallback.
|
|
3962
|
+
*
|
|
3963
|
+
* Keyboard:
|
|
3964
|
+
* - Esc → close (handled by Sheet)
|
|
3965
|
+
* - j / ArrowDown → onNext
|
|
3966
|
+
* - k / ArrowUp → onPrevious
|
|
3967
|
+
*/
|
|
3968
|
+
declare const PostDetailsDrawer: React$1.ForwardRefExoticComponent<PostDetailsDrawerProps & React$1.RefAttributes<HTMLDivElement>>;
|
|
3969
|
+
|
|
3970
|
+
type SupportedMetricLocale = 'fa' | 'en';
|
|
3971
|
+
type MetricKey = keyof PostMetrics;
|
|
3972
|
+
/**
|
|
3973
|
+
* Resolve a metric label for a given source + key + locale.
|
|
3974
|
+
*
|
|
3975
|
+
* Lookup order:
|
|
3976
|
+
* 1. Source-specific override (e.g. tiktok.views → "تماشا")
|
|
3977
|
+
* 2. Default for that locale (e.g. views → "بازدید")
|
|
3978
|
+
*
|
|
3979
|
+
* Never returns `undefined` — falls back to default labels.
|
|
3980
|
+
*/
|
|
3981
|
+
declare function getMetricLabel(source: PostSource, key: MetricKey, locale?: SupportedMetricLocale): string;
|
|
3982
|
+
|
|
3983
|
+
/**
|
|
3984
|
+
* Per-source metadata used by `<PostHeader>`, `<PostMetrics>`, badges, and the source-aware
|
|
3985
|
+
* default actions. This is the single source of truth — adding a new platform = adding
|
|
3986
|
+
* one entry here + one CSS var + one label entry in `post-metric-labels.ts`.
|
|
3987
|
+
*
|
|
3988
|
+
* Brand colors are referenced as CSS variables (`--social-platform-*`) and resolved at
|
|
3989
|
+
* runtime so the dark/light theme can adapt where needed (twitter, threads, press, web).
|
|
3990
|
+
*/
|
|
3991
|
+
type SourceIconSource =
|
|
3992
|
+
/** Icon comes from the brand-SVG set in `<SocialPlatformBadge>` (7 social platforms). */
|
|
3993
|
+
{
|
|
3994
|
+
kind: 'social-brand';
|
|
3995
|
+
}
|
|
3996
|
+
/** Icon is a generic Lucide glyph (broadcast / editorial sources). */
|
|
3997
|
+
| {
|
|
3998
|
+
kind: 'lucide';
|
|
3999
|
+
icon: LucideIcon;
|
|
4000
|
+
};
|
|
4001
|
+
interface PostSourceConfig {
|
|
4002
|
+
/** English label, displayed when `showLabel` is on. */
|
|
4003
|
+
label: string;
|
|
4004
|
+
/** Persian (fa) label, for fa-locale headers and tooltips. */
|
|
4005
|
+
labelFa: string;
|
|
4006
|
+
/** Category: drives header layout switch. */
|
|
4007
|
+
category: PostSourceCategory;
|
|
4008
|
+
/** CSS variable name (without the `var()` wrapper). */
|
|
4009
|
+
colorVar: string;
|
|
4010
|
+
/** How to render the icon for this source. */
|
|
4011
|
+
icon: SourceIconSource;
|
|
4012
|
+
/**
|
|
4013
|
+
* Default metric order — which metric keys to show by default and in what order.
|
|
4014
|
+
* Consumers can override per-card via PostMetadata's `metricsOrder` prop.
|
|
4015
|
+
*/
|
|
4016
|
+
defaultMetrics: ReadonlyArray<keyof PostMetrics>;
|
|
4017
|
+
}
|
|
4018
|
+
/** Look up the per-source config block. */
|
|
4019
|
+
declare function getPostSourceConfig(source: PostSource): PostSourceConfig;
|
|
4020
|
+
/**
|
|
4021
|
+
* Convenience: read the brand color CSS variable for a source.
|
|
4022
|
+
* Use as: `style={{ color: getSourceColorVar('instagram') }}` → `var(--social-platform-instagram)`.
|
|
4023
|
+
*/
|
|
4024
|
+
declare function getSourceColorVar(source: PostSource): string;
|
|
4025
|
+
|
|
3637
4026
|
declare const profileCardVariants: (props?: ({
|
|
3638
4027
|
variant?: "default" | "transparent" | "dark" | null | undefined;
|
|
3639
4028
|
size?: "sm" | "md" | "lg" | null | undefined;
|
|
@@ -4000,7 +4389,10 @@ declare namespace ScrollBar {
|
|
|
4000
4389
|
var displayName: string;
|
|
4001
4390
|
}
|
|
4002
4391
|
|
|
4003
|
-
declare const Select:
|
|
4392
|
+
declare const Select: {
|
|
4393
|
+
({ dir, ...props }: React$1.ComponentProps<typeof SelectPrimitive.Root>): react_jsx_runtime.JSX.Element;
|
|
4394
|
+
displayName: string;
|
|
4395
|
+
};
|
|
4004
4396
|
declare const SelectGroup: React$1.ForwardRefExoticComponent<SelectPrimitive.SelectGroupProps & React$1.RefAttributes<HTMLDivElement>>;
|
|
4005
4397
|
declare const SelectValue: React$1.ForwardRefExoticComponent<Omit<SelectPrimitive.SelectValueProps & React$1.RefAttributes<HTMLSpanElement>, "ref"> & VariantProps<(props?: ({
|
|
4006
4398
|
size?: "xs" | "sm" | "md" | "lg" | "xl" | null | undefined;
|
|
@@ -4015,61 +4407,9 @@ declare const SelectTrigger: React$1.ForwardRefExoticComponent<Omit<SelectPrimit
|
|
|
4015
4407
|
declare const SelectScrollUpButton: React$1.ForwardRefExoticComponent<Omit<SelectPrimitive.SelectScrollUpButtonProps & React$1.RefAttributes<HTMLDivElement>, "ref"> & React$1.RefAttributes<HTMLDivElement>>;
|
|
4016
4408
|
declare const SelectScrollDownButton: React$1.ForwardRefExoticComponent<Omit<SelectPrimitive.SelectScrollDownButtonProps & React$1.RefAttributes<HTMLDivElement>, "ref"> & React$1.RefAttributes<HTMLDivElement>>;
|
|
4017
4409
|
declare const SelectContent: React$1.ForwardRefExoticComponent<Omit<SelectPrimitive.SelectContentProps & React$1.RefAttributes<HTMLDivElement>, "ref"> & React$1.RefAttributes<HTMLDivElement>>;
|
|
4018
|
-
declare const SelectLabel: React$1.ForwardRefExoticComponent<Omit<SelectPrimitive.SelectLabelProps & React$1.RefAttributes<HTMLDivElement>, "ref"> & React$1.RefAttributes<HTMLDivElement>>;
|
|
4019
|
-
declare const SelectItem: React$1.ForwardRefExoticComponent<Omit<SelectPrimitive.SelectItemProps & React$1.RefAttributes<HTMLDivElement>, "ref"> & React$1.RefAttributes<HTMLDivElement>>;
|
|
4020
|
-
declare const SelectSeparator: React$1.ForwardRefExoticComponent<Omit<SelectPrimitive.SelectSeparatorProps & React$1.RefAttributes<HTMLDivElement>, "ref"> & React$1.RefAttributes<HTMLDivElement>>;
|
|
4021
|
-
|
|
4022
|
-
declare function Sheet({ ...props }: React$1.ComponentProps<typeof DialogPrimitive.Root>): react_jsx_runtime.JSX.Element;
|
|
4023
|
-
declare namespace Sheet {
|
|
4024
|
-
var displayName: string;
|
|
4025
|
-
}
|
|
4026
|
-
declare function SheetTrigger({ ...props }: React$1.ComponentProps<typeof DialogPrimitive.Trigger>): react_jsx_runtime.JSX.Element;
|
|
4027
|
-
declare namespace SheetTrigger {
|
|
4028
|
-
var displayName: string;
|
|
4029
|
-
}
|
|
4030
|
-
declare function SheetClose({ ...props }: React$1.ComponentProps<typeof DialogPrimitive.Close>): react_jsx_runtime.JSX.Element;
|
|
4031
|
-
declare namespace SheetClose {
|
|
4032
|
-
var displayName: string;
|
|
4033
|
-
}
|
|
4034
|
-
declare function SheetContent({ className, children, side, ...props }: React$1.ComponentProps<typeof DialogPrimitive.Content> & {
|
|
4035
|
-
side?: 'top' | 'right' | 'bottom' | 'left';
|
|
4036
|
-
}): react_jsx_runtime.JSX.Element;
|
|
4037
|
-
declare namespace SheetContent {
|
|
4038
|
-
var displayName: string;
|
|
4039
|
-
}
|
|
4040
|
-
declare function SheetHeader({ className, ...props }: React$1.ComponentProps<'div'>): react_jsx_runtime.JSX.Element;
|
|
4041
|
-
declare namespace SheetHeader {
|
|
4042
|
-
var displayName: string;
|
|
4043
|
-
}
|
|
4044
|
-
declare function SheetBody({ className, ...props }: React$1.ComponentProps<'div'>): react_jsx_runtime.JSX.Element;
|
|
4045
|
-
declare namespace SheetBody {
|
|
4046
|
-
var displayName: string;
|
|
4047
|
-
}
|
|
4048
|
-
declare function SheetFooter({ className, ...props }: React$1.ComponentProps<'div'>): react_jsx_runtime.JSX.Element;
|
|
4049
|
-
declare namespace SheetFooter {
|
|
4050
|
-
var displayName: string;
|
|
4051
|
-
}
|
|
4052
|
-
declare function SheetTitle({ className, ...props }: React$1.ComponentProps<typeof DialogPrimitive.Title>): react_jsx_runtime.JSX.Element;
|
|
4053
|
-
declare namespace SheetTitle {
|
|
4054
|
-
var displayName: string;
|
|
4055
|
-
}
|
|
4056
|
-
declare function SheetDescription({ className, ...props }: React$1.ComponentProps<typeof DialogPrimitive.Description>): react_jsx_runtime.JSX.Element;
|
|
4057
|
-
declare namespace SheetDescription {
|
|
4058
|
-
var displayName: string;
|
|
4059
|
-
}
|
|
4060
|
-
|
|
4061
|
-
declare const TooltipProvider: React$1.FC<TooltipPrimitive.TooltipProviderProps>;
|
|
4062
|
-
declare const Tooltip: React$1.FC<TooltipPrimitive.TooltipProps>;
|
|
4063
|
-
declare const TooltipTrigger: React$1.ForwardRefExoticComponent<TooltipPrimitive.TooltipTriggerProps & React$1.RefAttributes<HTMLButtonElement>>;
|
|
4064
|
-
interface TooltipContentProps extends React$1.ComponentPropsWithoutRef<typeof TooltipPrimitive.Content> {
|
|
4065
|
-
/** Visual variant */
|
|
4066
|
-
variant?: 'default' | 'light' | 'error';
|
|
4067
|
-
/** Size */
|
|
4068
|
-
size?: 'sm' | 'md';
|
|
4069
|
-
/** Show arrow/caret pointing to trigger */
|
|
4070
|
-
showArrow?: boolean;
|
|
4071
|
-
}
|
|
4072
|
-
declare const TooltipContent: React$1.ForwardRefExoticComponent<TooltipContentProps & React$1.RefAttributes<HTMLDivElement>>;
|
|
4410
|
+
declare const SelectLabel: React$1.ForwardRefExoticComponent<Omit<SelectPrimitive.SelectLabelProps & React$1.RefAttributes<HTMLDivElement>, "ref"> & React$1.RefAttributes<HTMLDivElement>>;
|
|
4411
|
+
declare const SelectItem: React$1.ForwardRefExoticComponent<Omit<SelectPrimitive.SelectItemProps & React$1.RefAttributes<HTMLDivElement>, "ref"> & React$1.RefAttributes<HTMLDivElement>>;
|
|
4412
|
+
declare const SelectSeparator: React$1.ForwardRefExoticComponent<Omit<SelectPrimitive.SelectSeparatorProps & React$1.RefAttributes<HTMLDivElement>, "ref"> & React$1.RefAttributes<HTMLDivElement>>;
|
|
4073
4413
|
|
|
4074
4414
|
type SidebarContextProps = {
|
|
4075
4415
|
state: 'expanded' | 'collapsed';
|
|
@@ -4278,40 +4618,7 @@ declare namespace FormRowSkeleton {
|
|
|
4278
4618
|
var displayName: string;
|
|
4279
4619
|
}
|
|
4280
4620
|
|
|
4281
|
-
|
|
4282
|
-
type SparklineVariant = 'line' | 'area' | 'bars';
|
|
4283
|
-
interface SparklineProps extends React$1.HTMLAttributes<HTMLDivElement> {
|
|
4284
|
-
/** Array of numeric data points. Must have at least 2 items to render line/area. */
|
|
4285
|
-
data: number[];
|
|
4286
|
-
/** Visual style @default "line" */
|
|
4287
|
-
variant?: SparklineVariant;
|
|
4288
|
-
/**
|
|
4289
|
-
* Trend colour. `"auto"` compares first and last point:
|
|
4290
|
-
* last > first → up, last < first → down, equal → neutral.
|
|
4291
|
-
* Pass an explicit value to override.
|
|
4292
|
-
* @default "auto"
|
|
4293
|
-
*/
|
|
4294
|
-
trend?: SparklineTrend;
|
|
4295
|
-
/** Width in px. Also used as SVG viewBox width — output scales to parent when CSS overrides. @default 80 */
|
|
4296
|
-
width?: number;
|
|
4297
|
-
/** Height in px @default 24 */
|
|
4298
|
-
height?: number;
|
|
4299
|
-
/** Line / bar stroke width @default 1.5 */
|
|
4300
|
-
strokeWidth?: number;
|
|
4301
|
-
/** Show a filled dot at the last point */
|
|
4302
|
-
showEndDot?: boolean;
|
|
4303
|
-
/** Padding inside the viewBox so strokes/dots are not clipped @default 2 */
|
|
4304
|
-
padding?: number;
|
|
4305
|
-
/** Override color with any CSS value (e.g. `"hsl(var(--brand))"`). Takes precedence over `trend`. */
|
|
4306
|
-
color?: string;
|
|
4307
|
-
/** For bars variant — gap between bars in user units @default 1 */
|
|
4308
|
-
barGap?: number;
|
|
4309
|
-
/** aria-label for screen readers — describe the trend / metric */
|
|
4310
|
-
'aria-label'?: string;
|
|
4311
|
-
}
|
|
4312
|
-
declare const Sparkline: React$1.ForwardRefExoticComponent<SparklineProps & React$1.RefAttributes<HTMLDivElement>>;
|
|
4313
|
-
|
|
4314
|
-
declare function Slider({ className, defaultValue, value, min, max, dir, ...props }: React$1.ComponentProps<typeof SliderPrimitive.Root>): react_jsx_runtime.JSX.Element;
|
|
4621
|
+
declare function Slider({ className, defaultValue, value, min, max, dir, 'aria-label': ariaLabel, 'aria-labelledby': ariaLabelledBy, ...props }: React$1.ComponentProps<typeof SliderPrimitive.Root>): react_jsx_runtime.JSX.Element;
|
|
4315
4622
|
declare namespace Slider {
|
|
4316
4623
|
var displayName: string;
|
|
4317
4624
|
}
|
|
@@ -4393,7 +4700,7 @@ declare namespace TableSortHeader {
|
|
|
4393
4700
|
var displayName: string;
|
|
4394
4701
|
}
|
|
4395
4702
|
|
|
4396
|
-
declare const Tabs: React$1.ForwardRefExoticComponent<TabsPrimitive.TabsProps & React$1.RefAttributes<HTMLDivElement>>;
|
|
4703
|
+
declare const Tabs: React$1.ForwardRefExoticComponent<Omit<TabsPrimitive.TabsProps & React$1.RefAttributes<HTMLDivElement>, "ref"> & React$1.RefAttributes<HTMLDivElement>>;
|
|
4397
4704
|
interface TabsListProps extends React$1.ComponentPropsWithoutRef<typeof TabsPrimitive.List> {
|
|
4398
4705
|
/** Visual variant */
|
|
4399
4706
|
variant?: 'default' | 'underline' | 'outline';
|
|
@@ -4578,6 +4885,15 @@ interface JobWizardStep {
|
|
|
4578
4885
|
description?: string;
|
|
4579
4886
|
/** Mark step as optional — a "Skip" button appears. @default false */
|
|
4580
4887
|
optional?: boolean;
|
|
4888
|
+
/**
|
|
4889
|
+
* Branching: resolve the next step id based on current data. Returning a
|
|
4890
|
+
* known step id navigates there (skipping any steps in between); returning
|
|
4891
|
+
* `null` marks the wizard as terminal (the Next button submits); returning
|
|
4892
|
+
* `undefined` falls back to the natural linear `currentIndex + 1`.
|
|
4893
|
+
*
|
|
4894
|
+
* Cast `data` to your wizard's data shape inside the callback.
|
|
4895
|
+
*/
|
|
4896
|
+
nextStep?: (data: Partial<Record<string, unknown>>) => string | null | undefined;
|
|
4581
4897
|
}
|
|
4582
4898
|
/** Result of a validator — `null`/`undefined` = pass, `string` = single error, `Record<field, message>` = field errors */
|
|
4583
4899
|
type JobWizardValidationResult = string | Record<string, string> | null | undefined;
|
|
@@ -4835,6 +5151,16 @@ interface MultiSelectProps {
|
|
|
4835
5151
|
emptyMessage?: string;
|
|
4836
5152
|
/** Search placeholder */
|
|
4837
5153
|
searchPlaceholder?: string;
|
|
5154
|
+
/** Accessible label. Falls back to the resolved placeholder when omitted. */
|
|
5155
|
+
'aria-label'?: string;
|
|
5156
|
+
/** id of an external label element that names this control. */
|
|
5157
|
+
'aria-labelledby'?: string;
|
|
5158
|
+
/** Marks the trigger as invalid (e.g. when wired through `<FormControl>`). */
|
|
5159
|
+
'aria-invalid'?: boolean | 'true' | 'false';
|
|
5160
|
+
/** id(s) of element(s) describing the trigger (typically a `<FormMessage>`). */
|
|
5161
|
+
'aria-describedby'?: string;
|
|
5162
|
+
/** id of the trigger element — set by `<FormControl>` to wire `<FormLabel htmlFor>`. */
|
|
5163
|
+
id?: string;
|
|
4838
5164
|
}
|
|
4839
5165
|
declare const MultiSelect: React$1.ForwardRefExoticComponent<MultiSelectProps & React$1.RefAttributes<HTMLDivElement>>;
|
|
4840
5166
|
|
|
@@ -4911,118 +5237,6 @@ interface ComparisonCardProps extends React$1.HTMLAttributes<HTMLDivElement> {
|
|
|
4911
5237
|
}
|
|
4912
5238
|
declare const ComparisonCard: React$1.ForwardRefExoticComponent<ComparisonCardProps & React$1.RefAttributes<HTMLDivElement>>;
|
|
4913
5239
|
|
|
4914
|
-
type SortDirection = 'asc' | 'desc';
|
|
4915
|
-
interface DataTableColumn<TData> {
|
|
4916
|
-
/** Unique key identifying the column — used for sort callbacks */
|
|
4917
|
-
id: string;
|
|
4918
|
-
/** Column header label */
|
|
4919
|
-
header: React$1.ReactNode;
|
|
4920
|
-
/** Render function for cell content */
|
|
4921
|
-
cell: (row: TData, rowIndex: number) => React$1.ReactNode;
|
|
4922
|
-
/** Whether this column is sortable */
|
|
4923
|
-
sortable?: boolean;
|
|
4924
|
-
/** Additional className for both <th> and <td> */
|
|
4925
|
-
className?: string;
|
|
4926
|
-
/** Column alignment */
|
|
4927
|
-
align?: 'start' | 'center' | 'end';
|
|
4928
|
-
/**
|
|
4929
|
-
* Pin the column to the start (logical, RTL-aware) or end of the visible
|
|
4930
|
-
* area. Pinned columns stay visible while horizontal scrolling. The
|
|
4931
|
-
* selection / expansion gutter columns are pinned automatically.
|
|
4932
|
-
*/
|
|
4933
|
-
pinned?: 'start' | 'end';
|
|
4934
|
-
/** Optional fixed pixel width (used for pinning offset calculation) */
|
|
4935
|
-
width?: number;
|
|
4936
|
-
/** When false, this column is hidden via the columnVisibility map */
|
|
4937
|
-
defaultVisible?: boolean;
|
|
4938
|
-
}
|
|
4939
|
-
interface DataTableColumnVisibility {
|
|
4940
|
-
/** Map of column id → visible. Missing keys default to true. */
|
|
4941
|
-
visible: Record<string, boolean>;
|
|
4942
|
-
/** Called when a column toggle changes. */
|
|
4943
|
-
onVisibilityChange: (next: Record<string, boolean>) => void;
|
|
4944
|
-
}
|
|
4945
|
-
interface DataTableExpansion<TData> {
|
|
4946
|
-
/** Set of expanded row keys. */
|
|
4947
|
-
expandedRows: Set<number>;
|
|
4948
|
-
/** Called when expansion toggles. */
|
|
4949
|
-
onExpandedRowsChange: (next: Set<number>) => void;
|
|
4950
|
-
/** Render function for the expanded content (full-width row below). */
|
|
4951
|
-
renderExpandedRow: (row: TData, rowIndex: number) => React$1.ReactNode;
|
|
4952
|
-
}
|
|
4953
|
-
interface DataTablePagination {
|
|
4954
|
-
currentPage: number;
|
|
4955
|
-
totalPages: number;
|
|
4956
|
-
onPageChange: (page: number) => void;
|
|
4957
|
-
}
|
|
4958
|
-
interface DataTableSort {
|
|
4959
|
-
column: string | null;
|
|
4960
|
-
direction: SortDirection | null;
|
|
4961
|
-
onSort: (column: string, direction: SortDirection) => void;
|
|
4962
|
-
}
|
|
4963
|
-
interface DataTableSelection<TData> {
|
|
4964
|
-
selectedRows: Set<number>;
|
|
4965
|
-
onSelectionChange: (selectedRows: Set<number>) => void;
|
|
4966
|
-
/** Function to get a unique key for each row (defaults to index) */
|
|
4967
|
-
getRowKey?: (row: TData, index: number) => number;
|
|
4968
|
-
}
|
|
4969
|
-
interface DataTableProps<TData> {
|
|
4970
|
-
/** Column definitions */
|
|
4971
|
-
columns: DataTableColumn<TData>[];
|
|
4972
|
-
/** Data rows */
|
|
4973
|
-
data: TData[];
|
|
4974
|
-
/** Table size variant */
|
|
4975
|
-
size?: 'sm' | 'md' | 'lg';
|
|
4976
|
-
/** Show loading skeleton */
|
|
4977
|
-
isLoading?: boolean;
|
|
4978
|
-
/** Number of skeleton rows to show when loading */
|
|
4979
|
-
loadingRows?: number;
|
|
4980
|
-
/** Content to show when data is empty (not loading) */
|
|
4981
|
-
emptyState?: React$1.ReactNode;
|
|
4982
|
-
/** Pagination configuration */
|
|
4983
|
-
pagination?: DataTablePagination;
|
|
4984
|
-
/** Sort configuration */
|
|
4985
|
-
sort?: DataTableSort;
|
|
4986
|
-
/** Row selection configuration */
|
|
4987
|
-
selection?: DataTableSelection<TData>;
|
|
4988
|
-
/** Column visibility configuration (for show/hide column toggle) */
|
|
4989
|
-
columnVisibility?: DataTableColumnVisibility;
|
|
4990
|
-
/** Expansion configuration (for inline detail row) */
|
|
4991
|
-
expansion?: DataTableExpansion<TData>;
|
|
4992
|
-
/**
|
|
4993
|
-
* Opt-in row virtualization for very long lists (1000+ rows). When set,
|
|
4994
|
-
* the table is wrapped in a scroll container of `viewportHeight` and only
|
|
4995
|
-
* rows in the visible window + `overscan` are rendered. Rows must have a
|
|
4996
|
-
* predictable `rowHeight`; expanded rows + dynamic content are NOT
|
|
4997
|
-
* supported in virtualized mode.
|
|
4998
|
-
*/
|
|
4999
|
-
virtualize?: {
|
|
5000
|
-
/** Pixel height of each row (must be uniform). */
|
|
5001
|
-
rowHeight: number;
|
|
5002
|
-
/** Container scroll-area height in px. @default 480 */
|
|
5003
|
-
viewportHeight?: number;
|
|
5004
|
-
/** Extra rows rendered above and below the viewport. @default 6 */
|
|
5005
|
-
overscan?: number;
|
|
5006
|
-
};
|
|
5007
|
-
/** Zebra-striped rows */
|
|
5008
|
-
striped?: boolean;
|
|
5009
|
-
/** Bordered cells */
|
|
5010
|
-
bordered?: boolean;
|
|
5011
|
-
/** Sticky header */
|
|
5012
|
-
stickyHeader?: boolean;
|
|
5013
|
-
/** Additional className for the root wrapper */
|
|
5014
|
-
className?: string;
|
|
5015
|
-
/** Caption text below the table */
|
|
5016
|
-
caption?: string;
|
|
5017
|
-
/** Total result count shown above table (e.g. "۲۴ نتیجه") */
|
|
5018
|
-
resultCount?: React$1.ReactNode;
|
|
5019
|
-
/** Locale for UI strings @default 'fa' */
|
|
5020
|
-
locale?: SupportedLocale;
|
|
5021
|
-
}
|
|
5022
|
-
declare const DataTable: <TData>(props: DataTableProps<TData> & {
|
|
5023
|
-
ref?: React$1.ForwardedRef<HTMLDivElement>;
|
|
5024
|
-
}) => React$1.ReactElement;
|
|
5025
|
-
|
|
5026
5240
|
/**
|
|
5027
5241
|
* data-table-cells — opinionated thin wrappers around DS primitives, sized
|
|
5028
5242
|
* and styled for use as `DataTableColumn.cell` values. Each cell renderer
|
|
@@ -5278,42 +5492,6 @@ interface SafeImageProps extends React$1.ImgHTMLAttributes<HTMLImageElement> {
|
|
|
5278
5492
|
}
|
|
5279
5493
|
declare const SafeImage: React$1.ForwardRefExoticComponent<SafeImageProps & React$1.RefAttributes<HTMLImageElement>>;
|
|
5280
5494
|
|
|
5281
|
-
/**
|
|
5282
|
-
* SavedQueryCard — saved-search tile for analyst dashboards. Shows query
|
|
5283
|
-
* description + filter summary chips, run count, last-run timestamp, and a
|
|
5284
|
-
* one-click "run again" action button. Optional star/favorite toggle.
|
|
5285
|
-
*/
|
|
5286
|
-
interface SavedQueryFilter {
|
|
5287
|
-
/** Filter label (e.g., "احساس") */
|
|
5288
|
-
label: React$1.ReactNode;
|
|
5289
|
-
/** Filter value (e.g., "منفی") */
|
|
5290
|
-
value: React$1.ReactNode;
|
|
5291
|
-
}
|
|
5292
|
-
interface SavedQueryCardProps extends React$1.HTMLAttributes<HTMLDivElement> {
|
|
5293
|
-
/** Saved query name */
|
|
5294
|
-
name: React$1.ReactNode;
|
|
5295
|
-
/** Optional 1-line description */
|
|
5296
|
-
description?: React$1.ReactNode;
|
|
5297
|
-
/** Filter chips (label + value pairs) */
|
|
5298
|
-
filters?: SavedQueryFilter[];
|
|
5299
|
-
/** Total run count */
|
|
5300
|
-
runCount?: number;
|
|
5301
|
-
/** Last-run display (e.g., "۲ روز پیش") */
|
|
5302
|
-
lastRun?: React$1.ReactNode;
|
|
5303
|
-
/** Run-now callback */
|
|
5304
|
-
onRun?: () => void;
|
|
5305
|
-
/** Run button label override */
|
|
5306
|
-
runLabel?: React$1.ReactNode;
|
|
5307
|
-
/** Favorite/star state. When set, renders the star toggle */
|
|
5308
|
-
favorite?: {
|
|
5309
|
-
starred: boolean;
|
|
5310
|
-
onChange: (next: boolean) => void;
|
|
5311
|
-
};
|
|
5312
|
-
/** Locale @default 'fa' */
|
|
5313
|
-
locale?: SupportedLocale;
|
|
5314
|
-
}
|
|
5315
|
-
declare const SavedQueryCard: React$1.ForwardRefExoticComponent<SavedQueryCardProps & React$1.RefAttributes<HTMLDivElement>>;
|
|
5316
|
-
|
|
5317
5495
|
interface ReportComposerProps extends Omit<React$1.HTMLAttributes<HTMLDivElement>, 'title'> {
|
|
5318
5496
|
/** Report title (e.g., "بولتن هفتگی — هفته ۱۴") */
|
|
5319
5497
|
title?: React$1.ReactNode;
|
|
@@ -5364,6 +5542,114 @@ interface BulletinViewerProps extends Omit<React$1.HTMLAttributes<HTMLDivElement
|
|
|
5364
5542
|
}
|
|
5365
5543
|
declare const BulletinViewer: React$1.ForwardRefExoticComponent<BulletinViewerProps & React$1.RefAttributes<HTMLDivElement>>;
|
|
5366
5544
|
|
|
5545
|
+
/**
|
|
5546
|
+
* Report section templates — thin compositions of existing primitives that
|
|
5547
|
+
* each render inside a `<ReportSection>` shell. They cover the 6 layouts
|
|
5548
|
+
* that recur across every افکارسنجی bulletin we've seen:
|
|
5549
|
+
*
|
|
5550
|
+
* 1. ExecutiveSummarySection — title + AI paragraph + tile metrics
|
|
5551
|
+
* 2. SentimentBreakdownSection — sentiment + optional 9-emotion side-by-side
|
|
5552
|
+
* 3. FlowDistributionSection — political-flow stacked bar
|
|
5553
|
+
* 4. TopPostsSection — compact PostList of N highlighted posts
|
|
5554
|
+
* 5. TimelineSection — line chart with optional sparkline summary
|
|
5555
|
+
* 6. SourceBreakdownSection — per-platform metric grid
|
|
5556
|
+
*
|
|
5557
|
+
* Each template is intentionally thin — props mirror the underlying
|
|
5558
|
+
* primitive when possible. Consumers compose these inside a
|
|
5559
|
+
* `<ReportComposer>`; for non-template sections, `<ReportSection>` is
|
|
5560
|
+
* still the building block.
|
|
5561
|
+
*/
|
|
5562
|
+
|
|
5563
|
+
type ReportSectionShellProps = Pick<ReportSectionProps, 'enabled' | 'onEnabledChange' | 'collapsed' | 'onCollapsedChange' | 'draggable' | 'onDragHandlePointerDown' | 'onSettingsClick' | 'headerActions'>;
|
|
5564
|
+
interface ExecutiveSummaryMetric {
|
|
5565
|
+
label: string;
|
|
5566
|
+
value: number | string;
|
|
5567
|
+
/** Pre-formatted display value. When omitted, numeric `value` is locale-formatted via `formatLargeNumber`. */
|
|
5568
|
+
displayValue?: string;
|
|
5569
|
+
/** Optional delta (percent vs previous period). */
|
|
5570
|
+
delta?: number;
|
|
5571
|
+
/** Optional unit string appended to the value (e.g. ' %'). */
|
|
5572
|
+
unit?: string;
|
|
5573
|
+
}
|
|
5574
|
+
interface ExecutiveSummarySectionProps extends ReportSectionShellProps {
|
|
5575
|
+
/** Section title (e.g., "خلاصه اجرایی") */
|
|
5576
|
+
title?: React$1.ReactNode;
|
|
5577
|
+
description?: React$1.ReactNode;
|
|
5578
|
+
/** AI / analyst-written paragraph (1–4 sentences). */
|
|
5579
|
+
summary: React$1.ReactNode;
|
|
5580
|
+
/** Up to 4 KPIs rendered as a row of tiles. */
|
|
5581
|
+
metrics?: ExecutiveSummaryMetric[];
|
|
5582
|
+
locale?: SupportedLocale;
|
|
5583
|
+
}
|
|
5584
|
+
declare const ExecutiveSummarySection: React$1.ForwardRefExoticComponent<ExecutiveSummarySectionProps & React$1.RefAttributes<HTMLDivElement>>;
|
|
5585
|
+
interface SentimentBreakdownSectionProps extends ReportSectionShellProps {
|
|
5586
|
+
title?: React$1.ReactNode;
|
|
5587
|
+
description?: React$1.ReactNode;
|
|
5588
|
+
/** 3-class sentiment counts (auto-normalized). */
|
|
5589
|
+
sentiment: SentimentData;
|
|
5590
|
+
/** Optional 9-emotion breakdown rendered alongside. */
|
|
5591
|
+
emotions?: Partial<Record<EmotionKey, number>>;
|
|
5592
|
+
locale?: SupportedLocale;
|
|
5593
|
+
}
|
|
5594
|
+
declare const SentimentBreakdownSection: React$1.ForwardRefExoticComponent<SentimentBreakdownSectionProps & React$1.RefAttributes<HTMLDivElement>>;
|
|
5595
|
+
interface FlowDistributionSectionProps extends ReportSectionShellProps {
|
|
5596
|
+
title?: React$1.ReactNode;
|
|
5597
|
+
description?: React$1.ReactNode;
|
|
5598
|
+
/** Political-flow counts (5 keys). */
|
|
5599
|
+
flow: Partial<Record<FlowKey, number>>;
|
|
5600
|
+
locale?: SupportedLocale;
|
|
5601
|
+
}
|
|
5602
|
+
declare const FlowDistributionSection: React$1.ForwardRefExoticComponent<FlowDistributionSectionProps & React$1.RefAttributes<HTMLDivElement>>;
|
|
5603
|
+
interface TopPostsSectionProps extends ReportSectionShellProps {
|
|
5604
|
+
title?: React$1.ReactNode;
|
|
5605
|
+
description?: React$1.ReactNode;
|
|
5606
|
+
posts: PostData[];
|
|
5607
|
+
/** Render only the first N posts. @default 5 */
|
|
5608
|
+
topN?: number;
|
|
5609
|
+
/** Density passed through to PostList. @default 'compact' */
|
|
5610
|
+
density?: 'compact' | 'comfortable';
|
|
5611
|
+
locale?: SupportedLocale;
|
|
5612
|
+
}
|
|
5613
|
+
declare const TopPostsSection: React$1.ForwardRefExoticComponent<TopPostsSectionProps & React$1.RefAttributes<HTMLDivElement>>;
|
|
5614
|
+
interface TimelineSectionProps extends ReportSectionShellProps {
|
|
5615
|
+
title?: React$1.ReactNode;
|
|
5616
|
+
description?: React$1.ReactNode;
|
|
5617
|
+
/** Row-oriented timeline data: [{ name: '۱ فروردین', volume: 1240 }, …] */
|
|
5618
|
+
data: Array<Record<string, string | number>>;
|
|
5619
|
+
/** Series keys to plot. */
|
|
5620
|
+
dataKeys: string[];
|
|
5621
|
+
/** Pixel chart height. @default 240 */
|
|
5622
|
+
chartHeight?: number;
|
|
5623
|
+
/**
|
|
5624
|
+
* Optional one-line summary of the trend, rendered as a sparkline + delta
|
|
5625
|
+
* pair below the chart. Pass a single series name and a "from" / "to" pair
|
|
5626
|
+
* to highlight the period delta.
|
|
5627
|
+
*/
|
|
5628
|
+
summary?: {
|
|
5629
|
+
seriesKey: string;
|
|
5630
|
+
from: number;
|
|
5631
|
+
to: number;
|
|
5632
|
+
};
|
|
5633
|
+
/** Custom axes (forwarded to PartoLineChart). */
|
|
5634
|
+
axisLeft?: Record<string, unknown>;
|
|
5635
|
+
axisBottom?: Record<string, unknown>;
|
|
5636
|
+
locale?: SupportedLocale;
|
|
5637
|
+
}
|
|
5638
|
+
declare const TimelineSection: React$1.ForwardRefExoticComponent<TimelineSectionProps & React$1.RefAttributes<HTMLDivElement>>;
|
|
5639
|
+
interface SourceBreakdownEntry {
|
|
5640
|
+
platform: SocialPlatform;
|
|
5641
|
+
count: number;
|
|
5642
|
+
/** Pre-computed share percent. When omitted, percent is computed across all entries. */
|
|
5643
|
+
percent?: number;
|
|
5644
|
+
}
|
|
5645
|
+
interface SourceBreakdownSectionProps extends ReportSectionShellProps {
|
|
5646
|
+
title?: React$1.ReactNode;
|
|
5647
|
+
description?: React$1.ReactNode;
|
|
5648
|
+
sources: SourceBreakdownEntry[];
|
|
5649
|
+
locale?: SupportedLocale;
|
|
5650
|
+
}
|
|
5651
|
+
declare const SourceBreakdownSection: React$1.ForwardRefExoticComponent<SourceBreakdownSectionProps & React$1.RefAttributes<HTMLDivElement>>;
|
|
5652
|
+
|
|
5367
5653
|
declare const calloutVariants: (props?: ({
|
|
5368
5654
|
variant?: "neutral" | "warning" | "success" | "info" | "destructive" | null | undefined;
|
|
5369
5655
|
} & class_variance_authority_types.ClassProp) | undefined) => string;
|
|
@@ -5408,122 +5694,6 @@ interface SectionNavigatorProps extends React$1.HTMLAttributes<HTMLElement> {
|
|
|
5408
5694
|
}
|
|
5409
5695
|
declare const SectionNavigator: React$1.ForwardRefExoticComponent<SectionNavigatorProps & React$1.RefAttributes<HTMLElement>>;
|
|
5410
5696
|
|
|
5411
|
-
interface PartoLineChartProps {
|
|
5412
|
-
/** Row-oriented data: [{ name: "فروردین", series1: 50, series2: 30 }] */
|
|
5413
|
-
data: Array<Record<string, any>>;
|
|
5414
|
-
/** Keys for each line series (e.g. ['فروش', 'سود']) */
|
|
5415
|
-
dataKeys: string[];
|
|
5416
|
-
/** Field name for X axis (default: 'name') */
|
|
5417
|
-
xAxisKey?: string;
|
|
5418
|
-
/** Curve type */
|
|
5419
|
-
curve?: 'monotone' | 'linear' | 'natural' | 'step';
|
|
5420
|
-
/** Line width */
|
|
5421
|
-
strokeWidth?: number;
|
|
5422
|
-
/** Show dots on data points */
|
|
5423
|
-
showDots?: boolean;
|
|
5424
|
-
/** Show horizontal grid lines */
|
|
5425
|
-
enableGridY?: boolean;
|
|
5426
|
-
/** Show vertical grid lines */
|
|
5427
|
-
enableGridX?: boolean;
|
|
5428
|
-
/** Chart margins */
|
|
5429
|
-
margin?: {
|
|
5430
|
-
top?: number;
|
|
5431
|
-
right?: number;
|
|
5432
|
-
bottom?: number;
|
|
5433
|
-
left?: number;
|
|
5434
|
-
};
|
|
5435
|
-
/** Custom X axis config */
|
|
5436
|
-
axisBottom?: Record<string, any> | null;
|
|
5437
|
-
/** Custom Y axis config */
|
|
5438
|
-
axisLeft?: Record<string, any> | null;
|
|
5439
|
-
/** Custom tooltip formatter */
|
|
5440
|
-
tooltipFormatter?: (name: string, value: number) => React$1.ReactNode;
|
|
5441
|
-
className?: string;
|
|
5442
|
-
isLoading?: boolean;
|
|
5443
|
-
ariaLabel?: string;
|
|
5444
|
-
/** Additional Recharts LineChart props */
|
|
5445
|
-
chartProps?: Record<string, any>;
|
|
5446
|
-
}
|
|
5447
|
-
declare const PartoLineChart: React$1.ForwardRefExoticComponent<PartoLineChartProps & React$1.RefAttributes<HTMLDivElement>>;
|
|
5448
|
-
|
|
5449
|
-
interface PartoBarChartProps {
|
|
5450
|
-
/** Chart data — row-oriented array of objects */
|
|
5451
|
-
data: Array<Record<string, any>>;
|
|
5452
|
-
/** Data keys to render as bars (e.g. ['فروش', 'هزینه']) */
|
|
5453
|
-
keys: string[];
|
|
5454
|
-
/** Field name used for X axis categories (e.g. 'ماه') */
|
|
5455
|
-
indexBy: string;
|
|
5456
|
-
/** Stacked or grouped layout */
|
|
5457
|
-
groupMode?: 'grouped' | 'stacked';
|
|
5458
|
-
/** Bar layout direction */
|
|
5459
|
-
layout?: 'vertical' | 'horizontal';
|
|
5460
|
-
/** Chart margins */
|
|
5461
|
-
margin?: {
|
|
5462
|
-
top?: number;
|
|
5463
|
-
right?: number;
|
|
5464
|
-
bottom?: number;
|
|
5465
|
-
left?: number;
|
|
5466
|
-
};
|
|
5467
|
-
/** Gap between category groups as percentage */
|
|
5468
|
-
barCategoryGap?: string | number;
|
|
5469
|
-
/** Gap between bars within a group */
|
|
5470
|
-
barGap?: number;
|
|
5471
|
-
/** Border radius for bar tops [topLeft, topRight, bottomRight, bottomLeft] */
|
|
5472
|
-
radius?: [number, number, number, number];
|
|
5473
|
-
/** Show horizontal grid lines */
|
|
5474
|
-
enableGridY?: boolean;
|
|
5475
|
-
/** Show vertical grid lines */
|
|
5476
|
-
enableGridX?: boolean;
|
|
5477
|
-
/** Show labels inside bars */
|
|
5478
|
-
enableLabel?: boolean;
|
|
5479
|
-
/** Custom X axis config */
|
|
5480
|
-
axisBottom?: Record<string, any> | null;
|
|
5481
|
-
/** Custom Y axis config */
|
|
5482
|
-
axisLeft?: Record<string, any> | null;
|
|
5483
|
-
/** Custom tooltip formatter */
|
|
5484
|
-
tooltipFormatter?: (name: string, value: number) => React$1.ReactNode;
|
|
5485
|
-
className?: string;
|
|
5486
|
-
isLoading?: boolean;
|
|
5487
|
-
ariaLabel?: string;
|
|
5488
|
-
/** Additional Recharts BarChart props */
|
|
5489
|
-
chartProps?: Record<string, any>;
|
|
5490
|
-
}
|
|
5491
|
-
declare const PartoBarChart: React$1.ForwardRefExoticComponent<PartoBarChartProps & React$1.RefAttributes<HTMLDivElement>>;
|
|
5492
|
-
|
|
5493
|
-
interface PartoPieChartProps {
|
|
5494
|
-
/** Data: [{ name: "محصول A", value: 40 }] */
|
|
5495
|
-
data: Array<{
|
|
5496
|
-
name: string;
|
|
5497
|
-
value: number;
|
|
5498
|
-
[key: string]: any;
|
|
5499
|
-
}>;
|
|
5500
|
-
/** Inner radius — 0 for full pie, "60%" for donut */
|
|
5501
|
-
innerRadius?: number | string;
|
|
5502
|
-
/** Outer radius */
|
|
5503
|
-
outerRadius?: number | string;
|
|
5504
|
-
/** Angle between slices in degrees */
|
|
5505
|
-
paddingAngle?: number;
|
|
5506
|
-
/** Corner radius of arc segments */
|
|
5507
|
-
cornerRadius?: number;
|
|
5508
|
-
/** Show arc link labels (lines from slices to text) */
|
|
5509
|
-
showLabels?: boolean;
|
|
5510
|
-
/** Skip labels for slices smaller than this angle */
|
|
5511
|
-
labelSkipAngle?: number;
|
|
5512
|
-
/** Chart margins */
|
|
5513
|
-
margin?: {
|
|
5514
|
-
top?: number;
|
|
5515
|
-
right?: number;
|
|
5516
|
-
bottom?: number;
|
|
5517
|
-
left?: number;
|
|
5518
|
-
};
|
|
5519
|
-
/** Custom tooltip formatter */
|
|
5520
|
-
tooltipFormatter?: (name: string, value: number) => React$1.ReactNode;
|
|
5521
|
-
className?: string;
|
|
5522
|
-
isLoading?: boolean;
|
|
5523
|
-
ariaLabel?: string;
|
|
5524
|
-
}
|
|
5525
|
-
declare const PartoPieChart: React$1.ForwardRefExoticComponent<PartoPieChartProps & React$1.RefAttributes<HTMLDivElement>>;
|
|
5526
|
-
|
|
5527
5697
|
/**
|
|
5528
5698
|
* PartoWordCloud — modern word cloud with smooth hover transitions,
|
|
5529
5699
|
* glassmorphic tooltip, and brand-harmonious coloring.
|
|
@@ -5552,52 +5722,20 @@ interface PartoWordCloudProps {
|
|
|
5552
5722
|
isLoading?: boolean;
|
|
5553
5723
|
/** Accessible label describing the chart content */
|
|
5554
5724
|
ariaLabel?: string;
|
|
5725
|
+
/** Locale for the empty-state message @default 'fa' */
|
|
5726
|
+
locale?: SupportedLocale;
|
|
5727
|
+
/**
|
|
5728
|
+
* Render a small caption below the cloud explaining that word size
|
|
5729
|
+
* encodes frequency. Helps colorblind / sighted-but-confused users —
|
|
5730
|
+
* word color is decorative (palette rotation), not semantic. @default `false`
|
|
5731
|
+
*/
|
|
5732
|
+
legend?: boolean;
|
|
5555
5733
|
}
|
|
5556
|
-
declare function PartoWordCloud({ words, width: widthProp, height: heightProp, className, minFontSize, maxFontSize, padding, spiral, rotate, random, fontWeight, onWordClick, isLoading, ariaLabel, }: PartoWordCloudProps): react_jsx_runtime.JSX.Element;
|
|
5734
|
+
declare function PartoWordCloud({ words, width: widthProp, height: heightProp, className, minFontSize, maxFontSize, padding, spiral, rotate, random, fontWeight, onWordClick, isLoading, ariaLabel, locale, legend, }: PartoWordCloudProps): react_jsx_runtime.JSX.Element;
|
|
5557
5735
|
declare namespace PartoWordCloud {
|
|
5558
5736
|
var displayName: string;
|
|
5559
5737
|
}
|
|
5560
5738
|
|
|
5561
|
-
interface PartoAreaChartProps {
|
|
5562
|
-
/** Row-oriented data: [{ name: "فروردین", series1: 50, series2: 30 }] */
|
|
5563
|
-
data: Array<Record<string, any>>;
|
|
5564
|
-
/** Keys for each area series (e.g. ['فروش', 'سود']) */
|
|
5565
|
-
dataKeys: string[];
|
|
5566
|
-
/** Field name for X axis (default: 'name') */
|
|
5567
|
-
xAxisKey?: string;
|
|
5568
|
-
/** Curve type */
|
|
5569
|
-
curve?: 'monotone' | 'linear' | 'natural' | 'step';
|
|
5570
|
-
/** Line width */
|
|
5571
|
-
strokeWidth?: number;
|
|
5572
|
-
/** Area fill opacity */
|
|
5573
|
-
fillOpacity?: number;
|
|
5574
|
-
/** Show dots on data points */
|
|
5575
|
-
showDots?: boolean;
|
|
5576
|
-
/** Show horizontal grid lines */
|
|
5577
|
-
enableGridY?: boolean;
|
|
5578
|
-
/** Show vertical grid lines */
|
|
5579
|
-
enableGridX?: boolean;
|
|
5580
|
-
/** Chart margins */
|
|
5581
|
-
margin?: {
|
|
5582
|
-
top?: number;
|
|
5583
|
-
right?: number;
|
|
5584
|
-
bottom?: number;
|
|
5585
|
-
left?: number;
|
|
5586
|
-
};
|
|
5587
|
-
/** Custom X axis config */
|
|
5588
|
-
axisBottom?: Record<string, any> | null;
|
|
5589
|
-
/** Custom Y axis config */
|
|
5590
|
-
axisLeft?: Record<string, any> | null;
|
|
5591
|
-
/** Custom tooltip formatter */
|
|
5592
|
-
tooltipFormatter?: (name: string, value: number) => React$1.ReactNode;
|
|
5593
|
-
className?: string;
|
|
5594
|
-
isLoading?: boolean;
|
|
5595
|
-
ariaLabel?: string;
|
|
5596
|
-
/** Additional Recharts AreaChart props */
|
|
5597
|
-
chartProps?: Record<string, any>;
|
|
5598
|
-
}
|
|
5599
|
-
declare const PartoAreaChart: React$1.ForwardRefExoticComponent<PartoAreaChartProps & React$1.RefAttributes<HTMLDivElement>>;
|
|
5600
|
-
|
|
5601
5739
|
/**
|
|
5602
5740
|
* PartoScatterChart — x/y scatter with optional bubble sizing (z) and
|
|
5603
5741
|
* per-point color override. Wraps Recharts ScatterChart with theme-aware
|
|
@@ -5656,6 +5794,11 @@ interface PartoScatterChartProps {
|
|
|
5656
5794
|
className?: string;
|
|
5657
5795
|
isLoading?: boolean;
|
|
5658
5796
|
ariaLabel?: string;
|
|
5797
|
+
/**
|
|
5798
|
+
* Render a legend below the chart. Only meaningful when `groupKey` is set —
|
|
5799
|
+
* the legend lists each group with its assigned color. @default `false`
|
|
5800
|
+
*/
|
|
5801
|
+
legend?: boolean;
|
|
5659
5802
|
}
|
|
5660
5803
|
declare const PartoScatterChart: React$1.ForwardRefExoticComponent<PartoScatterChartProps & React$1.RefAttributes<HTMLDivElement>>;
|
|
5661
5804
|
|
|
@@ -5710,6 +5853,12 @@ interface PartoSankeyChartProps {
|
|
|
5710
5853
|
className?: string;
|
|
5711
5854
|
isLoading?: boolean;
|
|
5712
5855
|
ariaLabel?: string;
|
|
5856
|
+
/**
|
|
5857
|
+
* Render a legend listing each node with its color. Useful for flows
|
|
5858
|
+
* where node names aren't always visible (small column widths). The
|
|
5859
|
+
* legend shows the same color the node rectangle uses. @default `false`
|
|
5860
|
+
*/
|
|
5861
|
+
legend?: boolean;
|
|
5713
5862
|
}
|
|
5714
5863
|
declare const PartoSankeyChart: React$1.ForwardRefExoticComponent<PartoSankeyChartProps & React$1.RefAttributes<HTMLDivElement>>;
|
|
5715
5864
|
|
|
@@ -5789,6 +5938,16 @@ interface ConceptPulseChartProps {
|
|
|
5789
5938
|
className?: string;
|
|
5790
5939
|
isLoading?: boolean;
|
|
5791
5940
|
ariaLabel?: string;
|
|
5941
|
+
/**
|
|
5942
|
+
* Render a legend below the chart that maps composition arc colors to
|
|
5943
|
+
* their category names (flow/emotion/custom). Only categories that
|
|
5944
|
+
* appear in at least one bubble's composition are listed.
|
|
5945
|
+
*
|
|
5946
|
+
* Without a legend, the arc colors are decipherable only via hover —
|
|
5947
|
+
* which fails WCAG 1.4.1 for the core "what is this composition?"
|
|
5948
|
+
* question. @default `false`
|
|
5949
|
+
*/
|
|
5950
|
+
legend?: boolean;
|
|
5792
5951
|
}
|
|
5793
5952
|
declare const ConceptPulseChart: React$1.ForwardRefExoticComponent<ConceptPulseChartProps & React$1.RefAttributes<HTMLDivElement>>;
|
|
5794
5953
|
|
|
@@ -5848,6 +6007,12 @@ interface PartoNetworkChartProps {
|
|
|
5848
6007
|
className?: string;
|
|
5849
6008
|
isLoading?: boolean;
|
|
5850
6009
|
ariaLabel?: string;
|
|
6010
|
+
/**
|
|
6011
|
+
* Render a legend listing each node group with its assigned color.
|
|
6012
|
+
* Pulled from the unique `group` values across `nodes`. When no node
|
|
6013
|
+
* has a `group`, the legend silently renders nothing. @default `false`
|
|
6014
|
+
*/
|
|
6015
|
+
legend?: boolean;
|
|
5851
6016
|
}
|
|
5852
6017
|
declare const PartoNetworkChart: React$1.ForwardRefExoticComponent<PartoNetworkChartProps & React$1.RefAttributes<HTMLDivElement>>;
|
|
5853
6018
|
|
|
@@ -5989,8 +6154,88 @@ interface ChartTooltipProps {
|
|
|
5989
6154
|
label?: string;
|
|
5990
6155
|
tooltipStyle: React$1.CSSProperties;
|
|
5991
6156
|
formatter?: (name: string, value: number) => React$1.ReactNode;
|
|
6157
|
+
/** Locale for the default value formatter. fa/ar render Persian/Arabic digits with thousands separators; en uses Latin. */
|
|
6158
|
+
locale?: SupportedLocale;
|
|
6159
|
+
}
|
|
6160
|
+
declare function ChartTooltip({ active, payload, label, tooltipStyle, formatter, locale }: ChartTooltipProps): react_jsx_runtime.JSX.Element | null;
|
|
6161
|
+
/**
|
|
6162
|
+
* Default tickFormatter for numeric chart axes (Y axis on Line/Area/Bar, both
|
|
6163
|
+
* axes on Scatter, radial on Radar). Renders Persian/Arabic digits + locale
|
|
6164
|
+
* suffix ("۱.۵ هزار", "1.5K") for fa/ar, Latin K/M/B for en.
|
|
6165
|
+
*
|
|
6166
|
+
* Pass via `axisLeft={{ tickFormatter: localeAwareNumberTick('fa') }}`, or rely
|
|
6167
|
+
* on the chart wrapper's `locale` prop which wires this in by default.
|
|
6168
|
+
*/
|
|
6169
|
+
declare function localeAwareNumberTick(locale: SupportedLocale): (value: unknown) => string;
|
|
6170
|
+
/**
|
|
6171
|
+
* Default tickFormatter for categorical chart axes — converts embedded digits
|
|
6172
|
+
* to the locale's numerals (e.g. "۱۴۰۳-۰۱" for "1403-01") without altering
|
|
6173
|
+
* letters. Use on date/time axes whose labels carry digits.
|
|
6174
|
+
*/
|
|
6175
|
+
declare function localeAwareCategoryTick(locale: SupportedLocale): (value: unknown) => string;
|
|
6176
|
+
interface ChartLegendItem {
|
|
6177
|
+
/** Unique identifier — typically the dataKey or series id. */
|
|
6178
|
+
key: string;
|
|
6179
|
+
/** Display label. Strings preferred so AT can read it. */
|
|
6180
|
+
label: React$1.ReactNode;
|
|
6181
|
+
/** Marker color. Pass the resolved value (hsl, hex, or `var(--token)`). */
|
|
6182
|
+
color: string;
|
|
6183
|
+
/**
|
|
6184
|
+
* Marker shape. `dot` for categorical (Bar/Pie), `line` for series (Line/Area),
|
|
6185
|
+
* `bar` for stacked distributions. @default `dot`
|
|
6186
|
+
*/
|
|
6187
|
+
shape?: 'dot' | 'line' | 'bar';
|
|
6188
|
+
/**
|
|
6189
|
+
* Optional stroke pattern when `shape="line"`. Lets color-blind users
|
|
6190
|
+
* distinguish series by texture in addition to color. WCAG 1.4.1
|
|
6191
|
+
* (Use of Color) recommends adding a non-color signal.
|
|
6192
|
+
*/
|
|
6193
|
+
pattern?: 'solid' | 'dashed' | 'dotted' | 'dash-dot';
|
|
6194
|
+
/** Optional trailing value (count, percent, etc.). */
|
|
6195
|
+
value?: React$1.ReactNode;
|
|
6196
|
+
}
|
|
6197
|
+
interface ChartLegendProps extends React$1.HTMLAttributes<HTMLDivElement> {
|
|
6198
|
+
/** Series to enumerate. */
|
|
6199
|
+
items: ChartLegendItem[];
|
|
6200
|
+
/** Layout — `horizontal` wraps, `vertical` stacks. @default `horizontal` */
|
|
6201
|
+
orientation?: 'horizontal' | 'vertical';
|
|
6202
|
+
/** Marker square/dot edge length in px. @default `10` */
|
|
6203
|
+
swatchSize?: number;
|
|
6204
|
+
}
|
|
6205
|
+
/**
|
|
6206
|
+
* Reusable chart legend. Pair with `PartoLineChart`, `PartoBarChart`, etc. by
|
|
6207
|
+
* passing `legend={[…]}` or rendering `<ChartLegend>` next to the chart. Each
|
|
6208
|
+
* line-shape entry can carry a stroke pattern so colorblind users can read
|
|
6209
|
+
* series identity without relying on color alone.
|
|
6210
|
+
*
|
|
6211
|
+
* The legend has no chart-aware behavior on its own — pass the same colors
|
|
6212
|
+
* (resolved via `useChartTheme`) you handed to the chart's `Cell`/series.
|
|
6213
|
+
*/
|
|
6214
|
+
declare const ChartLegend: React$1.ForwardRefExoticComponent<ChartLegendProps & React$1.RefAttributes<HTMLDivElement>>;
|
|
6215
|
+
interface ChartGradientLegendProps extends React$1.HTMLAttributes<HTMLDivElement> {
|
|
6216
|
+
/** Color at the low end of the scale (e.g. background-muted). */
|
|
6217
|
+
startColor: string;
|
|
6218
|
+
/** Color at the high end (e.g. brand). */
|
|
6219
|
+
endColor: string;
|
|
6220
|
+
/** Optional left/start label (typically the minimum value). */
|
|
6221
|
+
startLabel?: React$1.ReactNode;
|
|
6222
|
+
/** Optional right/end label (typically the maximum value). */
|
|
6223
|
+
endLabel?: React$1.ReactNode;
|
|
6224
|
+
/** Optional caption above the bar (e.g. "تراکم انتشار"). */
|
|
6225
|
+
caption?: React$1.ReactNode;
|
|
6226
|
+
/** Bar width in px @default 160 */
|
|
6227
|
+
width?: number;
|
|
6228
|
+
/** Bar height in px @default 8 */
|
|
6229
|
+
height?: number;
|
|
5992
6230
|
}
|
|
5993
|
-
|
|
6231
|
+
/**
|
|
6232
|
+
* Continuous-scale legend for charts whose data is encoded as color intensity
|
|
6233
|
+
* (HeatMap, choropleth, gradient density). Renders a horizontal gradient bar
|
|
6234
|
+
* with start/end labels, captioned for AT via `role="img"` + `aria-label`.
|
|
6235
|
+
*
|
|
6236
|
+
* For discrete categorical legends (Line/Bar/Pie), use `<ChartLegend>` instead.
|
|
6237
|
+
*/
|
|
6238
|
+
declare const ChartGradientLegend: React$1.ForwardRefExoticComponent<ChartGradientLegendProps & React$1.RefAttributes<HTMLDivElement>>;
|
|
5994
6239
|
/**
|
|
5995
6240
|
* Transforms Nivo line/area data format to Recharts row-oriented format.
|
|
5996
6241
|
* Useful for consumers migrating from Nivo data shape.
|
|
@@ -6019,6 +6264,46 @@ declare function transformNivoLineData(nivoData: Array<{
|
|
|
6019
6264
|
*/
|
|
6020
6265
|
declare function useScrollLock(locked: boolean): void;
|
|
6021
6266
|
|
|
6267
|
+
interface ShortcutsCheatsheetProps {
|
|
6268
|
+
/** Controlled open state. If omitted, the cheatsheet manages its own open state. */
|
|
6269
|
+
open?: boolean;
|
|
6270
|
+
onOpenChange?: (open: boolean) => void;
|
|
6271
|
+
/**
|
|
6272
|
+
* Global keyboard shortcut to toggle the cheatsheet. Default: `'shift+?'`.
|
|
6273
|
+
* Pass `false` to disable the global listener (useful when wiring your own).
|
|
6274
|
+
*/
|
|
6275
|
+
shortcut?: HotkeyCombo | false;
|
|
6276
|
+
/** Trigger node — when set, the cheatsheet opens on click. Otherwise opening is controlled or via shortcut. */
|
|
6277
|
+
trigger?: React$1.ReactNode;
|
|
6278
|
+
/** Custom title (defaults to a localized "Keyboard shortcuts"). */
|
|
6279
|
+
title?: React$1.ReactNode;
|
|
6280
|
+
/** Custom description shown under the title. */
|
|
6281
|
+
description?: React$1.ReactNode;
|
|
6282
|
+
/** Locale for default strings + sort tie-breaks. */
|
|
6283
|
+
locale?: SupportedLocale;
|
|
6284
|
+
/** Override which entries to show. Defaults to the active provider's full registry. */
|
|
6285
|
+
hotkeys?: RegisteredHotkey[];
|
|
6286
|
+
/** Optional empty-state customization when the registry is empty. */
|
|
6287
|
+
emptyState?: React$1.ReactNode;
|
|
6288
|
+
className?: string;
|
|
6289
|
+
}
|
|
6290
|
+
/**
|
|
6291
|
+
* Visual help overlay that lists every hotkey registered with the active
|
|
6292
|
+
* `<HotkeyProvider>`. Opens on `Shift+?` by default (configurable) or via a
|
|
6293
|
+
* trigger button. Renders nothing useful outside a HotkeyProvider — the
|
|
6294
|
+
* registry is empty and the empty state shows.
|
|
6295
|
+
*
|
|
6296
|
+
* @example
|
|
6297
|
+
* <HotkeyProvider>
|
|
6298
|
+
* <ShortcutsCheatsheet />
|
|
6299
|
+
* <App /> // descendants register via useHotkey()
|
|
6300
|
+
* </HotkeyProvider>
|
|
6301
|
+
*
|
|
6302
|
+
* Pair with `useHotkey('?', 'shift+?', () => setOpen(true))` if you prefer
|
|
6303
|
+
* to wire the toggle yourself; the built-in shortcut is just a convenience.
|
|
6304
|
+
*/
|
|
6305
|
+
declare const ShortcutsCheatsheet: React$1.ForwardRefExoticComponent<ShortcutsCheatsheetProps & React$1.RefAttributes<HTMLDivElement>>;
|
|
6306
|
+
|
|
6022
6307
|
/**
|
|
6023
6308
|
* Fires `handler` whenever a pointer event lands outside the referenced
|
|
6024
6309
|
* element. Use for closing dropdowns, popovers, dismissable cards, etc.
|
|
@@ -6128,4 +6413,91 @@ interface UseAsyncReturn<T> {
|
|
|
6128
6413
|
}
|
|
6129
6414
|
declare function useAsync<T = unknown>(initialData?: T | null): UseAsyncReturn<T>;
|
|
6130
6415
|
|
|
6131
|
-
export { ACTION_STATUS_KEYS, ACTION_TYPE_KEYS, ACTION_TYPE_META, Accordion, AccordionContent, AccordionItem, AccordionTrigger, type ActionStatusKey, ActionTimeline, type ActionTimelineDensity, type ActionTimelineGroupBy, ActionTimelineItem, type ActionTimelineItemData, type ActionTimelineItemProps, type ActionTimelineProps, ActionTypeChip, type ActionTypeChipProps, type ActionTypeKey, ActiveFiltersBar, type ActiveFiltersBarProps, ActiveFiltersClearAll, type ActiveFiltersClearAllProps, Alert, type AlertChannel, AlertDescription, AlertDialog, AlertDialogAction, AlertDialogCancel, AlertDialogContent, AlertDialogDescription, AlertDialogFooter, AlertDialogHeader, AlertDialogOverlay, AlertDialogPortal, AlertDialogTitle, AlertDialogTrigger, AlertRuleCard, type AlertRuleCardProps, AlertTitle, AnimatedNumber, type AnimatedNumberProps, AppBar, type AppBarProps, AppLayout, AppLayoutContent, AspectRatio, type AsyncStatus, Autocomplete, type AutocompleteItem, type AutocompleteProps, Avatar, AvatarFallback, AvatarGroup, type AvatarGroupItem, type AvatarGroupProps, AvatarImage, AvatarTextSkeleton, type AvatarTextSkeletonProps, Badge, type BadgeProps, Banner, type BannerProps, type BenchmarkMarker, type BenchmarkTier, type BotDetectionData, type BotDetectionKey, BotDetectionMeter, type BotDetectionMeterProps, Breadcrumb, BreadcrumbEllipsis, BreadcrumbItem, BreadcrumbLink, BreadcrumbList, BreadcrumbPage, BreadcrumbSeparator, BulletinViewer, type BulletinViewerProps, Button, ButtonGroup, ButtonGroupSeparator, ButtonGroupText, type ButtonProps, type ButtonVariantProps, CHART_FONT_FAMILY, CRITERION_TIER_KEYS, Calendar, type CalendarProps, Callout, CalloutDescription, type CalloutProps, CalloutTitle, Card, CardContent, CardDescription, CardFooter, CardHeader, type CardProps, CardSkeleton, type CardSkeletonProps, CardTitle, Carousel, type CarouselApi, CarouselContent, CarouselItem, CarouselNext, CarouselPrevious, ChartContainer, ChartLoadingSkeleton, ChartSkeleton, type ChartSkeletonProps$1 as ChartSkeletonProps, ChartTooltip, Checkbox, CircularProgress, type CircularProgressProps, Collapsible, CollapsibleContent, CollapsibleTrigger, Command, CommandDialog, CommandEmpty, CommandGroup, CommandInput, CommandItem, CommandList, CommandPalette, type CommandPaletteItem, type CommandPaletteProps, type CommandPaletteRecentsConfig, CommandSeparator, CommandShortcut, CommentCard, type CommentCardProps, type CommentTag, ComparisonCard, type ComparisonCardProps, type ComparisonEntity, type ComparisonMetric, ComparisonRadar, type ComparisonRadarProps, type ComparisonWinner, type CompositionScale, ConceptCard, type ConceptCardProps, type ConceptComposition, type ConceptPoint, ConceptPulseChart, type ConceptPulseChartProps, ConfirmDialog, type ConfirmDialogProps, ContextMenu, ContextMenuCheckboxItem, ContextMenuContent, ContextMenuGroup, ContextMenuItem, ContextMenuLabel, ContextMenuPortal, ContextMenuRadioGroup, ContextMenuRadioItem, ContextMenuSeparator, ContextMenuShortcut, ContextMenuSub, ContextMenuSubContent, ContextMenuSubTrigger, ContextMenuTrigger, CopyButton, type CopyButtonProps, type CriterionInputSpec, CriterionScoreCard, type CriterionScoreCardProps, type CriterionTierKey, type CriterionTierThresholds, type CriterionTrend, DEFAULT_CRITERION_THRESHOLDS, DEFAULT_PERIODS, DEFAULT_THRESHOLDS, DataTable, type DataTableColumn, type DataTableColumnVisibility, DataTableColumnVisibilityToggle, type DataTableColumnVisibilityToggleProps, type DataTableExpansion, DataTableExportButton, type DataTableExportButtonProps, type DataTablePagination, type DataTableProps, type DataTableSelection, type DataTableSort, DatePicker, type DatePickerProps, DateRangePicker, DateRangePickerInline, type DateRangePickerProps, Dialog, DialogClose, DialogContent, DialogDescription, DialogFooter, DialogHeader, DialogOverlay, DialogPortal, DialogTitle, DialogTrigger, type Direction, DirectionalBox, type DirectionalBoxProps, Drawer, DrawerClose, DrawerContent, DrawerDescription, DrawerFooter, DrawerHeader, DrawerOverlay, DrawerPortal, DrawerTitle, DrawerTrigger, DropdownMenu, DropdownMenuCheckboxItem, DropdownMenuContent, DropdownMenuGroup, DropdownMenuItem, DropdownMenuLabel, DropdownMenuPortal, DropdownMenuRadioGroup, DropdownMenuRadioItem, DropdownMenuSeparator, DropdownMenuShortcut, DropdownMenuSub, DropdownMenuSubContent, DropdownMenuSubTrigger, DropdownMenuTrigger, EMOTION_KEYS, ENGAGEMENT_RANGES, ENTITY_HEALTH_KEYS, EmotionBadge, type EmotionBadgeProps, type EmotionData, EmotionDistribution, type EmotionDistributionProps, type EmotionKey, Empty, EmptyAction, EmptyChart, type EmptyChartProps, type EmptyChartShape, EmptyDescription, EmptyIcon, EmptyTitle, type EngagementRange, type EngagementRangeWithDisplay, EngagementRate, EngagementRateBar, type EngagementRateBarProps, EngagementRateBenchmark, type EngagementRateBenchmarkProps, type EngagementRateProps, type EngagementTier, EntityHealthCard, EntityHealthCardActions, EntityHealthCardFooter, EntityHealthCardHeader, EntityHealthCardHeaderEnd, EntityHealthCardHeaderText, EntityHealthCardMeta, EntityHealthCardMetric, type EntityHealthCardMetricProps, EntityHealthCardMetrics, type EntityHealthCardMetricsProps, EntityHealthCardNarrative, EntityHealthCardPhase, type EntityHealthCardPhaseProps, type EntityHealthCardProps, EntityHealthCardScore, type EntityHealthCardScoreProps, EntityHealthCardSeverityBadge, type EntityHealthCardSeverityBadgeProps, EntityHealthCardSubtitle, EntityHealthCardTitle, type EntityHealthCardTitleProps, EntityHealthCardTrust, type EntityHealthCardTrustProps, type EntityHealthKey, ErrorBoundary, type ErrorBoundaryProps, ErrorState, type ErrorStateProps, type ExportableColumn, FLOW_KEYS, Field, FieldContent, FieldDescription, FieldError, FieldGroup, FieldLabel, FieldLegend, FieldSeparator, FieldSet, FieldTitle, FilterBar, FilterBarActions, type FilterBarActionsProps, FilterBarActiveFilters, type FilterBarActiveFiltersProps, FilterBarClear, type FilterBarClearProps, type FilterBarProps, FilterBarRow, type FilterBarRowProps, FilterChip, FilterChipGroup, type FilterChipProps, FilterPanel, FilterPanelBody, FilterPanelClearAll, type FilterPanelClearAllProps, FilterPanelFooter, FilterPanelHeader, type FilterPanelProps, FilterPanelTitle, type FilterPanelTitleProps, FilterPanelTrigger, type FilterPanelTriggerProps, FilterSection, type FilterSectionProps, FlowBadge, type FlowBadgeProps, FlowCell, type FlowCellProps, type FlowData, FlowDistribution, type FlowDistributionProps, type FlowKey, type FollowerGroup, Form, FormControl, FormDescription, FormField, FormItem, FormLabel, FormMessage, FormRowSkeleton, type FormRowSkeletonProps, GROUP_LABELS, HashtagInput, type TagInputProps as HashtagInputProps, type HeatMapDatum, type HeatMapRow, type HotkeyCombo, HoverCard, HoverCardContent, HoverCardTrigger, type Icon, Icons, Input, InputGroup, InputGroupAddon, InputGroupButton, InputGroupInput, InputGroupText, InputGroupTextarea, InputOTP, InputOTPGroup, InputOTPSeparator, InputOTPSlot, type InputProps, InputVariants, InputWithIcon, type InputWithIconProps, JOB_STATUS_KEYS, JobCard, JobCardActions, JobCardError, JobCardHeader, JobCardHeaderActions, JobCardHeaderText, JobCardMeta, JobCardMetaItem, type JobCardMetaItemProps, JobCardProgress, type JobCardProgressProps, type JobCardProps, JobCardStat, type JobCardStatProps, JobCardStats, type JobCardStatsProps, JobCardStatusBadge, type JobCardStatusBadgeProps, JobCardSubtitle, JobCardThumbnail, type JobCardThumbnailProps, JobCardTitle, type JobCardTitleProps, type JobStatusKey, JobWizard, type JobWizardApi, JobWizardBack, type JobWizardBackProps, JobWizardBody, JobWizardCancel, type JobWizardCancelProps, JobWizardError, JobWizardFooter, JobWizardHeader, type JobWizardHeaderProps, JobWizardNext, type JobWizardNextProps, type JobWizardProps, JobWizardSkip, type JobWizardSkipProps, JobWizardSpacer, type JobWizardStep, JobWizardStepper, type JobWizardStepperProps, type JobWizardSubmitState, JobWizardSuccess, type JobWizardSuccessProps, type JobWizardValidationResult, Kbd, KbdGroup, Label, type LegacySize, type LoadingVariantProps, type Locale, Menubar, MenubarCheckboxItem, MenubarContent, MenubarGroup, MenubarItem, MenubarLabel, MenubarMenu, MenubarPortal, MenubarRadioGroup, MenubarRadioItem, MenubarSeparator, MenubarShortcut, MenubarSub, MenubarSubContent, MenubarSubTrigger, MenubarTrigger, MetricCard, MetricCardContent, MetricCardDifferential, MetricCardHeader, MetricCardLabel, MetricCardSkeleton, type MetricCardSkeletonProps, MetricCardSparkline, MetricCardValue, MultiSelect, type MultiSelectOption, type MultiSelectProps, NativeSelect, NativeSelectOptGroup, NativeSelectOption, NavGroup, type NavGroupProps, NavItem, type NavItemBaseProps, type NavItemProps, type NavMatchStrategy, NavPanel, NavPanelContent, NavPanelFooter, NavPanelHeader, NavRail, NavRailContent, NavRailFooter, NavRailHeader, NavRailItem, NavRailProvider, NavRailSeparator, NavRailTrigger, NavSeparator, NavTree, type NavTreeContextValue, NavTreeProvider, type NavTreeProviderProps, NavigationMenu, NavigationMenuContent, NavigationMenuIndicator, NavigationMenuItem, NavigationMenuLink, NavigationMenuList, NavigationMenuTrigger, NavigationMenuViewport, type NetworkLink, type NetworkNode, NotificationCenter, type NotificationCenterProps, type NotificationFilter, type NotificationItem, type NotificationSeverity, PERSIAN_MONTHS, PERSIAN_MONTHS_SHORT, PERSIAN_WEEKDAYS, PERSIAN_WEEKDAYS_SHORT, PageCard, type PageCardContentMix, type PageCardProps, PageHeader, type PageHeaderProps, PageLoader, type PageLoaderProps, Pagination, PaginationContent, PaginationControlled, type PaginationControlledProps, PaginationEllipsis, PaginationItem, PaginationLink, PaginationNext, PaginationPrevious, PartoAreaChart, type PartoAreaChartProps, PartoBarChart, type PartoBarChartProps, PartoHeatMap, type PartoHeatMapProps, PartoLineChart, type PartoLineChartProps, PartoNetworkChart, type PartoNetworkChartProps, PartoPieChart, type PartoPieChartProps, PartoRadarChart, type PartoRadarChartProps, PartoSankeyChart, type PartoSankeyChartProps, PartoScatterChart, type PartoScatterChartProps, type PartoToasterProps, PartoWordCloud, type PartoWordCloudProps, type PeriodOption, PeriodSelector, type PeriodSelectorProps, type PlatformMetadata, Popover, PopoverAnchor, PopoverContent, PopoverTrigger, type PostAction, PostActions, type PostActionsProps, type PostAiAnalysis, type PostAiEntity, type PostAuthor, PostBody, type PostBodyData, type PostBodyProps, PostCard, type PostCardProps, type PostComment, type PostCommentAuthor, type PostData, type PostDensity, type PostDetails, PostDetailsModal, type PostDetailsModalProps, type PostDetailsTab, type PostEmotion, type PostEnrichmentFlags, PostHeader, type PostHeaderProps, type PostIntent, PostList, type PostListProps, type PostMediaItem, PostMetadata, type PostMetadataProps, type PostMetrics, type PostPlatform, type PostSentiment, type PostingFrequencyCell, PostingFrequencyHeatmap, type PostingFrequencyHeatmapProps, type PostingFrequencySummary, type PostingWeekStart, ProfileCard, type ProfileCardProps, ProfileInfo, type ProfileInfoProps, Progress, ProgressCell, type ProgressCellProps, type ProgressProps, type QuotaLevel, QuotaProgressBar, type QuotaProgressBarProps, type QuotaThresholds, RadioCardDescription, RadioCardItem, RadioCardTitle, RadioCards, RadioGroup, RadioGroupItem, RateLimitBanner, type RateLimitBannerProps, ReportComposer, type ReportComposerProps, ReportSection, type ReportSectionProps, ResizableHandle, ResizablePanel, ResizablePanelGroup, RouteProgress, type RouteProgressHandle, type RouteProgressProps, SONNER_DEFAULT_DURATION, STAGE_STATUS_KEYS, SafeImage, type SafeImageProps, type SankeyLink, type SankeyNode, SavedQueryCard, type SavedQueryCardProps, type SavedQueryFilter, ScrollArea, ScrollBar, SearchInput, type SearchInputProps, type SectionItem, SectionNavigator, type SectionNavigatorProps, Select, SelectContent, SelectGroup, SelectItem, SelectLabel, SelectScrollDownButton, SelectScrollUpButton, SelectSeparator, SelectTrigger, SelectTriggerVariants, SelectValue, SentimentBadge, type SentimentBadgeProps, SentimentCell, type SentimentCellProps, type SentimentData, SentimentDistribution, type SentimentDistributionProps, Separator, SeverityBadge, type SeverityBadgeProps, type SeverityKey, Sheet, SheetBody, SheetClose, SheetContent, SheetDescription, SheetFooter, SheetHeader, SheetTitle, SheetTrigger, Sidebar, SidebarContent, SidebarFooter, SidebarGroup, SidebarGroupAction, SidebarGroupContent, SidebarGroupLabel, SidebarHeader, SidebarInput, SidebarInset, SidebarMenu, SidebarMenuAction, SidebarMenuBadge, SidebarMenuButton, SidebarMenuItem, SidebarMenuSkeleton, SidebarMenuSub, SidebarMenuSubButton, SidebarMenuSubItem, SidebarProvider, SidebarRail, SidebarSeparator, SidebarTrigger, SiteHeader, SiteHeaderActions, SiteHeaderEnd, type SiteHeaderProps, SiteHeaderSeparator, SiteHeaderStart, SiteHeaderSubtitle, SiteHeaderTitle, SiteHeaderTitleGroup, type SizeWithLegacy, Skeleton, type SkeletonProps, Slider, type SocialPlatform, SocialPlatformBadge, type SocialPlatformBadgeProps, type SortDirection, Sparkline, SparklineCell, type SparklineCellProps, type SparklineProps, type SparklineTrend, type SparklineVariant, Spinner, type SpinnerProps, type StageStatusKey, type StandardSize, StatDeltaCell, type StatDeltaCellProps, StatDisplay, type StatDisplayProps, StatusBadge, type StatusBadgeProps, StatusFlow, type StatusFlowOrientation, type StatusFlowProps, type StatusFlowSize, StatusFlowStage, type StatusFlowStageData, type StatusFlowStageProps, type StatusKey, StatusPulseCell, type StatusPulseCellProps, Step, type StepProps, Stepper, type StepperProps, type SupportedLocale, Switch, type SwitchProps, TIER_LABELS, Table, TableBody, TableCaption, TableCell, TableComparisonView, type TableComparisonViewProps, TableFooter, TableHead, TableHeader, TableRow, TableRowSkeleton, type TableRowSkeletonProps, TableSkeleton, type TableSkeletonProps, TableSortHeader, Tabs, TabsContent, TabsList, TabsTrigger, TagInput, type TagInputProps, Textarea, Toaster, Toggle, ToggleGroup, ToggleGroupItem, Tooltip, TooltipContent, TooltipProvider, TooltipTrigger, TrendCell, type TrendCellProps, TrendIndicator, type TrendIndicatorProps, type UIStringKeys, type UIStrings, UI_STRINGS, type UseAsyncReturn, type UseClipboardOptions, type UseClipboardReturn, type UseHotkeysOptions, type UseInfiniteScrollOptions, type UseInfiniteScrollReturn, type UseJobWizardOptions, UserAutocomplete, type UserAutocompleteProps, type UserItem, UserMenu, type UserMenuItem, type UserMenuProps, type UserMenuUser, type ViewMode, ViewToggle, type ViewToggleProps, type WordData, actionStatusLabels, actionTypeChipVariants, actionTypeLabels, actionTypeVerbs, appBarVariants, avatarGroupVariants, badgeVariants, bannerVariants, buildCsv, buildPostingFrequencyRows, buildTsv, buttonGroupVariants, buttonVariants, calloutVariants, cardVariants, cn, computeComparisonWinners, convertToLocalNumbers, countComparisonWins, defaultActions as defaultPostActions, downloadFile, emotionLabels, engagementUiTranslations, entityHealthLabels, entityHealthPriority, findTierIndex, flowLabels, formatAbsoluteTime, formatHotkey, formatJalaliDate, formatLargeNumber, formatNumber, formatPersianDateRange, formatRelativeLocaleTime, formatRelativeTime, formatTimeRemaining, getCriterionTier, getCurrentRangeIndex, getEngagementRanges, getEngagementRateBenchmarkTiers, getFollowerGroup, getPersianDay, getPersianMonth, getPersianMonthName, getPersianMonthNameShort, getPersianMonthsForDropdown, getPersianWeekdayName, getPersianYear, getPersianYearsForDropdown, getScoreBenchmarkTiers, getUIStrings, tagInputVariants as hashtagInputVariants, inputVariants, isActiveJobStatus, isCriticalEntityHealth, isRTL, jalaliToGregorian, jobStatusLabels, navItemVariants, navigationMenuTriggerStyle, normalizeSize, pageLoaderVariants, postCardVariants, postHeaderVariants, profileCardVariants, resolveLevel, sentimentLabels, severityLabels, siteHeaderVariants, socialPlatformBadgeVariants, spinnerVariants, stageStatusLabels, statDisplayVariants, statusLabels, tagInputVariants, toEnglishDigits, toPersianDigits, toggleVariants, transformNivoLineData, useAsync, useBreakpoint, useChartTheme, useClipboard, useDebounce, useDocumentDirection, useFormField, useHotkeys, useInfiniteScroll, useIsMobile, useJobWizard, useJobWizardState, useLocalStorage, useMediaQuery, useNavRail, useNavTree, useOutsideClick, usePrevious, useRootStyles, useScrollLock, useSidebar };
|
|
6416
|
+
interface UseFilterParamsOptions<T extends FilterStateShape> {
|
|
6417
|
+
/**
|
|
6418
|
+
* Convert a state object into a flat map of URL params. Return null/undefined
|
|
6419
|
+
* for entries you want to omit (e.g. defaults, empty arrays, null fields).
|
|
6420
|
+
*/
|
|
6421
|
+
serialize: (state: T) => Record<string, string | undefined | null>;
|
|
6422
|
+
/**
|
|
6423
|
+
* Parse the current URL params back into a partial state. Called once on
|
|
6424
|
+
* mount to hydrate the FilterProvider, and on browser navigation events.
|
|
6425
|
+
*/
|
|
6426
|
+
parse: (params: URLSearchParams) => Partial<T>;
|
|
6427
|
+
/**
|
|
6428
|
+
* Debounce window (ms) before pushing serialized state to the URL.
|
|
6429
|
+
* @default 200
|
|
6430
|
+
*/
|
|
6431
|
+
debounceMs?: number;
|
|
6432
|
+
/**
|
|
6433
|
+
* Use `history.pushState` instead of `replaceState`. Default replace
|
|
6434
|
+
* keeps the back button useful for actual page navigation rather than
|
|
6435
|
+
* filter tweaks.
|
|
6436
|
+
* @default 'replace'
|
|
6437
|
+
*/
|
|
6438
|
+
history?: 'push' | 'replace';
|
|
6439
|
+
/** Disable the hook (e.g. while a parent is loading server-side data). */
|
|
6440
|
+
disabled?: boolean;
|
|
6441
|
+
}
|
|
6442
|
+
declare function normalizeUrlDigits(input: string): string;
|
|
6443
|
+
/**
|
|
6444
|
+
* Two-way bind a `<FilterProvider>`'s state with `URLSearchParams`.
|
|
6445
|
+
*
|
|
6446
|
+
* - On mount, parses `window.location.search` and merges it onto the
|
|
6447
|
+
* provider's initial state via `patch`.
|
|
6448
|
+
* - On state change, runs `serialize` and writes the result to the URL
|
|
6449
|
+
* (debounced 200ms, replaceState by default).
|
|
6450
|
+
* - Persian/Arabic digits in incoming params are normalized to Latin.
|
|
6451
|
+
*
|
|
6452
|
+
* SSR-safe — does nothing on the server. Must be used inside a
|
|
6453
|
+
* `<FilterProvider>`. Throws otherwise to surface wiring mistakes early.
|
|
6454
|
+
*/
|
|
6455
|
+
declare function useFilterParams<T extends FilterStateShape>(options: UseFilterParamsOptions<T>): void;
|
|
6456
|
+
|
|
6457
|
+
interface FilterPreset<T extends FilterStateShape = FilterStateShape> {
|
|
6458
|
+
/** Stable, locally-unique id (slug or random). */
|
|
6459
|
+
id: string;
|
|
6460
|
+
/** User-visible name. */
|
|
6461
|
+
name: string;
|
|
6462
|
+
/** Snapshot of the filter state. */
|
|
6463
|
+
state: T;
|
|
6464
|
+
/** Unix timestamp (ms) of creation. */
|
|
6465
|
+
createdAt: number;
|
|
6466
|
+
/** Unix timestamp (ms) of the most recent rename / overwrite. */
|
|
6467
|
+
updatedAt: number;
|
|
6468
|
+
}
|
|
6469
|
+
interface UseFilterPresetsOptions {
|
|
6470
|
+
/** localStorage namespace (must be unique per app section). */
|
|
6471
|
+
storageKey: string;
|
|
6472
|
+
/** Soft cap on total presets retained. Oldest is dropped on overflow. @default 20 */
|
|
6473
|
+
maxPresets?: number;
|
|
6474
|
+
}
|
|
6475
|
+
interface UseFilterPresetsReturn<T extends FilterStateShape> {
|
|
6476
|
+
/** Sorted list (newest first by `updatedAt`). */
|
|
6477
|
+
presets: FilterPreset<T>[];
|
|
6478
|
+
/** Save the FilterProvider's current state under a name. Returns the new preset's id. */
|
|
6479
|
+
save: (name: string) => string;
|
|
6480
|
+
/** Apply a preset's state to the FilterProvider via `set`. */
|
|
6481
|
+
load: (id: string) => boolean;
|
|
6482
|
+
/** Remove a preset. */
|
|
6483
|
+
remove: (id: string) => void;
|
|
6484
|
+
/** Update a preset's name. */
|
|
6485
|
+
rename: (id: string, name: string) => boolean;
|
|
6486
|
+
/** Overwrite a preset with the current state. */
|
|
6487
|
+
overwrite: (id: string) => boolean;
|
|
6488
|
+
/** Clear ALL presets in this namespace. */
|
|
6489
|
+
clear: () => void;
|
|
6490
|
+
}
|
|
6491
|
+
/**
|
|
6492
|
+
* Save / load / rename / delete named presets of a `<FilterProvider>`'s
|
|
6493
|
+
* state in localStorage.
|
|
6494
|
+
*
|
|
6495
|
+
* Storage shape: `localStorage[storageKey] = JSON.stringify(FilterPreset[])`.
|
|
6496
|
+
* Presets are sorted newest-first by `updatedAt`. Soft-capped at `maxPresets`
|
|
6497
|
+
* (default 20) — oldest is dropped on overflow at save time.
|
|
6498
|
+
*
|
|
6499
|
+
* SSR-safe: returns an empty list on the server, hydrates on first effect.
|
|
6500
|
+
*/
|
|
6501
|
+
declare function useFilterPresets<T extends FilterStateShape>(options: UseFilterPresetsOptions): UseFilterPresetsReturn<T>;
|
|
6502
|
+
|
|
6503
|
+
export { ACTION_TYPE_META, Accordion, AccordionContent, AccordionItem, AccordionTrigger, ActionStatusKey, ActionTimeline, type ActionTimelineDensity, type ActionTimelineGroupBy, ActionTimelineItem, type ActionTimelineItemData, type ActionTimelineItemProps, type ActionTimelineProps, ActionTypeChip, type ActionTypeChipProps, ActionTypeKey, ActiveFiltersBar, type ActiveFiltersBarProps, ActiveFiltersClearAll, type ActiveFiltersClearAllProps, Alert, AlertDescription, AlertDialog, AlertDialogAction, AlertDialogCancel, AlertDialogContent, AlertDialogDescription, AlertDialogFooter, AlertDialogHeader, AlertDialogOverlay, AlertDialogPortal, AlertDialogTitle, AlertDialogTrigger, AlertTitle, AnimatedNumber, type AnimatedNumberProps, AppBar, type AppBarProps, AppLayout, AppLayoutContent, AspectRatio, type AsyncStatus, Autocomplete, type AutocompleteItem, type AutocompleteProps, AvatarGroup, type AvatarGroupItem, type AvatarGroupProps, AvatarTextSkeleton, type AvatarTextSkeletonProps, Banner, type BannerProps, type BenchmarkMarker, type BenchmarkTier, BlurBackdrop, Breadcrumb, BreadcrumbEllipsis, BreadcrumbItem, BreadcrumbLink, BreadcrumbList, BreadcrumbPage, BreadcrumbSeparator, BulletinViewer, type BulletinViewerProps, Button, ButtonGroup, ButtonGroupSeparator, ButtonGroupText, ButtonProps, CENTERED_CONTAINER_CLS, CHART_FONT_FAMILY, COUNTRIES, CRITERION_TIER_KEYS, Callout, CalloutDescription, type CalloutProps, CalloutTitle, CardSkeleton, type CardSkeletonProps, Carousel, type CarouselApi, CarouselContent, CarouselItem, CarouselNext, CarouselPrevious, ChartContainer, ChartGradientLegend, type ChartGradientLegendProps, ChartLegend, type ChartLegendItem, type ChartLegendProps, ChartLoadingSkeleton, ChartSkeleton, type ChartSkeletonProps$1 as ChartSkeletonProps, ChartTooltip, Checkbox, CircularProgress, type CircularProgressProps, Collapsible, CollapsibleContent, CollapsibleTrigger, Command, CommandDialog, CommandEmpty, CommandGroup, CommandInput, CommandItem, CommandList, CommandPalette, type CommandPaletteItem, type CommandPaletteProps, type CommandPaletteRecentsConfig, CommandSeparator, CommandShortcut, CommentCard, type CommentCardProps, type CommentTag, ComparisonCard, type ComparisonCardProps, type ComparisonEntity, type ComparisonMetric, ComparisonRadar, type ComparisonRadarProps, type ComparisonWinner, type CompositionScale, type ConceptComposition, type ConceptPoint, ConceptPulseChart, type ConceptPulseChartProps, ConfirmDialog, type ConfirmDialogProps, ContextMenu, ContextMenuCheckboxItem, ContextMenuContent, ContextMenuGroup, ContextMenuItem, ContextMenuLabel, ContextMenuPortal, ContextMenuRadioGroup, ContextMenuRadioItem, ContextMenuSeparator, ContextMenuShortcut, ContextMenuSub, ContextMenuSubContent, ContextMenuSubTrigger, ContextMenuTrigger, CopyButton, type CopyButtonProps, type Country, type CountryCode, CountryPicker, type CountryPickerProps, type CriterionInputSpec, CriterionScoreCard, type CriterionScoreCardProps, type CriterionTierKey, type CriterionTierThresholds, type CriterionTrend, DEFAULT_CRITERION_THRESHOLDS, DEFAULT_PERIODS, DEFAULT_THRESHOLDS, DataTableColumn, DataTableColumnVisibility, DataTableColumnVisibilityToggle, type DataTableColumnVisibilityToggleProps, DataTableExportButton, type DataTableExportButtonProps, DatePicker, type DatePickerProps, DateRangePicker, DateRangePickerInline, type DateRangePickerProps, Dialog, type Direction, DirectionalBox, type DirectionalBoxProps, Drawer, DrawerClose, DrawerContent, DrawerDescription, DrawerFooter, DrawerHeader, DrawerOverlay, DrawerPortal, DrawerTitle, DrawerTrigger, DropdownMenu, DropdownMenuCheckboxItem, DropdownMenuContent, DropdownMenuGroup, DropdownMenuItem, DropdownMenuLabel, DropdownMenuPortal, DropdownMenuRadioGroup, DropdownMenuRadioItem, DropdownMenuSeparator, DropdownMenuShortcut, DropdownMenuSub, DropdownMenuSubContent, DropdownMenuSubTrigger, DropdownMenuTrigger, ENGAGEMENT_RANGES, EmotionBadge, type EmotionBadgeProps, type EmotionData, EmotionDistribution, type EmotionDistributionProps, EmotionKey, Empty, EmptyAction, EmptyChart, type EmptyChartProps, type EmptyChartShape, EmptyDescription, EmptyIcon, EmptyTitle, type EngagementRange, type EngagementRangeWithDisplay, EngagementRate, EngagementRateBar, type EngagementRateBarProps, EngagementRateBenchmark, type EngagementRateBenchmarkProps, type EngagementRateProps, type EngagementTier, EntityHealthCard, EntityHealthCardActions, EntityHealthCardFooter, EntityHealthCardHeader, EntityHealthCardHeaderEnd, EntityHealthCardHeaderText, EntityHealthCardMeta, EntityHealthCardMetric, type EntityHealthCardMetricProps, EntityHealthCardMetrics, type EntityHealthCardMetricsProps, EntityHealthCardNarrative, EntityHealthCardPhase, type EntityHealthCardPhaseProps, type EntityHealthCardProps, EntityHealthCardScore, type EntityHealthCardScoreProps, EntityHealthCardSeverityBadge, type EntityHealthCardSeverityBadgeProps, EntityHealthCardSubtitle, EntityHealthCardTitle, type EntityHealthCardTitleProps, EntityHealthCardTrust, type EntityHealthCardTrustProps, EntityHealthKey, ErrorBoundary, type ErrorBoundaryProps, ErrorIllustration, ErrorState, type ErrorStateProps, type ExecutiveSummaryMetric, ExecutiveSummarySection, type ExecutiveSummarySectionProps, type ExportableColumn, type ExtendedPlatform, FOREGROUND_IMG_CLS, Field, FieldContent, FieldDescription, FieldError, FieldGroup, FieldLabel, FieldLegend, FieldSeparator, FieldSet, FieldTitle, FilterBar, FilterBarActions, type FilterBarActionsProps, FilterBarActiveFilters, type FilterBarActiveFiltersProps, FilterBarClear, type FilterBarClearProps, type FilterBarProps, FilterBarRow, type FilterBarRowProps, FilterChip, FilterChipGroup, type FilterChipProps, FilterPanel, FilterPanelBody, FilterPanelClearAll, type FilterPanelClearAllProps, FilterPanelFooter, FilterPanelHeader, type FilterPanelProps, FilterPanelTitle, type FilterPanelTitleProps, FilterPanelTrigger, type FilterPanelTriggerProps, type FilterPreset, FilterSection, type FilterSectionProps, FilterStateShape, FirstRunIllustration, FlowBadge, type FlowBadgeProps, FlowCell, type FlowCellProps, FlowData, FlowDistributionSection, type FlowDistributionSectionProps, FlowKey, type FollowerGroup, ForbiddenIllustration, Form, FormControl, FormDescription, FormField, FormItem, FormLabel, FormMessage, FormRowSkeleton, type FormRowSkeletonProps, GROUP_LABELS, HashtagInput, type TagInputProps as HashtagInputProps, type HashtagPerformanceData, HashtagPerformanceRow, type HashtagPerformanceRowProps, type HeatMapDatum, type HeatMapRow, HotkeyCombo, HoverCard, HoverCardContent, HoverCardTrigger, IRAN_PROVINCES, type Icon, Icons, Input, InputGroup, InputGroupAddon, InputGroupButton, InputGroupInput, InputGroupText, InputGroupTextarea, InputOTP, InputOTPGroup, InputOTPSeparator, InputOTPSlot, InputProps, InputVariants, InputWithIcon, type InputWithIconProps, type IranProvince, type IranProvinceSlug, JobCard, JobCardActions, JobCardError, JobCardHeader, JobCardHeaderActions, JobCardHeaderText, JobCardMeta, JobCardMetaItem, type JobCardMetaItemProps, JobCardProgress, type JobCardProgressProps, type JobCardProps, JobCardStat, type JobCardStatProps, JobCardStats, type JobCardStatsProps, JobCardStatusBadge, type JobCardStatusBadgeProps, JobCardSubtitle, JobCardThumbnail, type JobCardThumbnailProps, JobCardTitle, type JobCardTitleProps, JobStatusKey, JobWizard, type JobWizardApi, JobWizardBack, type JobWizardBackProps, JobWizardBody, JobWizardCancel, type JobWizardCancelProps, JobWizardError, JobWizardFooter, JobWizardHeader, type JobWizardHeaderProps, JobWizardNext, type JobWizardNextProps, type JobWizardProps, JobWizardSkip, type JobWizardSkipProps, JobWizardSpacer, type JobWizardStep, JobWizardStepper, type JobWizardStepperProps, type JobWizardSubmitState, JobWizardSuccess, type JobWizardSuccessProps, type JobWizardValidationResult, Kbd, KbdGroup, Label, LabelChip, type LabelChipProps, LabelEditDialog, type LabelEditDialogProps, type LegacySize, MarkdownRenderer, type MarkdownRendererProps, Menubar, MenubarCheckboxItem, MenubarContent, MenubarGroup, MenubarItem, MenubarLabel, MenubarMenu, MenubarPortal, MenubarRadioGroup, MenubarRadioItem, MenubarSeparator, MenubarShortcut, MenubarSub, MenubarSubContent, MenubarSubTrigger, MenubarTrigger, MetricCard, MetricCardContent, MetricCardDifferential, MetricCardHeader, MetricCardLabel, MetricCardSkeleton, type MetricCardSkeletonProps, MetricCardSparkline, MetricCardValue, type MultiPlatformMetrics, MultiPlatformPostCard, type MultiPlatformPostCardProps, type MultiPlatformPostData, MultiSelect, type MultiSelectOption, type MultiSelectProps, NativeSelect, NativeSelectOptGroup, NativeSelectOption, NavGroup, type NavGroupProps, NavItem, type NavItemBaseProps, type NavItemProps, type NavMatchStrategy, NavPanel, NavPanelContent, NavPanelFooter, NavPanelHeader, NavRail, NavRailContent, NavRailFooter, NavRailHeader, NavRailItem, NavRailProvider, NavRailSeparator, NavRailTrigger, NavSeparator, NavTree, type NavTreeContextValue, NavTreeProvider, type NavTreeProviderProps, NavigationMenu, NavigationMenuContent, NavigationMenuIndicator, NavigationMenuItem, NavigationMenuLink, NavigationMenuList, NavigationMenuTrigger, NavigationMenuViewport, type NetworkLink, type NetworkNode, NoDataIllustration, NoResultsIllustration, NotificationCenter, type NotificationCenterProps, type NotificationFilter, type NotificationItem, type NotificationSeverity, NumberInputLocale, type NumberInputLocaleProps, PERSIAN_MONTHS, PERSIAN_MONTHS_SHORT, PERSIAN_WEEKDAYS, PERSIAN_WEEKDAYS_SHORT, PageHeader, type PageHeaderProps, PageLoader, type PageLoaderProps, Pagination, PaginationContent, PaginationControlled, type PaginationControlledProps, PaginationEllipsis, PaginationItem, PaginationLink, PaginationNext, PaginationPrevious, PartoHeatMap, type PartoHeatMapProps, PartoNetworkChart, type PartoNetworkChartProps, PartoRadarChart, type PartoRadarChartProps, PartoSankeyChart, type PartoSankeyChartProps, PartoScatterChart, type PartoScatterChartProps, type PartoToasterProps, PartoWordCloud, type PartoWordCloudProps, type PeriodOption, PeriodSelector, type PeriodSelectorProps, type PlatformMetadata, type PostAction, PostActions, type PostActionsProps, type PostAiAnalysis, type PostAiEntity, type PostAuthor, type PostAuthorityTier, PostBody, type PostBodyData, type PostBodyProps, type PostBulkAction, PostBulkActionBar, type PostBulkActionBarProps, PostCard, type PostCardProps, type PostCluster, type PostComment, type PostCommentAuthor, PostCrisisBanner, type PostCrisisBannerProps, type PostData, type PostDensity, type PostDetails, PostDetailsDrawer, type PostDetailsDrawerProps, PostDetailsModal, type PostDetailsModalProps, type PostDetailsTab$1 as PostDetailsTab, type PostEmotion, type PostEnrichmentFlags, type PostFlags, type PostFlow, type PostGroupBy, PostHeader, PostHeaderBroadcast, type PostHeaderBroadcastProps, PostHeaderEditorial, type PostHeaderEditorialProps, type PostHeaderProps, type PostIntent, PostList, type PostListProps, PostMedia, PostMediaAudio, PostMediaCarousel, PostMediaGrid, PostMediaHighlight, type PostMediaItem, PostMediaPlaceholder, type PostMediaPlaceholderProps, type PostMediaPlaceholderVariant, type PostMediaProps, PostMediaSensitiveOverlay, type PostMediaSensitivity, PostMediaSingle, PostMediaSourceRemoved, type PostMediaSourceRemovedProps, type PostMediaStatus, PostMediaStory, PostMediaVideo, PostMetadata, type PostMetadataProps, type PostMetrics, type PostOutlet, type PostPlatform, PostQuotedEmbed, type PostQuotedEmbedProps, PostRepostHeader, type PostRepostHeaderProps, type PostRepostInfo, type PostSentiment, type PostSeverity, PostSignals, type PostSignalsProps, type PostSortBy, type PostSource, type PostSourceCategory, type PostStatus, PostThreadConnector, type PostThreadConnectorProps, type PostThreadInfo, type PostUrlPreview, type PostUrlPreview as PostUrlPreviewData, type PostUrlPreviewProps, type PostView, type PostingFrequencyCell, PostingFrequencyHeatmap, type PostingFrequencyHeatmapProps, type PostingFrequencySummary, type PostingWeekStart, ProfileCard, type ProfileCardProps, ProfileInfo, type ProfileInfoProps, Progress, ProgressCell, type ProgressCellProps, type ProgressProps, type QuotaLevel, QuotaProgressBar, type QuotaProgressBarProps, type QuotaThresholds, RadioCardDescription, RadioCardItem, RadioCardTitle, RadioCards, RadioGroup, RadioGroupItem, RateLimitBanner, type RateLimitBannerProps, type ReactionBreakdown, RegionPicker, type RegionPickerKey, type RegionPickerProps, RegisteredHotkey, ReportComposer, type ReportComposerProps, ReportSection, type ReportSectionProps, ResizableHandle, ResizablePanel, ResizablePanelGroup, RouteProgress, type RouteProgressHandle, type RouteProgressProps, SENSITIVITY_LABEL, SONNER_DEFAULT_DURATION, SafeImage, type SafeImageProps, type SankeyLink, type SankeyNode, ScrollArea, ScrollBar, SearchInput, type SearchInputProps, type SectionItem, SectionNavigator, type SectionNavigatorProps, Select, SelectContent, SelectGroup, SelectItem, SelectLabel, SelectScrollDownButton, SelectScrollUpButton, SelectSeparator, SelectTrigger, SelectTriggerVariants, SelectValue, SentimentBadge, type SentimentBadgeProps, SentimentBreakdownSection, type SentimentBreakdownSectionProps, SentimentCell, type SentimentCellProps, SentimentData, Separator, SeverityBadge, type SeverityBadgeProps, SeverityKey, ShortcutsCheatsheet, type ShortcutsCheatsheetProps, Sidebar, SidebarContent, SidebarFooter, SidebarGroup, SidebarGroupAction, SidebarGroupContent, SidebarGroupLabel, SidebarHeader, SidebarInput, SidebarInset, SidebarMenu, SidebarMenuAction, SidebarMenuBadge, SidebarMenuButton, SidebarMenuItem, SidebarMenuSkeleton, SidebarMenuSub, SidebarMenuSubButton, SidebarMenuSubItem, SidebarProvider, SidebarRail, SidebarSeparator, SidebarTrigger, SiteHeader, SiteHeaderActions, SiteHeaderEnd, type SiteHeaderProps, SiteHeaderSeparator, SiteHeaderStart, SiteHeaderSubtitle, SiteHeaderTitle, SiteHeaderTitleGroup, type SizeWithLegacy, Skeleton, type SkeletonProps, Slider, SocialPlatform, type SourceBreakdownEntry, SourceBreakdownSection, type SourceBreakdownSectionProps, SparklineCell, type SparklineCellProps, Spinner, type SpinnerProps, StageStatusKey, type StandardSize, StatDeltaCell, type StatDeltaCellProps, StatDisplay, type StatDisplayProps, StatusBadge, type StatusBadgeProps, StatusFlow, type StatusFlowOrientation, type StatusFlowProps, type StatusFlowSize, StatusFlowStage, type StatusFlowStageData, type StatusFlowStageProps, StatusKey, StatusPulseCell, type StatusPulseCellProps, Step, type StepProps, Stepper, type StepperProps, SupportedLocale, Switch, type SwitchProps, TIER_LABELS, Table, TableBody, TableCaption, TableCell, TableComparisonView, type TableComparisonViewProps, TableFooter, TableHead, TableHeader, TableRow, TableRowSkeleton, type TableRowSkeletonProps, TableSkeleton, type TableSkeletonProps, TableSortHeader, Tabs, TabsContent, TabsList, TabsTrigger, TagInput, type TagInputProps, TaskList, type TaskListGroup, type TaskListProps, Textarea, TimelineSection, type TimelineSectionProps, Toaster, Toggle, ToggleGroup, ToggleGroupItem, TooltipContent, TopPostsSection, type TopPostsSectionProps, TrendCell, type TrendCellProps, TrendIndicator, type TrendIndicatorProps, type UseAsyncReturn, type UseClipboardOptions, type UseClipboardReturn, type UseFilterParamsOptions, type UseFilterPresetsOptions, type UseFilterPresetsReturn, type UseInfiniteScrollOptions, type UseInfiniteScrollReturn, type UseJobWizardOptions, UserAutocomplete, type UserAutocompleteProps, type UserItem, UserMenu, type UserMenuItem, type UserMenuProps, type UserMenuUser, type ViewMode, ViewToggle, type ViewToggleProps, type WordData, actionTypeChipVariants, appBarVariants, avatarGroupVariants, bannerVariants, buildCsv, buildPostingFrequencyRows, buildTsv, buttonGroupVariants, calloutVariants, computeComparisonWinners, countComparisonWins, countryFlag, defaultActions as defaultPostActions, downloadFile, findCountry, findProvince, findTierIndex, formatJalaliDate, formatPersianDateRange, getCountryLabel, getCriterionTier, getCurrentRangeIndex, getEngagementRanges, getEngagementRateBenchmarkTiers, getFollowerGroup, getMetricLabel, getPersianDay, getPersianMonth, getPersianMonthName, getPersianMonthNameShort, getPersianMonthsForDropdown, getPersianWeekdayName, getPersianYear, getPersianYearsForDropdown, getPostSourceConfig, getProvinceLabel, getScoreBenchmarkTiers, getSourceColorVar, tagInputVariants as hashtagInputVariants, jalaliToGregorian, labelChipVariants, localeAwareCategoryTick, localeAwareNumberTick, navItemVariants, navigationMenuTriggerStyle, normalizeSize, normalizeUrlDigits, pageLoaderVariants, postCardVariants, postHeaderVariants, profileCardVariants, resolveLevel, siteHeaderVariants, sourceCategory, spinnerVariants, statDisplayVariants, tagInputVariants, toEnglishDigits, toPersianDigits, toggleVariants, transformNivoLineData, useAsync, useBreakpoint, useChartTheme, useClipboard, useDebounce, useDocumentDirection, useFilterParams, useFilterPresets, useFormField, useInfiniteScroll, useIsMobile, useJobWizard, useJobWizardState, useLocalStorage, useMediaQuery, useNavRail, useNavTree, useOutsideClick, usePrevious, useRootStyles, useScrollLock, useSidebar };
|