@redsift/products 12.5.7 → 12.5.8-muiv7

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/bimi-checker.d.ts CHANGED
@@ -1,67 +1,8 @@
1
1
  import * as _redsift_design_system from '@redsift/design-system';
2
- import React, { ReactNode, ComponentProps } from 'react';
2
+ import React, { ComponentProps, ReactNode } from 'react';
3
3
  import { CardStatus } from '@redsift/signal-logic';
4
4
  export { BIMI_CHECKER_SIGNAL_TYPES, BimiCheckerSignalType, CARD_STATUS, SIGNAL_TYPES, STATUS_COLORS, STATUS_ICONS, STATUS_ICON_STYLES, SignalType, getStatusColor, getStatusIcon, getStatusIconStyle, isCardStatus, isFailureStatus, isSuccessStatus, isWarningStatus, mapStatusToDetailedCardColor, normalizeStatus } from '@redsift/signal-logic';
5
5
 
6
- /**
7
- * Signal Cards Theme Configuration
8
- *
9
- * This context provides theme configuration to signal card components,
10
- * eliminating the need to pass `useInvestigateColors` through every component layer.
11
- */
12
- interface SignalCardTheme {
13
- /**
14
- * Whether to use Investigate-specific colors and fonts.
15
- * When true, applies custom fonts and color palette for the Investigate tool.
16
- */
17
- useInvestigateColors: boolean;
18
- }
19
- interface SignalCardThemeProviderProps {
20
- children: ReactNode;
21
- /**
22
- * Theme configuration to apply to all signal card descendants
23
- */
24
- theme?: Partial<SignalCardTheme>;
25
- }
26
- /**
27
- * Provider component for Signal Card theming.
28
- *
29
- * Wrap signal card components with this provider to set theme options
30
- * without passing props through every component level.
31
- *
32
- * This provider injects CSS custom properties (--sc-*) that components use for styling.
33
- *
34
- * @example
35
- * ```tsx
36
- * <SignalCardThemeProvider theme={{ useInvestigateColors: true }}>
37
- * <SignalCardList signals={signals} />
38
- * </SignalCardThemeProvider>
39
- * ```
40
- */
41
- declare const SignalCardThemeProvider: React.FC<SignalCardThemeProviderProps>;
42
- /**
43
- * Hook to access the current signal card theme.
44
- *
45
- * Components can use this hook to access theme configuration
46
- * without requiring explicit props.
47
- *
48
- * @example
49
- * ```tsx
50
- * const { useInvestigateColors } = useSignalCardTheme();
51
- * ```
52
- */
53
- declare const useSignalCardTheme: () => SignalCardTheme;
54
- /**
55
- * Hook that combines prop value with context value.
56
- * Prop value takes precedence over context when explicitly provided.
57
- *
58
- * Components can receive useInvestigateColors via props or context.
59
- *
60
- * @param propValue - Explicitly passed prop value (takes precedence)
61
- * @returns Resolved theme configuration
62
- */
63
- declare const useResolvedTheme: (propValue?: boolean) => SignalCardTheme;
64
-
65
6
  /**
66
7
  * Common props shared by all signal card components. These cover layout options
67
8
  * that ultimately map to `SignalCardNormal`.
@@ -94,22 +35,34 @@ interface SignalCardSharedProps extends Omit<ComponentProps<'div'>, 'children' |
94
35
  }
95
36
 
96
37
  /**
97
- * Component props.
38
+ * SPF report item from the BIMI Checker API
98
39
  */
