@atlaskit/profilecard 19.13.0 → 19.14.1

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (95) hide show
  1. package/CHANGELOG.md +1134 -1121
  2. package/afm-cc/tsconfig.json +3 -0
  3. package/dist/cjs/client/ProfileCardClient.js +7 -0
  4. package/dist/cjs/client/getTeamFromAGG.js +1 -1
  5. package/dist/cjs/components/Team/TeamProfileCardTrigger.js +9 -3
  6. package/dist/cjs/components/User/ProfileCardDetails.js +1 -1
  7. package/dist/cjs/components/User/ProfileCardTrigger.js +6 -2
  8. package/dist/cjs/styled/Card.js +69 -24
  9. package/dist/cjs/styled/Error.js +13 -0
  10. package/dist/cjs/styled/ReportingLines.js +12 -0
  11. package/dist/cjs/styled/TeamCard.js +34 -2
  12. package/dist/cjs/util/analytics.js +1 -1
  13. package/dist/es2019/client/ProfileCardClient.js +7 -0
  14. package/dist/es2019/client/getTeamFromAGG.js +1 -1
  15. package/dist/es2019/components/Team/TeamProfileCardTrigger.js +9 -3
  16. package/dist/es2019/components/User/ProfileCardDetails.js +1 -1
  17. package/dist/es2019/components/User/ProfileCardTrigger.js +6 -2
  18. package/dist/es2019/styled/Card.js +229 -186
  19. package/dist/es2019/styled/Error.js +14 -0
  20. package/dist/es2019/styled/ReportingLines.js +13 -0
  21. package/dist/es2019/styled/TeamCard.js +41 -8
  22. package/dist/es2019/util/analytics.js +1 -1
  23. package/dist/esm/client/ProfileCardClient.js +7 -0
  24. package/dist/esm/client/getTeamFromAGG.js +1 -1
  25. package/dist/esm/components/Team/TeamProfileCardTrigger.js +9 -3
  26. package/dist/esm/components/User/ProfileCardDetails.js +1 -1
  27. package/dist/esm/components/User/ProfileCardTrigger.js +6 -2
  28. package/dist/esm/styled/Card.js +69 -24
  29. package/dist/esm/styled/Error.js +14 -0
  30. package/dist/esm/styled/ReportingLines.js +13 -0
  31. package/dist/esm/styled/TeamCard.js +35 -2
  32. package/dist/esm/util/analytics.js +1 -1
  33. package/dist/types/client/ProfileCardClient.d.ts +2 -2
  34. package/dist/types/client/TeamCentralCardClient.d.ts +1 -1
  35. package/dist/types/client/TeamProfileCardClient.d.ts +1 -1
  36. package/dist/types/client/UserProfileCardClient.d.ts +2 -2
  37. package/dist/types/client/errorUtils.d.ts +1 -1
  38. package/dist/types/components/Error/ErrorMessage.d.ts +2 -2
  39. package/dist/types/components/Team/TeamForbiddenErrorState.d.ts +1 -1
  40. package/dist/types/components/Team/TeamLoadingState.d.ts +1 -1
  41. package/dist/types/components/Team/TeamProfileCardTrigger.d.ts +2 -2
  42. package/dist/types/components/User/OverflowProfileCardButtons.d.ts +1 -1
  43. package/dist/types/components/User/ProfileCard.d.ts +1 -1
  44. package/dist/types/components/User/ProfileCardDetails.d.ts +1 -1
  45. package/dist/types/components/User/ProfileCardResourced.d.ts +2 -2
  46. package/dist/types/components/User/ProfileCardTrigger.d.ts +1 -1
  47. package/dist/types/components/User/ProfileCardTriggerNext.d.ts +1 -1
  48. package/dist/types/components/User/ReportingLinesDetails.d.ts +1 -1
  49. package/dist/types/components/User/UserLoadingState.d.ts +1 -1
  50. package/dist/types/index.d.ts +1 -1
  51. package/dist/types/internal/filterActions.d.ts +1 -1
  52. package/dist/types/internal/getLabelMessage.d.ts +1 -1
  53. package/dist/types/internal/relative-date.d.ts +1 -1
  54. package/dist/types/mocks/mock-team-client.d.ts +1 -1
  55. package/dist/types/mocks/reporting-lines-data.d.ts +1 -1
  56. package/dist/types/mocks/simple-mock-clients.d.ts +1 -1
  57. package/dist/types/mocks/team-data.d.ts +1 -1
  58. package/dist/types/types.d.ts +95 -89
  59. package/dist/types/util/analytics.d.ts +2 -2
  60. package/dist/types/util/click.d.ts +1 -1
  61. package/dist/types/util/withOuterListeners.d.ts +1 -1
  62. package/dist/types-ts4.5/client/ProfileCardClient.d.ts +2 -2
  63. package/dist/types-ts4.5/client/TeamCentralCardClient.d.ts +1 -1
  64. package/dist/types-ts4.5/client/TeamProfileCardClient.d.ts +1 -1
  65. package/dist/types-ts4.5/client/UserProfileCardClient.d.ts +2 -2
  66. package/dist/types-ts4.5/client/errorUtils.d.ts +1 -1
  67. package/dist/types-ts4.5/components/Error/ErrorMessage.d.ts +2 -2
  68. package/dist/types-ts4.5/components/Team/TeamForbiddenErrorState.d.ts +1 -1
  69. package/dist/types-ts4.5/components/Team/TeamLoadingState.d.ts +1 -1
  70. package/dist/types-ts4.5/components/Team/TeamProfileCardTrigger.d.ts +2 -2
  71. package/dist/types-ts4.5/components/User/OverflowProfileCardButtons.d.ts +1 -1
  72. package/dist/types-ts4.5/components/User/ProfileCard.d.ts +1 -1
  73. package/dist/types-ts4.5/components/User/ProfileCardDetails.d.ts +1 -1
  74. package/dist/types-ts4.5/components/User/ProfileCardResourced.d.ts +2 -2
  75. package/dist/types-ts4.5/components/User/ProfileCardTrigger.d.ts +1 -1
  76. package/dist/types-ts4.5/components/User/ProfileCardTriggerNext.d.ts +1 -1
  77. package/dist/types-ts4.5/components/User/ReportingLinesDetails.d.ts +1 -1
  78. package/dist/types-ts4.5/components/User/UserLoadingState.d.ts +1 -1
  79. package/dist/types-ts4.5/index.d.ts +1 -1
  80. package/dist/types-ts4.5/internal/filterActions.d.ts +1 -1
  81. package/dist/types-ts4.5/internal/getLabelMessage.d.ts +1 -1
  82. package/dist/types-ts4.5/internal/relative-date.d.ts +1 -1
  83. package/dist/types-ts4.5/mocks/mock-team-client.d.ts +1 -1
  84. package/dist/types-ts4.5/mocks/reporting-lines-data.d.ts +1 -1
  85. package/dist/types-ts4.5/mocks/simple-mock-clients.d.ts +1 -1
  86. package/dist/types-ts4.5/mocks/team-data.d.ts +1 -1
  87. package/dist/types-ts4.5/types.d.ts +95 -89
  88. package/dist/types-ts4.5/util/analytics.d.ts +2 -2
  89. package/dist/types-ts4.5/util/click.d.ts +1 -1
  90. package/dist/types-ts4.5/util/withOuterListeners.d.ts +1 -1
  91. package/docs/0-intro.tsx +13 -18
  92. package/docs/1-profilecard-trigger.tsx +13 -19
  93. package/docs/2-team-profilecard.tsx +26 -32
  94. package/package.json +14 -12
  95. package/report.api.md +457 -496
package/report.api.md CHANGED
@@ -2,7 +2,8 @@
2
2
 
3
3
  ## API Report File for "@atlaskit/profilecard"
4
4
 
5
- > Do not edit this file. This report is auto-generated using [API Extractor](https://api-extractor.com/).
5
+ > Do not edit this file. This report is auto-generated using
6
+ > [API Extractor](https://api-extractor.com/).
6
7
  > [Learn more about API reports](https://hello.atlassian.net/wiki/spaces/UR/pages/1825484529/Package+API+Reports)
7
8
 
8
9
  ### Table of contents
@@ -33,93 +34,84 @@ type AnalyticsFunction = (generator: AnalyticsFromDuration) => void;
33
34
 
34
35
  // @public (undocumented)
35
36
  interface AnalyticsProps {
36
- // (undocumented)
37
- createAnalyticsEvent?: CreateUIAnalyticsEvent;
37
+ // (undocumented)
38
+ createAnalyticsEvent?: CreateUIAnalyticsEvent;
38
39
  }
39
40
 
40
41
  // @public (undocumented)
41
42
  export interface ApiClientResponse {
42
- // (undocumented)
43
- User: {
44
- id: string;
45
- isBot: boolean;
46
- isCurrentUser: boolean;
47
- avatarUrl: null | string;
48
- email: null | string;
49
- fullName: null | string;
50
- location: null | string;
51
- meta: null | string;
52
- nickname: null | string;
53
- companyName: null | string;
54
- remoteTimeString: null | string;
55
- remoteWeekdayIndex: null | string;
56
- remoteWeekdayString: null | string;
57
- status: StatusType;
58
- statusModifiedDate: null | number;
59
- };
43
+ // (undocumented)
44
+ User: {
45
+ id: string;
46
+ isBot: boolean;
47
+ isCurrentUser: boolean;
48
+ avatarUrl: null | string;
49
+ email: null | string;
50
+ fullName: null | string;
51
+ location: null | string;
52
+ meta: null | string;
53
+ nickname: null | string;
54
+ companyName: null | string;
55
+ remoteTimeString: null | string;
56
+ remoteWeekdayIndex: null | string;
57
+ remoteWeekdayString: null | string;
58
+ status: StatusType;
59
+ statusModifiedDate: null | number;
60
+ };
60
61
  }
61
62
 
62
63
  // @public (undocumented)
63
64
  interface CacheConfig {
64
- // (undocumented)
65
- cacheMaxAge?: number;
66
- // (undocumented)
67
- cacheSize?: number;
65
+ // (undocumented)
66
+ cacheMaxAge?: number;
67
+ // (undocumented)
68
+ cacheSize?: number;
68
69
  }
69
70
 
70
71
  // @public (undocumented)
71
72
  interface CachedData<T> {
72
- // (undocumented)
73
- expire: number;
74
- // (undocumented)
75
- profile: T;
73
+ // (undocumented)
74
+ expire: number;
75
+ // (undocumented)
76
+ profile: T;
76
77
  }
77
78
 
78
79
  // @public (undocumented)
79
80
  class CachingClient<T> {
80
- constructor(config: CacheConfig);
81
- // (undocumented)
82
- cache: LRUMap<string, CachedData<T>> | null;
83
- // (undocumented)
84
- config: Required<CacheConfig>;
85
- // (undocumented)
86
- flushCache(): void;
87
- // (undocumented)
88
- getCachedProfile(cacheIdentifier: string): T | null;
89
- // (undocumented)
90
- setCachedProfile(cacheIdentifier: string, profile: T): void;
81
+ constructor(config: CacheConfig);
82
+ // (undocumented)
83
+ cache: LRUMap<string, CachedData<T>> | null;
84
+ // (undocumented)
85
+ config: Required<CacheConfig>;
86
+ // (undocumented)
87
+ flushCache(): void;
88
+ // (undocumented)
89
+ getCachedProfile(cacheIdentifier: string): T | null;
90
+ // (undocumented)
91
+ setCachedProfile(cacheIdentifier: string, profile: T): void;
91
92
  }
92
93
 
93
94
  // @public (undocumented)
94
95
  interface ClientOverrides {
95
- // (undocumented)
96
- teamCentralClient?: TeamCentralCardClient;
97
- // (undocumented)
98
- teamClient?: TeamProfileClient;
99
- // (undocumented)
100
- userClient?: UserProfileClient;
96
+ // (undocumented)
97
+ teamCentralClient?: TeamCentralCardClient;
98
+ // (undocumented)
99
+ teamClient?: TeamProfileClient;
100
+ // (undocumented)
101
+ userClient?: UserProfileClient;
101
102
  }
102
103
 
103
104
  // @public (undocumented)
104
105
  const _default: React_2.ForwardRefExoticComponent<
105
- Pick<
106
- Omit<
107
- ProfileCardResourcedProps & AnalyticsProps,
108
- keyof WithAnalyticsEventsProps
109
- >,
110
- never
111
- > &
112
- Partial<
113
- Pick<
114
- Omit<
115
- ProfileCardResourcedProps & AnalyticsProps,
116
- keyof WithAnalyticsEventsProps
117
- >,
118
- keyof ProfileCardResourcedProps
119
- >
120
- > &
121
- Partial<Pick<Partial<ProfileCardResourcedProps>, never>> &
122
- React_2.RefAttributes<any>
106
+ Pick<Omit<ProfileCardResourcedProps & AnalyticsProps, keyof WithAnalyticsEventsProps>, never> &
107
+ Partial<
108
+ Pick<
109
+ Omit<ProfileCardResourcedProps & AnalyticsProps, keyof WithAnalyticsEventsProps>,
110
+ keyof ProfileCardResourcedProps
111
+ >
112
+ > &
113
+ Partial<Pick<Partial<ProfileCardResourcedProps>, never>> &
114
+ React_2.RefAttributes<any>
123
115
  >;
124
116
  export default _default;
125
117
 
@@ -131,546 +123,515 @@ export const DELAY_MS_SHOW = 800;
131
123
 
132
124
  // @public (undocumented)
133
125
  type FeatureFlagExtraContext = {
134
- key: string;
135
- value: string;
126
+ key: string;
127
+ value: string;
136
128
  };
137
129
 
138
130
  // @public (undocumented)
139
- type LozengeColor =
140
- | 'default'
141
- | 'inprogress'
142
- | 'moved'
143
- | 'new'
144
- | 'removed'
145
- | 'success';
131
+ type LozengeColor = 'default' | 'inprogress' | 'moved' | 'new' | 'removed' | 'success';
146
132
 
147
133
  // @public (undocumented)
148
134
  interface LozengeProps {
149
- // (undocumented)
150
- appearance?: LozengeColor;
151
- // (undocumented)
152
- isBold?: boolean;
153
- // (undocumented)
154
- text: React_2.ReactNode;
135
+ // (undocumented)
136
+ appearance?: LozengeColor;
137
+ // (undocumented)
138
+ isBold?: boolean;
139
+ // (undocumented)
140
+ text: React_2.ReactNode;
155
141
  }
156
142
 
157
143
  // @public (undocumented)
158
144
  export interface MessageIntlProviderProps {
159
- // (undocumented)
160
- children: React_2.ReactNode;
161
- // (undocumented)
162
- intl: IntlShape;
145
+ // (undocumented)
146
+ children: React_2.ReactNode;
147
+ // (undocumented)
148
+ intl: IntlShape;
163
149
  }
164
150
 
165
151
  // @public
166
- export const modifyResponse: (
167
- response: ApiClientResponse,
168
- ) => ProfileCardClientData;
152
+ export const modifyResponse: (response: ApiClientResponse) => ProfileCardClientData;
169
153
 
170
154
  // @public (undocumented)
171
155
  export const ProfileCard: React_2.ForwardRefExoticComponent<
172
- Omit<ProfilecardProps & AnalyticsProps, keyof WithAnalyticsEventsProps> &
173
- React_2.RefAttributes<any>
156
+ Omit<ProfilecardProps & AnalyticsProps, keyof WithAnalyticsEventsProps> &
157
+ React_2.RefAttributes<any>
174
158
  >;
175
159
 
176
160
  // @public (undocumented)
177
161
  export interface ProfileCardAction {
178
- // (undocumented)
179
- callback?: (...args: any[]) => any;
180
- // (undocumented)
181
- id?: string;
182
- // (undocumented)
183
- label: React_2.ReactNode;
184
- // (undocumented)
185
- link?: string;
186
- // (undocumented)
187
- shouldRender?: (data: any) => boolean;
162
+ // (undocumented)
163
+ callback?: (...args: any[]) => any;
164
+ // (undocumented)
165
+ id?: string;
166
+ // (undocumented)
167
+ label: React_2.ReactNode;
168
+ // (undocumented)
169
+ link?: string;
170
+ // (undocumented)
171
+ shouldRender?: (data: any) => boolean;
188
172
  }
189
173
 
190
174
  // @public (undocumented)
191
175
  export interface ProfileCardClientData {
192
- // (undocumented)
193
- avatarUrl?: string;
194
- // (undocumented)
195
- companyName?: string;
196
- // (undocumented)
197
- customLozenges?: LozengeProps[];
198
- // (undocumented)
199
- email?: string;
200
- // (undocumented)
201
- fullName?: string;
202
- // (undocumented)
203
- isBot: boolean;
204
- // (undocumented)
205
- isCurrentUser: boolean;
206
- // (undocumented)
207
- location?: string;
208
- // (undocumented)
209
- meta?: string;
210
- // (undocumented)
211
- nickname?: string;
212
- // (undocumented)
213
- status: StatusType;
214
- // (undocumented)
215
- statusModifiedDate?: null | number;
216
- // (undocumented)
217
- timestring?: string;
176
+ // (undocumented)
177
+ avatarUrl?: string;
178
+ // (undocumented)
179
+ companyName?: string;
180
+ // (undocumented)
181
+ customLozenges?: LozengeProps[];
182
+ // (undocumented)
183
+ email?: string;
184
+ // (undocumented)
185
+ fullName?: string;
186
+ // (undocumented)
187
+ isBot: boolean;
188
+ // (undocumented)
189
+ isCurrentUser: boolean;
190
+ // (undocumented)
191
+ location?: string;
192
+ // (undocumented)
193
+ meta?: string;
194
+ // (undocumented)
195
+ nickname?: string;
196
+ // (undocumented)
197
+ status: StatusType;
198
+ // (undocumented)
199
+ statusModifiedDate?: null | number;
200
+ // (undocumented)
201
+ timestring?: string;
218
202
  }
219
203
 
220
204
  // @public (undocumented)
221
205
  export type ProfileCardErrorType = null | {
222
- reason: 'NotFound' | 'default';
206
+ reason: 'NotFound' | 'default';
223
207
  };
224
208
 
225
209
  // @public (undocumented)
226
210
  export interface ProfilecardProps {
227
- // (undocumented)
228
- actions?: ProfileCardAction[];
229
- // (undocumented)
230
- addFlag?: (flag: any) => void;
231
- // (undocumented)
232
- avatarUrl?: string;
233
- // (undocumented)
234
- clientFetchProfile?: () => void;
235
- // (undocumented)
236
- cloudId?: string;
237
- // (undocumented)
238
- companyName?: string;
239
- // (undocumented)
240
- customLozenges?: LozengeProps[];
241
- // (undocumented)
242
- disabledAccountMessage?: React_2.ReactNode;
243
- // (undocumented)
244
- email?: string;
245
- // (undocumented)
246
- errorType?: ProfileCardErrorType;
247
- // (undocumented)
248
- fullName?: string;
249
- // (undocumented)
250
- hasDisabledAccountLozenge?: boolean;
251
- // (undocumented)
252
- hasError?: boolean;
253
- // (undocumented)
254
- isBot?: boolean;
255
- // (undocumented)
256
- isCurrentUser?: boolean;
257
- // (undocumented)
258
- isKudosEnabled?: boolean;
259
- // (undocumented)
260
- isLoading?: boolean;
261
- // (undocumented)
262
- location?: string;
263
- // (undocumented)
264
- meta?: string;
265
- // (undocumented)
266
- nickname?: string;
267
- onReportingLinesClick?: (user: ReportingLinesUser) => void;
268
- // (undocumented)
269
- openKudosDrawer?: () => void;
270
- reportingLines?: TeamCentralReportingLinesData;
271
- reportingLinesProfileUrl?: string;
272
- // (undocumented)
273
- status?: StatusType;
274
- // (undocumented)
275
- statusModifiedDate?: null | number;
276
- // (undocumented)
277
- teamCentralBaseUrl?: string;
278
- // (undocumented)
279
- timestring?: string;
280
- // (undocumented)
281
- userId?: string;
282
- // (undocumented)
283
- withoutElevation?: boolean;
211
+ // (undocumented)
212
+ actions?: ProfileCardAction[];
213
+ // (undocumented)
214
+ addFlag?: (flag: any) => void;
215
+ // (undocumented)
216
+ avatarUrl?: string;
217
+ // (undocumented)
218
+ clientFetchProfile?: () => void;
219
+ // (undocumented)
220
+ cloudId?: string;
221
+ // (undocumented)
222
+ companyName?: string;
223
+ // (undocumented)
224
+ customLozenges?: LozengeProps[];
225
+ // (undocumented)
226
+ disabledAccountMessage?: React_2.ReactNode;
227
+ // (undocumented)
228
+ email?: string;
229
+ // (undocumented)
230
+ errorType?: ProfileCardErrorType;
231
+ // (undocumented)
232
+ fullName?: string;
233
+ // (undocumented)
234
+ hasDisabledAccountLozenge?: boolean;
235
+ // (undocumented)
236
+ hasError?: boolean;
237
+ // (undocumented)
238
+ isBot?: boolean;
239
+ // (undocumented)
240
+ isCurrentUser?: boolean;
241
+ // (undocumented)
242
+ isKudosEnabled?: boolean;
243
+ // (undocumented)
244
+ isLoading?: boolean;
245
+ // (undocumented)
246
+ location?: string;
247
+ // (undocumented)
248
+ meta?: string;
249
+ // (undocumented)
250
+ nickname?: string;
251
+ onReportingLinesClick?: (user: ReportingLinesUser) => void;
252
+ // (undocumented)
253
+ openKudosDrawer?: () => void;
254
+ reportingLines?: TeamCentralReportingLinesData;
255
+ reportingLinesProfileUrl?: string;
256
+ // (undocumented)
257
+ status?: StatusType;
258
+ // (undocumented)
259
+ statusModifiedDate?: null | number;
260
+ // (undocumented)
261
+ teamCentralBaseUrl?: string;
262
+ // (undocumented)
263
+ timestring?: string;
264
+ // (undocumented)
265
+ userId?: string;
266
+ // (undocumented)
267
+ withoutElevation?: boolean;
284
268
  }
285
269
 
286
270
  // @public (undocumented)
287
271
  export interface ProfileCardResourcedProps {
288
- // (undocumented)
289
- actions?: ProfileCardAction[];
290
- // (undocumented)
291
- addFlag?: (flag: any) => void;
292
- // (undocumented)
293
- children?: React_2.ReactNode;
294
- // (undocumented)
295
- cloudId: string;
296
- // (undocumented)
297
- onReportingLinesClick?: (user: ReportingLinesUser) => void;
298
- // (undocumented)
299
- position?: ProfilecardTriggerPosition;
300
- // (undocumented)
301
- reportingLinesProfileUrl?: string;
302
- // (undocumented)
303
- resourceClient: ProfileClient_2;
304
- // (undocumented)
305
- trigger?: TriggerType;
306
- // (undocumented)
307
- userId: string;
272
+ // (undocumented)
273
+ actions?: ProfileCardAction[];
274
+ // (undocumented)
275
+ addFlag?: (flag: any) => void;
276
+ // (undocumented)
277
+ children?: React_2.ReactNode;
278
+ // (undocumented)
279
+ cloudId: string;
280
+ // (undocumented)
281
+ onReportingLinesClick?: (user: ReportingLinesUser) => void;
282
+ // (undocumented)
283
+ position?: ProfilecardTriggerPosition;
284
+ // (undocumented)
285
+ reportingLinesProfileUrl?: string;
286
+ // (undocumented)
287
+ resourceClient: ProfileClient_2;
288
+ // (undocumented)
289
+ trigger?: TriggerType;
290
+ // (undocumented)
291
+ userId: string;
308
292
  }
309
293
 
310
294
  // @public (undocumented)
311
295
  export interface ProfileCardResourcedState {
312
- // (undocumented)
313
- data: ProfileCardClientData | null;
314
- // (undocumented)
315
- error?: ProfileCardErrorType;
316
- // (undocumented)
317
- hasError: boolean;
318
- // (undocumented)
319
- isKudosEnabled?: boolean;
320
- // (undocumented)
321
- isLoading?: boolean;
322
- // (undocumented)
323
- kudosDrawerOpen: boolean;
324
- // (undocumented)
325
- reportingLinesData?: TeamCentralReportingLinesData;
326
- // (undocumented)
327
- visible?: boolean;
296
+ // (undocumented)
297
+ data: ProfileCardClientData | null;
298
+ // (undocumented)
299
+ error?: ProfileCardErrorType;
300
+ // (undocumented)
301
+ hasError: boolean;
302
+ // (undocumented)
303
+ isKudosEnabled?: boolean;
304
+ // (undocumented)
305
+ isLoading?: boolean;
306
+ // (undocumented)
307
+ kudosDrawerOpen: boolean;
308
+ // (undocumented)
309
+ reportingLinesData?: TeamCentralReportingLinesData;
310
+ // (undocumented)
311
+ visible?: boolean;
328
312
  }
329
313
 
330
314
  // @public (undocumented)
331
315
  export const ProfileCardTrigger: React_2.ForwardRefExoticComponent<
332
- Pick<
333
- Omit<
334
- ProfileCardTriggerProps & AnalyticsProps,
335
- keyof WithAnalyticsEventsProps
336
- >,
337
- never
338
- > &
339
- Partial<
340
- Pick<
341
- Omit<
342
- ProfileCardTriggerProps & AnalyticsProps,
343
- keyof WithAnalyticsEventsProps
344
- >,
345
- keyof ProfileCardTriggerProps
346
- >
347
- > &
348
- Partial<Pick<Partial<ProfileCardTriggerProps>, never>> &
349
- React_2.RefAttributes<any>
316
+ Pick<Omit<ProfileCardTriggerProps & AnalyticsProps, keyof WithAnalyticsEventsProps>, never> &
317
+ Partial<
318
+ Pick<
319
+ Omit<ProfileCardTriggerProps & AnalyticsProps, keyof WithAnalyticsEventsProps>,
320
+ keyof ProfileCardTriggerProps
321
+ >
322
+ > &
323
+ Partial<Pick<Partial<ProfileCardTriggerProps>, never>> &
324
+ React_2.RefAttributes<any>
350
325
  >;
351
326
 
352
327
  // @public (undocumented)
353
328
  export type ProfilecardTriggerPosition =
354
- | 'bottom'
355
- | 'bottom-end'
356
- | 'bottom-start'
357
- | 'left'
358
- | 'left-end'
359
- | 'left-start'
360
- | 'right'
361
- | 'right-end'
362
- | 'right-start'
363
- | 'top'
364
- | 'top-end'
365
- | 'top-start';
329
+ | 'bottom'
330
+ | 'bottom-end'
331
+ | 'bottom-start'
332
+ | 'left'
333
+ | 'left-end'
334
+ | 'left-start'
335
+ | 'right'
336
+ | 'right-end'
337
+ | 'right-start'
338
+ | 'top'
339
+ | 'top-end'
340
+ | 'top-start';
366
341
 
367
342
  // @public (undocumented)
368
343
  export interface ProfileCardTriggerProps {
369
- // (undocumented)
370
- actions?: ProfileCardAction[];
371
- // (undocumented)
372
- addFlag?: (flag: any) => void;
373
- // (undocumented)
374
- children?: React_2.ReactNode;
375
- cloudId?: string;
376
- // (undocumented)
377
- onReportingLinesClick?: (user: ReportingLinesUser) => void;
378
- // (undocumented)
379
- position?: ProfilecardTriggerPosition;
380
- // (undocumented)
381
- reportingLinesProfileUrl?: string;
382
- // (undocumented)
383
- resourceClient: ProfileClient_2;
384
- // (undocumented)
385
- testId?: string;
386
- // (undocumented)
387
- trigger?: TriggerType;
388
- // (undocumented)
389
- userId: string;
344
+ // (undocumented)
345
+ actions?: ProfileCardAction[];
346
+ // (undocumented)
347
+ addFlag?: (flag: any) => void;
348
+ // (undocumented)
349
+ children?: React_2.ReactNode;
350
+ cloudId?: string;
351
+ // (undocumented)
352
+ onReportingLinesClick?: (user: ReportingLinesUser) => void;
353
+ // (undocumented)
354
+ position?: ProfilecardTriggerPosition;
355
+ // (undocumented)
356
+ reportingLinesProfileUrl?: string;
357
+ // (undocumented)
358
+ resourceClient: ProfileClient_2;
359
+ // (undocumented)
360
+ testId?: string;
361
+ // (undocumented)
362
+ trigger?: TriggerType;
363
+ // (undocumented)
364
+ userId: string;
390
365
  }
391
366
 
392
367
  // @public (undocumented)
393
368
  export interface ProfileCardTriggerState {
394
- // (undocumented)
395
- data: ProfileCardClientData | null;
396
- // (undocumented)
397
- error?: ProfileCardErrorType;
398
- // (undocumented)
399
- hasError: boolean;
400
- // (undocumented)
401
- isLoading?: boolean;
402
- // (undocumented)
403
- kudosDrawerOpen: boolean;
404
- // (undocumented)
405
- reportingLinesData?: TeamCentralReportingLinesData;
406
- // (undocumented)
407
- shouldShowGiveKudos?: boolean;
408
- // (undocumented)
409
- teamCentralBaseUrl?: string;
410
- // (undocumented)
411
- visible?: boolean;
369
+ // (undocumented)
370
+ data: ProfileCardClientData | null;
371
+ // (undocumented)
372
+ error?: ProfileCardErrorType;
373
+ // (undocumented)
374
+ hasError: boolean;
375
+ // (undocumented)
376
+ isLoading?: boolean;
377
+ // (undocumented)
378
+ kudosDrawerOpen: boolean;
379
+ // (undocumented)
380
+ reportingLinesData?: TeamCentralReportingLinesData;
381
+ // (undocumented)
382
+ shouldShowGiveKudos?: boolean;
383
+ // (undocumented)
384
+ teamCentralBaseUrl?: string;
385
+ // (undocumented)
386
+ visible?: boolean;
412
387
  }
413
388
 
414
389
  // @public (undocumented)
415
390
  export class ProfileClient {
416
- constructor(config: ProfileClientOptions, clients?: ClientOverrides);
417
- // (undocumented)
418
- flushCache(): void;
419
- // (undocumented)
420
- getProfile(
421
- cloudId: string,
422
- userId: string,
423
- analytics?: (event: AnalyticsEventPayload) => void,
424
- ): Promise<any>;
425
- // (undocumented)
426
- getReportingLines(userId: string): Promise<TeamCentralReportingLinesData>;
427
- // (undocumented)
428
- getTeamCentralBaseUrl(): string | undefined;
429
- // (undocumented)
430
- getTeamProfile(
431
- teamId: string,
432
- orgId?: string,
433
- analytics?: (event: AnalyticsEventPayload) => void,
434
- ): Promise<Team>;
435
- // (undocumented)
436
- shouldShowGiveKudos(): Promise<boolean>;
437
- // (undocumented)
438
- tcClient?: TeamCentralCardClient;
439
- // (undocumented)
440
- teamClient: TeamProfileClient;
441
- // (undocumented)
442
- userClient: UserProfileClient;
391
+ constructor(config: ProfileClientOptions, clients?: ClientOverrides);
392
+ // (undocumented)
393
+ flushCache(): void;
394
+ // (undocumented)
395
+ getProfile(
396
+ cloudId: string,
397
+ userId: string,
398
+ analytics?: (event: AnalyticsEventPayload) => void,
399
+ ): Promise<any>;
400
+ // (undocumented)
401
+ getReportingLines(userId: string): Promise<TeamCentralReportingLinesData>;
402
+ // (undocumented)
403
+ getTeamCentralBaseUrl(): string | undefined;
404
+ // (undocumented)
405
+ getTeamProfile(
406
+ teamId: string,
407
+ orgId?: string,
408
+ analytics?: (event: AnalyticsEventPayload) => void,
409
+ ): Promise<Team>;
410
+ // (undocumented)
411
+ shouldShowGiveKudos(): Promise<boolean>;
412
+ // (undocumented)
413
+ tcClient?: TeamCentralCardClient;
414
+ // (undocumented)
415
+ teamClient: TeamProfileClient;
416
+ // (undocumented)
417
+ userClient: UserProfileClient;
443
418
  }
444
419
 
445
420
  // @public (undocumented)
446
421
  interface ProfileClient_2 {
447
- // (undocumented)
448
- flushCache: () => void;
449
- // (undocumented)
450
- getProfile: (
451
- cloudId: string,
452
- userId: string,
453
- analytics?: (event: AnalyticsEventPayload) => void,
454
- ) => Promise<ProfileCardClientData>;
455
- // (undocumented)
456
- getReportingLines: (userId: string) => Promise<TeamCentralReportingLinesData>;
457
- // (undocumented)
458
- getTeamCentralBaseUrl: () => string | undefined;
459
- // (undocumented)
460
- getTeamProfile: (
461
- teamId: string,
462
- orgId?: string,
463
- fireAnalytics?: (event: AnalyticsEventPayload) => void,
464
- ) => Promise<Team>;
465
- // (undocumented)
466
- shouldShowGiveKudos: () => Promise<boolean>;
422
+ // (undocumented)
423
+ flushCache: () => void;
424
+ // (undocumented)
425
+ getProfile: (
426
+ cloudId: string,
427
+ userId: string,
428
+ analytics?: (event: AnalyticsEventPayload) => void,
429
+ ) => Promise<ProfileCardClientData>;
430
+ // (undocumented)
431
+ getReportingLines: (userId: string) => Promise<TeamCentralReportingLinesData>;
432
+ // (undocumented)
433
+ getTeamCentralBaseUrl: () => string | undefined;
434
+ // (undocumented)
435
+ getTeamProfile: (
436
+ teamId: string,
437
+ orgId?: string,
438
+ fireAnalytics?: (event: AnalyticsEventPayload) => void,
439
+ ) => Promise<Team>;
440
+ // (undocumented)
441
+ shouldShowGiveKudos: () => Promise<boolean>;
467
442
  }
468
443
 
469
444
  // @public (undocumented)
470
445
  export interface ProfileClientOptions {
471
- // (undocumented)
472
- cacheMaxAge?: number;
473
- // (undocumented)
474
- cacheSize?: number;
475
- // (undocumented)
476
- cloudId?: string;
477
- // (undocumented)
478
- gatewayGraphqlUrl?: string;
479
- productIdentifier?: string;
480
- teamCentralBaseUrl?: string;
481
- teamCentralUrl?: string;
482
- // (undocumented)
483
- url: string;
446
+ // (undocumented)
447
+ cacheMaxAge?: number;
448
+ // (undocumented)
449
+ cacheSize?: number;
450
+ // (undocumented)
451
+ cloudId?: string;
452
+ // (undocumented)
453
+ gatewayGraphqlUrl?: string;
454
+ productIdentifier?: string;
455
+ teamCentralBaseUrl?: string;
456
+ teamCentralUrl?: string;
457
+ // (undocumented)
458
+ url: string;
484
459
  }
485
460
 
486
461
  // @public (undocumented)
487
462
  export type RelativeDateKeyType =
488
- | 'AFewMonths'
489
- | 'LastMonth'
490
- | 'MoreThanAYear'
491
- | 'SeveralMonths'
492
- | 'ThisMonth'
493
- | 'ThisWeek'
494
- | null;
463
+ | 'AFewMonths'
464
+ | 'LastMonth'
465
+ | 'MoreThanAYear'
466
+ | 'SeveralMonths'
467
+ | 'ThisMonth'
468
+ | 'ThisWeek'
469
+ | null;
495
470
 
496
471
  // @public (undocumented)
497
472
  interface ReportingLinesUser {
498
- // (undocumented)
499
- accountIdentifier: string;
500
- // (undocumented)
501
- identifierType: 'ATLASSIAN_ID' | 'BASE64_HASH' | 'UNKNOWN';
502
- // (undocumented)
503
- pii?: ReportingLinesUserPII;
473
+ // (undocumented)
474
+ accountIdentifier: string;
475
+ // (undocumented)
476
+ identifierType: 'ATLASSIAN_ID' | 'BASE64_HASH' | 'UNKNOWN';
477
+ // (undocumented)
478
+ pii?: ReportingLinesUserPII;
504
479
  }
505
480
 
506
481
  // @public (undocumented)
507
482
  interface ReportingLinesUserPII {
508
- // (undocumented)
509
- name: string;
510
- // (undocumented)
511
- picture?: string;
483
+ // (undocumented)
484
+ name: string;
485
+ // (undocumented)
486
+ picture?: string;
512
487
  }
513
488
 
514
489
  // @public (undocumented)
515
490
  export type StatusModifiedDateType =
516
- | 'aFewMonths'
517
- | 'lastMonth'
518
- | 'moreThanAYear'
519
- | 'noDate'
520
- | 'severalMonths'
521
- | 'thisMonth'
522
- | 'thisWeek';
491
+ | 'aFewMonths'
492
+ | 'lastMonth'
493
+ | 'moreThanAYear'
494
+ | 'noDate'
495
+ | 'severalMonths'
496
+ | 'thisMonth'
497
+ | 'thisWeek';
523
498
 
524
499
  // @public (undocumented)
525
500
  export type StatusType = 'active' | 'closed' | 'inactive';
526
501
 
527
502
  // @public (undocumented)
528
503
  export interface Team {
529
- // (undocumented)
530
- description: string;
531
- // (undocumented)
532
- displayName: string;
533
- // (undocumented)
534
- id: string;
535
- // (undocumented)
536
- largeAvatarImageUrl?: string;
537
- // (undocumented)
538
- largeHeaderImageUrl?: string;
539
- // (undocumented)
540
- members?: {
541
- id: string;
542
- fullName: string;
543
- avatarUrl: string;
544
- }[];
545
- // (undocumented)
546
- organizationId?: string;
547
- // (undocumented)
548
- smallAvatarImageUrl?: string;
549
- // (undocumented)
550
- smallHeaderImageUrl?: string;
504
+ // (undocumented)
505
+ description: string;
506
+ // (undocumented)
507
+ displayName: string;
508
+ // (undocumented)
509
+ id: string;
510
+ // (undocumented)
511
+ largeAvatarImageUrl?: string;
512
+ // (undocumented)
513
+ largeHeaderImageUrl?: string;
514
+ // (undocumented)
515
+ members?: {
516
+ id: string;
517
+ fullName: string;
518
+ avatarUrl: string;
519
+ }[];
520
+ // (undocumented)
521
+ organizationId?: string;
522
+ // (undocumented)
523
+ smallAvatarImageUrl?: string;
524
+ // (undocumented)
525
+ smallHeaderImageUrl?: string;
551
526
  }
552
527
 
553
528
  // @public (undocumented)
554
529
  class TeamCentralCardClient extends CachingClient<TeamCentralReportingLinesData> {
555
- constructor(options: TeamCentralCardClientOptions);
556
- bypassOnFailure: boolean;
557
- // (undocumented)
558
- checkWorkspaceExists(): Promise<boolean>;
559
- // (undocumented)
560
- createTcReadyPromise(config: ProfileClientOptions): Promise<boolean>;
561
- // (undocumented)
562
- featureFlagKeys: Map<string, boolean>;
563
- // (undocumented)
564
- getFlagEnabled(
565
- featureKey: string,
566
- productIdentifier?: string,
567
- ): Promise<boolean>;
568
- // (undocumented)
569
- getReportingLines(userId: string): Promise<TeamCentralReportingLinesData>;
570
- // (undocumented)
571
- isTCReadyPromise: Promise<boolean>;
572
- // (undocumented)
573
- makeFeatureFlagCheckRequest(
574
- featureKey: string,
575
- context?: FeatureFlagExtraContext[],
576
- ): Promise<boolean>;
577
- // (undocumented)
578
- makeRequest(userId: string): Promise<TeamCentralReportingLinesData>;
579
- // (undocumented)
580
- options: TeamCentralCardClientOptions;
530
+ constructor(options: TeamCentralCardClientOptions);
531
+ bypassOnFailure: boolean;
532
+ // (undocumented)
533
+ checkWorkspaceExists(): Promise<boolean>;
534
+ // (undocumented)
535
+ createTcReadyPromise(config: ProfileClientOptions): Promise<boolean>;
536
+ // (undocumented)
537
+ featureFlagKeys: Map<string, boolean>;
538
+ // (undocumented)
539
+ getFlagEnabled(featureKey: string, productIdentifier?: string): Promise<boolean>;
540
+ // (undocumented)
541
+ getReportingLines(userId: string): Promise<TeamCentralReportingLinesData>;
542
+ // (undocumented)
543
+ isTCReadyPromise: Promise<boolean>;
544
+ // (undocumented)
545
+ makeFeatureFlagCheckRequest(
546
+ featureKey: string,
547
+ context?: FeatureFlagExtraContext[],
548
+ ): Promise<boolean>;
549
+ // (undocumented)
550
+ makeRequest(userId: string): Promise<TeamCentralReportingLinesData>;
551
+ // (undocumented)
552
+ options: TeamCentralCardClientOptions;
581
553
  }
582
554
 
583
555
  // @public (undocumented)
584
556
  type TeamCentralCardClientOptions = ProfileClientOptions & {
585
- teamCentralUrl: string;
557
+ teamCentralUrl: string;
586
558
  };
587
559
 
588
560
  // @public (undocumented)
589
561
  interface TeamCentralReportingLinesData {
590
- // (undocumented)
591
- managers?: ReportingLinesUser[];
592
- // (undocumented)
593
- reports?: ReportingLinesUser[];
562
+ // (undocumented)
563
+ managers?: ReportingLinesUser[];
564
+ // (undocumented)
565
+ reports?: ReportingLinesUser[];
594
566
  }
595
567
 
596
568
  // @public (undocumented)
597
- export const TeamProfileCard: (
598
- props: TeamProfilecardProps,
599
- ) => JSX.Element | null;
569
+ export const TeamProfileCard: (props: TeamProfilecardProps) => JSX.Element | null;
600
570
 
601
571
  // @public (undocumented)
602
572
  interface TeamProfilecardCoreProps {
603
- actions?: ProfileCardAction[];
604
- generateUserLink?: (userId: string) => string;
605
- onUserClick?: (userId: string, event: React_2.MouseEvent<Element>) => void;
606
- viewingUserId?: string;
607
- viewProfileLink: string;
608
- viewProfileOnClick?: (event?: React_2.MouseEvent<Element>) => void;
573
+ actions?: ProfileCardAction[];
574
+ generateUserLink?: (userId: string) => string;
575
+ onUserClick?: (userId: string, event: React_2.MouseEvent<Element>) => void;
576
+ viewingUserId?: string;
577
+ viewProfileLink: string;
578
+ viewProfileOnClick?: (event?: React_2.MouseEvent<Element>) => void;
609
579
  }
610
580
 
611
581
  // @public (undocumented)
612
582
  type TeamProfileCardErrorType = null | {
613
- reason: 'NotFound' | 'TEAMS_FORBIDDEN' | 'default';
583
+ reason: 'NotFound' | 'TEAMS_FORBIDDEN' | 'default';
614
584
  };
615
585
 
616
586
  // @public (undocumented)
617
587
  interface TeamProfilecardProps extends TeamProfilecardCoreProps {
618
- analytics: AnalyticsFunction;
619
- clientFetchProfile?: () => void;
620
- errorType?: TeamProfileCardErrorType;
621
- hasError?: boolean;
622
- isLoading?: boolean;
623
- team?: Team;
588
+ analytics: AnalyticsFunction;
589
+ clientFetchProfile?: () => void;
590
+ errorType?: TeamProfileCardErrorType;
591
+ hasError?: boolean;
592
+ isLoading?: boolean;
593
+ team?: Team;
624
594
  }
625
595
 
626
596
  // @public (undocumented)
627
597
  export const TeamProfileCardTrigger: React_2.ForwardRefExoticComponent<
628
- Pick<
629
- Omit<
630
- TeamProfileCardTriggerProps & AnalyticsProps,
631
- keyof WithAnalyticsEventsProps
632
- >,
633
- never
634
- > &
635
- Partial<
636
- Pick<
637
- Omit<
638
- TeamProfileCardTriggerProps & AnalyticsProps,
639
- keyof WithAnalyticsEventsProps
640
- >,
641
- keyof TeamProfileCardTriggerProps
642
- >
643
- > &
644
- Partial<Pick<Partial<TeamProfileCardTriggerProps>, never>> &
645
- React_2.RefAttributes<any>
598
+ Pick<Omit<TeamProfileCardTriggerProps & AnalyticsProps, keyof WithAnalyticsEventsProps>, never> &
599
+ Partial<
600
+ Pick<
601
+ Omit<TeamProfileCardTriggerProps & AnalyticsProps, keyof WithAnalyticsEventsProps>,
602
+ keyof TeamProfileCardTriggerProps
603
+ >
604
+ > &
605
+ Partial<Pick<Partial<TeamProfileCardTriggerProps>, never>> &
606
+ React_2.RefAttributes<any>
646
607
  >;
647
608
 
648
609
  // @public (undocumented)
649
610
  interface TeamProfileCardTriggerProps extends TeamProfilecardCoreProps {
650
- addFlag?: (flag: any) => void;
651
- children?: React_2.ReactNode;
652
- cloudId?: string;
653
- orgId: string;
654
- position?: ProfilecardTriggerPosition;
655
- resourceClient: ProfileClient_2;
656
- teamId: string;
657
- trigger?: 'click' | 'hover' | 'hover-click';
658
- triggerLinkType?: 'clickable-link' | 'link' | 'none';
611
+ addFlag?: (flag: any) => void;
612
+ children?: React_2.ReactNode;
613
+ cloudId?: string;
614
+ orgId: string;
615
+ position?: ProfilecardTriggerPosition;
616
+ resourceClient: ProfileClient_2;
617
+ teamId: string;
618
+ trigger?: 'click' | 'hover' | 'hover-click';
619
+ triggerLinkType?: 'clickable-link' | 'link' | 'none';
659
620
  }
660
621
 
661
622
  // @public (undocumented)
662
623
  export class TeamProfileClient extends CachingClient<Team> {
663
- constructor(options: ProfileClientOptions);
664
- // (undocumented)
665
- getProfile(
666
- teamId: string,
667
- orgId: string | undefined,
668
- analytics?: (event: AnalyticsEventPayload) => void,
669
- ): Promise<Team>;
670
- // (undocumented)
671
- makeRequest(teamId: string, _orgId: string | undefined): Promise<Team>;
672
- // (undocumented)
673
- options: ProfileClientOptions;
624
+ constructor(options: ProfileClientOptions);
625
+ // (undocumented)
626
+ getProfile(
627
+ teamId: string,
628
+ orgId: string | undefined,
629
+ analytics?: (event: AnalyticsEventPayload) => void,
630
+ ): Promise<Team>;
631
+ // (undocumented)
632
+ makeRequest(teamId: string, _orgId: string | undefined): Promise<Team>;
633
+ // (undocumented)
634
+ options: ProfileClientOptions;
674
635
  }
675
636
 
676
637
  // @public (undocumented)
@@ -678,30 +639,30 @@ export type TriggerType = 'click' | 'hover';
678
639
 
679
640
  // @public (undocumented)
680
641
  export class UserProfileClient extends CachingClient<any> {
681
- constructor(options: ProfileClientOptions);
682
- // (undocumented)
683
- getProfile(
684
- cloudId: string,
685
- userId: string,
686
- analytics?: (event: AnalyticsEventPayload) => void,
687
- ): Promise<any>;
688
- // (undocumented)
689
- makeRequest(cloudId: string, userId: string): Promise<ProfileCardClientData>;
690
- // (undocumented)
691
- options: ProfileClientOptions;
642
+ constructor(options: ProfileClientOptions);
643
+ // (undocumented)
644
+ getProfile(
645
+ cloudId: string,
646
+ userId: string,
647
+ analytics?: (event: AnalyticsEventPayload) => void,
648
+ ): Promise<any>;
649
+ // (undocumented)
650
+ makeRequest(cloudId: string, userId: string): Promise<ProfileCardClientData>;
651
+ // (undocumented)
652
+ options: ProfileClientOptions;
692
653
  }
693
654
 
694
655
  // @public (undocumented)
695
656
  export function withOuterListeners<P>(
696
- Component: ComponentType<P>,
657
+ Component: ComponentType<P>,
697
658
  ): React_2.ComponentClass<P & WithOuterListenersProps>;
698
659
 
699
660
  // @public (undocumented)
700
661
  export interface WithOuterListenersProps {
701
- // (undocumented)
702
- handleClickOutside?: () => void;
703
- // (undocumented)
704
- handleEscapeKeydown?: () => void;
662
+ // (undocumented)
663
+ handleClickOutside?: () => void;
664
+ // (undocumented)
665
+ handleEscapeKeydown?: () => void;
705
666
  }
706
667
 
707
668
  // (No @packageDocumentation comment for this package)
@@ -715,8 +676,8 @@ export interface WithOuterListenersProps {
715
676
 
716
677
  ```json
717
678
  {
718
- "react": "^16.8.0",
719
- "react-dom": "^16.8.0"
679
+ "react": "^16.8.0",
680
+ "react-dom": "^16.8.0"
720
681
  }
721
682
  ```
722
683