99
- interface SignalCardBimiProps extends SignalCardSharedProps {
100
- /**
101
- * JMAP data containing BIMI and DMARC information from the email security report.
102
- */
103
- jmap: {
104
- extsecrep: {
105
- bimi?: any;
106
- dmarc?: any;
107
- };
108
- };
40
+ interface SpfReportItem {
41
+ status?: string;
42
+ message?: string;
43
+ spfError?: string;
44
+ }
45
+ interface SpfDetails {
46
+ raw?: string | string[] | null;
47
+ status?: string | null;
48
+ txtExtractedFrom?: string | null;
49
+ report?: SpfReportItem[];
50
+ [key: string]: unknown;
51
+ }
52
+ /**
53
+ * Props for the SignalCardSpfDomain component.
54
+ *
55
+ * Simplified SPF Domain Card for BIMI Checker - shows only pass/fail status and raw SPF record.
56
+ */
57
+ interface SignalCardSpfDomainProps extends SignalCardSharedProps {
109
58
  /**
110
- * Optional callback invoked when the component mounts.
59
+ * JMAP data containing SPF authentication results
111
60
  */
112
- onComponentMount?: () => void;
61
+ jmap?: {
62
+ extsecrep?: {
63
+ spf?: SpfDetails | null;
64
+ } | null;
65
+ } | null;
113
66
  }
114
67
 
115
68
  type DmarcResult = {
@@ -138,35 +91,82 @@ interface SignalCardDmarcDomainProps extends SignalCardSharedProps {
138
91
  }
139
92
 
140
93
  /**
141
- * SPF report item from the BIMI Checker API
94
+ * Component props.
142
95
  */
143
- interface SpfReportItem {
144
- status?: string;
145
- message?: string;
146
- spfError?: string;
147
- }
148
- interface SpfDetails {
149
- raw?: string | string[] | null;
150
- status?: string | null;
151
- txtExtractedFrom?: string | null;
152
- report?: SpfReportItem[];
153
- [key: string]: unknown;
96
+ interface SignalCardBimiProps extends SignalCardSharedProps {
97
+ /**
98
+ * JMAP data containing BIMI and DMARC information from the email security report.
99
+ */
100
+ jmap: {
101
+ extsecrep: {
102
+ bimi?: any;
103
+ dmarc?: any;
104
+ };
105
+ };
106
+ /**
107
+ * Optional callback invoked when the component mounts.
108
+ */
109
+ onComponentMount?: () => void;
154
110
  }
111
+
155
112
  /**
156
- * Props for the SignalCardSpfDomain component.
113
+ * Signal Cards Theme Configuration
157
114
  *
158
- * Simplified SPF Domain Card for BIMI Checker - shows only pass/fail status and raw SPF record.
115
+ * This context provides theme configuration to signal card components,
116
+ * eliminating the need to pass `useInvestigateColors` through every component layer.
159
117
  */
160
- interface SignalCardSpfDomainProps extends SignalCardSharedProps {
118
+ interface SignalCardTheme {
161
119
  /**
162
- * JMAP data containing SPF authentication results
120
+ * Whether to use Investigate-specific colors and fonts.
121
+ * When true, applies custom fonts and color palette for the Investigate tool.
163
122
  */
164
- jmap?: {
165
- extsecrep?: {
166
- spf?: SpfDetails | null;
167
- } | null;
168
- } | null;
123
+ useInvestigateColors: boolean;
124
+ }
125
+ interface SignalCardThemeProviderProps {
126
+ children: ReactNode;
127
+ /**
128
+ * Theme configuration to apply to all signal card descendants
129
+ */
130
+ theme?: Partial<SignalCardTheme>;
169
131
  }
132
+ /**
133
+ * Provider component for Signal Card theming.
134
+ *
135
+ * Wrap signal card components with this provider to set theme options
136
+ * without passing props through every component level.
137
+ *
138
+ * This provider injects CSS custom properties (--sc-*) that components use for styling.
139
+ *
140
+ * @example
141
+ * ```tsx
142
+ * <SignalCardThemeProvider theme={{ useInvestigateColors: true }}>
143
+ * <SignalCardList signals={signals} />
144
+ * </SignalCardThemeProvider>
145
+ * ```
146
+ */
147
+ declare const SignalCardThemeProvider: React.FC<SignalCardThemeProviderProps>;
148
+ /**
149
+ * Hook to access the current signal card theme.
150
+ *
151
+ * Components can use this hook to access theme configuration
152
+ * without requiring explicit props.
153
+ *
154
+ * @example
155
+ * ```tsx
156
+ * const { useInvestigateColors } = useSignalCardTheme();
157
+ * ```
158
+ */
159
+ declare const useSignalCardTheme: () => SignalCardTheme;
160
+ /**
161
+ * Hook that combines prop value with context value.
162
+ * Prop value takes precedence over context when explicitly provided.
163
+ *
164
+ * Components can receive useInvestigateColors via props or context.
165
+ *
166
+ * @param propValue - Explicitly passed prop value (takes precedence)
167
+ * @returns Resolved theme configuration
168
+ */
169
+ declare const useResolvedTheme: (propValue?: boolean) => SignalCardTheme;
170
170
 
171
171
  /**
172
172
  * BIMI signal card - displays Brand Indicators for Message Identification status.