dce-reactkit 5.0.1 → 5.0.2
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/dist/cjs/index.js +305 -160
- package/dist/cjs/index.js.map +1 -1
- package/dist/cjs/types/components/FakeProgressBar.d.ts +27 -0
- package/dist/cjs/types/index.d.ts +2 -1
- package/dist/esm/index.js +305 -161
- package/dist/esm/index.js.map +1 -1
- package/dist/esm/types/components/FakeProgressBar.d.ts +27 -0
- package/dist/esm/types/index.d.ts +2 -1
- package/dist/index.d.ts +74 -49
- package/package.json +1 -1
- package/src/components/FakeProgressBar.tsx +274 -0
- package/src/index.ts +2 -0
|
@@ -0,0 +1,27 @@
|
|
|
1
|
+
/**
|
|
2
|
+
* Fake progress bar that approaches completion but never fully finishes.
|
|
3
|
+
* Built on top of the existing ProgressBar component.
|
|
4
|
+
*
|
|
5
|
+
* Two phases:
|
|
6
|
+
* 1. Fast phase (0–90%): random jumps of 1–5% at randomized intervals,
|
|
7
|
+
* paced to reach ~90% in roughly estimatedTimeSec seconds.
|
|
8
|
+
* 2. Slow phase (90–99%): crawls 1% at a time with longer random delays,
|
|
9
|
+
* never reaching 100% on its own.
|
|
10
|
+
*
|
|
11
|
+
* When isFinished becomes true, the bar immediately jumps to 100%.
|
|
12
|
+
* @author Yuen Ler Chow
|
|
13
|
+
*/
|
|
14
|
+
import React from 'react';
|
|
15
|
+
import Variant from '../types/Variant';
|
|
16
|
+
import ProgressBarSize from '../types/ProgressBarSize';
|
|
17
|
+
type Props = {
|
|
18
|
+
isFinished?: boolean;
|
|
19
|
+
estimatedTimeSec?: number;
|
|
20
|
+
striped?: boolean;
|
|
21
|
+
variant?: Variant;
|
|
22
|
+
bgVariant?: Variant;
|
|
23
|
+
showOutline?: boolean;
|
|
24
|
+
size?: ProgressBarSize;
|
|
25
|
+
};
|
|
26
|
+
declare const FakeProgressBar: React.FC<Props>;
|
|
27
|
+
export default FakeProgressBar;
|
|
@@ -25,6 +25,7 @@ import AutoscrollToBottomContainer from './components/AutoscrollToBottomContaine
|
|
|
25
25
|
import MultiSwitch from './components/MultiSwitch';
|
|
26
26
|
import Dropdown from './components/Dropdown';
|
|
27
27
|
import ProgressBar from './components/ProgressBar';
|
|
28
|
+
import FakeProgressBar from './components/FakeProgressBar';
|
|
28
29
|
import DynamicWord from './dynamicConstants/DynamicWord';
|
|
29
30
|
import initClient from './helpers/initClient';
|
|
30
31
|
import visitServerEndpoint from './helpers/visitServerEndpoint';
|
|
@@ -47,4 +48,4 @@ import PickableItem from './components/ItemPicker/types/PickableItem';
|
|
|
47
48
|
import DBEntry from './components/DBEntryManagerPanel/types/DBEntry';
|
|
48
49
|
import DBEntryField from './components/DBEntryManagerPanel/types/DBEntryField';
|
|
49
50
|
import DBEntryFieldType from './components/DBEntryManagerPanel/types/DBEntryFieldType';
|
|
50
|
-
export { AppWrapper, LoadingSpinner, ErrorBox, Modal, TabBox, RadioButton, CheckboxButton, ButtonInputGroup, SimpleDateChooser, SimpleTimeChooser, Drawer, PopSuccessMark, PopFailureMark, PopPendingMark, CopiableBox, ItemPicker, LogReviewer, IntelliTable, CSVDownloadButton, DBEntryManagerPanel, Tooltip, ToggleSwitch, AutoscrollToBottomContainer, MultiSwitch, Dropdown, ProgressBar, alert, prompt, confirm, showFatalError, DynamicWord, stubServerEndpoint, canReviewLogs, isMobileOrTablet, makeLinksClickable, isSelectAdmin, initClient, visitServerEndpoint, logClientEvent, addFatalErrorHandler, leaveToURL, combineClassNames, useForceRender, setClientEventMetadataPopulator, ModalButtonType, ModalSize, ModalType, Variant, IntelliTableColumn, DropdownItemType, LogReviewerFilterState, ProgressBarSize, PickableItem, DBEntry, DBEntryField, DBEntryFieldType, ErrorWithCode, MINUTE_IN_MS, HOUR_IN_MS, DAY_IN_MS, LOG_REVIEW_ROUTE_PATH_PREFIX, LOG_ROUTE_PATH, LOG_REVIEW_STATUS_ROUTE, LOG_REVIEW_GET_LOGS_ROUTE, SELECT_ADMIN_CHECK_ROUTE, abbreviate, avg, ceilToNumDecimals, floorToNumDecimals, forceNumIntoBounds, padDecimalZeros, padZerosLeft, roundToNumDecimals, sum, waitMs, getOrdinal, getTimeInfoInET, startMinWait, getHumanReadableDate, getPartOfDay, stringsToHumanReadableList, onlyKeepLetters, parallelLimit, getMonthName, genCSV, extractProp, compareArraysByProp, getLocalTimeInfo, genCommaList, validateEmail, validatePhoneNumber, validateString, idify, prefixWithAOrAn, everyAsync, filterAsync, forEachAsync, mapAsync, someAsync, capitalize, shuffleArray, getWordCount, cloneDeep, getTimestampFromTimeInfoInET, ParamType, DayOfWeek, Log, LogType, LogSource, LogAction, LogBuiltInMetadata, LogMetadataType, LogFunction, LogTypeSpecificInfo, LogMainInfo, LogSourceSpecificInfo, LogLevel, CommonKitErrorCode, };
|
|
51
|
+
export { AppWrapper, LoadingSpinner, ErrorBox, Modal, TabBox, RadioButton, CheckboxButton, ButtonInputGroup, SimpleDateChooser, SimpleTimeChooser, Drawer, PopSuccessMark, PopFailureMark, PopPendingMark, CopiableBox, ItemPicker, LogReviewer, IntelliTable, CSVDownloadButton, DBEntryManagerPanel, Tooltip, ToggleSwitch, AutoscrollToBottomContainer, MultiSwitch, Dropdown, ProgressBar, FakeProgressBar, alert, prompt, confirm, showFatalError, DynamicWord, stubServerEndpoint, canReviewLogs, isMobileOrTablet, makeLinksClickable, isSelectAdmin, initClient, visitServerEndpoint, logClientEvent, addFatalErrorHandler, leaveToURL, combineClassNames, useForceRender, setClientEventMetadataPopulator, ModalButtonType, ModalSize, ModalType, Variant, IntelliTableColumn, DropdownItemType, LogReviewerFilterState, ProgressBarSize, PickableItem, DBEntry, DBEntryField, DBEntryFieldType, ErrorWithCode, MINUTE_IN_MS, HOUR_IN_MS, DAY_IN_MS, LOG_REVIEW_ROUTE_PATH_PREFIX, LOG_ROUTE_PATH, LOG_REVIEW_STATUS_ROUTE, LOG_REVIEW_GET_LOGS_ROUTE, SELECT_ADMIN_CHECK_ROUTE, abbreviate, avg, ceilToNumDecimals, floorToNumDecimals, forceNumIntoBounds, padDecimalZeros, padZerosLeft, roundToNumDecimals, sum, waitMs, getOrdinal, getTimeInfoInET, startMinWait, getHumanReadableDate, getPartOfDay, stringsToHumanReadableList, onlyKeepLetters, parallelLimit, getMonthName, genCSV, extractProp, compareArraysByProp, getLocalTimeInfo, genCommaList, validateEmail, validatePhoneNumber, validateString, idify, prefixWithAOrAn, everyAsync, filterAsync, forEachAsync, mapAsync, someAsync, capitalize, shuffleArray, getWordCount, cloneDeep, getTimestampFromTimeInfoInET, ParamType, DayOfWeek, Log, LogType, LogSource, LogAction, LogBuiltInMetadata, LogMetadataType, LogFunction, LogTypeSpecificInfo, LogMainInfo, LogSourceSpecificInfo, LogLevel, CommonKitErrorCode, };
|
package/dist/index.d.ts
CHANGED
|
@@ -25,7 +25,7 @@ declare enum Variant {
|
|
|
25
25
|
* @author Gabe Abrams
|
|
26
26
|
*/
|
|
27
27
|
|
|
28
|
-
type Props$
|
|
28
|
+
type Props$o = {
|
|
29
29
|
children: React$1.ReactNode;
|
|
30
30
|
};
|
|
31
31
|
/**
|
|
@@ -108,7 +108,7 @@ declare const showFatalError: (error: any, errorTitle?: string) => Promise<void>
|
|
|
108
108
|
* @author Gabe Abrams
|
|
109
109
|
*/
|
|
110
110
|
declare const addFatalErrorHandler: (handler: () => void) => void;
|
|
111
|
-
declare const AppWrapper: React$1.FC<Props$
|
|
111
|
+
declare const AppWrapper: React$1.FC<Props$o>;
|
|
112
112
|
|
|
113
113
|
/**
|
|
114
114
|
* Loading spinner/indicator
|
|
@@ -122,14 +122,14 @@ declare const LoadingSpinner: () => React$1.JSX.Element;
|
|
|
122
122
|
* @author Gabe Abrams
|
|
123
123
|
*/
|
|
124
124
|
|
|
125
|
-
type Props$
|
|
125
|
+
type Props$n = {
|
|
126
126
|
error: any;
|
|
127
127
|
title?: string;
|
|
128
128
|
onClose?: () => void;
|
|
129
129
|
variant?: Variant;
|
|
130
130
|
icon?: IconProp;
|
|
131
131
|
};
|
|
132
|
-
declare const ErrorBox: React$1.FC<Props$
|
|
132
|
+
declare const ErrorBox: React$1.FC<Props$n>;
|
|
133
133
|
|
|
134
134
|
/**
|
|
135
135
|
* Types of buttons in the modal
|
|
@@ -228,7 +228,7 @@ declare const Modal: React$1.FC<ModalProps>;
|
|
|
228
228
|
* @author Gabe Abrams
|
|
229
229
|
*/
|
|
230
230
|
|
|
231
|
-
type Props$
|
|
231
|
+
type Props$m = {
|
|
232
232
|
title: React$1.ReactNode;
|
|
233
233
|
children: React$1.ReactNode;
|
|
234
234
|
topRightChildren?: React$1.ReactNode;
|
|
@@ -236,14 +236,14 @@ type Props$l = {
|
|
|
236
236
|
noBottomPadding?: boolean;
|
|
237
237
|
minTitleWidth?: string;
|
|
238
238
|
};
|
|
239
|
-
declare const TabBox: React$1.FC<Props$
|
|
239
|
+
declare const TabBox: React$1.FC<Props$m>;
|
|
240
240
|
|
|
241
241
|
/**
|
|
242
242
|
* A radio selection button
|
|
243
243
|
* @author Gabe Abrams
|
|
244
244
|
*/
|
|
245
245
|
|
|
246
|
-
type Props$
|
|
246
|
+
type Props$l = {
|
|
247
247
|
text: React$1.ReactNode;
|
|
248
248
|
onSelected: () => void;
|
|
249
249
|
ariaLabel: string;
|
|
@@ -257,14 +257,14 @@ type Props$k = {
|
|
|
257
257
|
small?: boolean;
|
|
258
258
|
useComplexFormatting?: boolean;
|
|
259
259
|
};
|
|
260
|
-
declare const RadioButton: React$1.FC<Props$
|
|
260
|
+
declare const RadioButton: React$1.FC<Props$l>;
|
|
261
261
|
|
|
262
262
|
/**
|
|
263
263
|
* A checkbox button
|
|
264
264
|
* @author Gabe Abrams
|
|
265
265
|
*/
|
|
266
266
|
|
|
267
|
-
type Props$
|
|
267
|
+
type Props$k = {
|
|
268
268
|
text: React$1.ReactNode;
|
|
269
269
|
onChanged: (checked: boolean) => void;
|
|
270
270
|
ariaLabel: string;
|
|
@@ -279,14 +279,14 @@ type Props$j = {
|
|
|
279
279
|
dashed?: boolean;
|
|
280
280
|
useComplexFormatting?: boolean;
|
|
281
281
|
};
|
|
282
|
-
declare const CheckboxButton: React$1.FC<Props$
|
|
282
|
+
declare const CheckboxButton: React$1.FC<Props$k>;
|
|
283
283
|
|
|
284
284
|
/**
|
|
285
285
|
* Input group with a title and space for buttons
|
|
286
286
|
* @author Gabe Abrams
|
|
287
287
|
*/
|
|
288
288
|
|
|
289
|
-
type Props$
|
|
289
|
+
type Props$j = {
|
|
290
290
|
label: React$1.ReactNode;
|
|
291
291
|
minLabelWidth?: string;
|
|
292
292
|
children: React$1.ReactNode;
|
|
@@ -295,7 +295,7 @@ type Props$i = {
|
|
|
295
295
|
isAdminFeature?: boolean;
|
|
296
296
|
noMarginOnBottom?: boolean;
|
|
297
297
|
};
|
|
298
|
-
declare const ButtonInputGroup: React$1.FC<Props$
|
|
298
|
+
declare const ButtonInputGroup: React$1.FC<Props$j>;
|
|
299
299
|
|
|
300
300
|
/**
|
|
301
301
|
* A very simple, lightweight date chooser
|
|
@@ -303,7 +303,7 @@ declare const ButtonInputGroup: React$1.FC<Props$i>;
|
|
|
303
303
|
* @author Gardenia Liu
|
|
304
304
|
*/
|
|
305
305
|
|
|
306
|
-
type Props$
|
|
306
|
+
type Props$i = {
|
|
307
307
|
ariaLabel: string;
|
|
308
308
|
name: string;
|
|
309
309
|
month: number;
|
|
@@ -321,14 +321,14 @@ type Props$h = {
|
|
|
321
321
|
dontAllowFuture?: boolean;
|
|
322
322
|
isDisabled?: boolean;
|
|
323
323
|
};
|
|
324
|
-
declare const SimpleDateChooser: React$1.FC<Props$
|
|
324
|
+
declare const SimpleDateChooser: React$1.FC<Props$i>;
|
|
325
325
|
|
|
326
326
|
/**
|
|
327
327
|
* A very simple, lightweight time chooser
|
|
328
328
|
* @author Gardenia Liu
|
|
329
329
|
*/
|
|
330
330
|
|
|
331
|
-
type Props$
|
|
331
|
+
type Props$h = {
|
|
332
332
|
ariaLabel: string;
|
|
333
333
|
name: string;
|
|
334
334
|
hour: number;
|
|
@@ -342,62 +342,62 @@ type Props$g = {
|
|
|
342
342
|
intervalMin?: number;
|
|
343
343
|
isDisabled?: boolean;
|
|
344
344
|
};
|
|
345
|
-
declare const SimpleTimeChooser: React$1.FC<Props$
|
|
345
|
+
declare const SimpleTimeChooser: React$1.FC<Props$h>;
|
|
346
346
|
|
|
347
347
|
/**
|
|
348
348
|
* Drawer container
|
|
349
349
|
* @author Gabe Abrams
|
|
350
350
|
*/
|
|
351
351
|
|
|
352
|
-
type Props$
|
|
352
|
+
type Props$g = {
|
|
353
353
|
grayBackground?: boolean;
|
|
354
354
|
customBackgroundColor?: string;
|
|
355
355
|
children: React$1.ReactNode;
|
|
356
356
|
};
|
|
357
|
-
declare const Drawer: React$1.FC<Props$
|
|
357
|
+
declare const Drawer: React$1.FC<Props$g>;
|
|
358
358
|
|
|
359
359
|
/**
|
|
360
360
|
* Success checkmark that pops into view
|
|
361
361
|
* @author Gabe Abrams
|
|
362
362
|
*/
|
|
363
363
|
|
|
364
|
-
type Props$
|
|
364
|
+
type Props$f = {
|
|
365
365
|
sizeRem?: number;
|
|
366
366
|
circleVariant?: string;
|
|
367
367
|
checkVariant?: string;
|
|
368
368
|
};
|
|
369
|
-
declare const PopSuccessMark: React$1.FC<Props$
|
|
369
|
+
declare const PopSuccessMark: React$1.FC<Props$f>;
|
|
370
370
|
|
|
371
371
|
/**
|
|
372
372
|
* Failure x mark that pops into view
|
|
373
373
|
* @author Gabe Abrams
|
|
374
374
|
*/
|
|
375
375
|
|
|
376
|
-
type Props$
|
|
376
|
+
type Props$e = {
|
|
377
377
|
sizeRem?: number;
|
|
378
378
|
circleVariant?: string;
|
|
379
379
|
xVariant?: string;
|
|
380
380
|
};
|
|
381
|
-
declare const PopFailureMark: React$1.FC<Props$
|
|
381
|
+
declare const PopFailureMark: React$1.FC<Props$e>;
|
|
382
382
|
|
|
383
383
|
/**
|
|
384
384
|
* Failure pending that pops into view
|
|
385
385
|
* @author Gabe Abrams
|
|
386
386
|
*/
|
|
387
387
|
|
|
388
|
-
type Props$
|
|
388
|
+
type Props$d = {
|
|
389
389
|
sizeRem?: number;
|
|
390
390
|
circleVariant?: string;
|
|
391
391
|
hourglassVariant?: string;
|
|
392
392
|
};
|
|
393
|
-
declare const PopPendingMark: React$1.FC<Props$
|
|
393
|
+
declare const PopPendingMark: React$1.FC<Props$d>;
|
|
394
394
|
|
|
395
395
|
/**
|
|
396
396
|
* Copiable text box
|
|
397
397
|
* @author Gabe Abrams
|
|
398
398
|
*/
|
|
399
399
|
|
|
400
|
-
type Props$
|
|
400
|
+
type Props$c = {
|
|
401
401
|
text: string;
|
|
402
402
|
maxTextWidthRem?: number;
|
|
403
403
|
label?: string;
|
|
@@ -409,7 +409,7 @@ type Props$b = {
|
|
|
409
409
|
textAreaId?: string;
|
|
410
410
|
copyButtonId?: string;
|
|
411
411
|
};
|
|
412
|
-
declare const CopiableBox: React$1.FC<Props$
|
|
412
|
+
declare const CopiableBox: React$1.FC<Props$c>;
|
|
413
413
|
|
|
414
414
|
/**
|
|
415
415
|
* An item that can be chosen (for use within ItemPicker)
|
|
@@ -432,7 +432,7 @@ type PickableItem = ({
|
|
|
432
432
|
* @author Yuen Ler Chow
|
|
433
433
|
*/
|
|
434
434
|
|
|
435
|
-
type Props$
|
|
435
|
+
type Props$b = {
|
|
436
436
|
title: string;
|
|
437
437
|
items: PickableItem[];
|
|
438
438
|
/**
|
|
@@ -444,7 +444,7 @@ type Props$a = {
|
|
|
444
444
|
noBottomMargin?: boolean;
|
|
445
445
|
hideSelectAllOrNoneButtons?: boolean;
|
|
446
446
|
};
|
|
447
|
-
declare const ItemPicker: React$1.FC<Props$
|
|
447
|
+
declare const ItemPicker: React$1.FC<Props$b>;
|
|
448
448
|
|
|
449
449
|
/**
|
|
450
450
|
* Log reviewer panel that allows users (must be approved admins) to
|
|
@@ -452,11 +452,11 @@ declare const ItemPicker: React$1.FC<Props$a>;
|
|
|
452
452
|
* @author Gabe Abrams
|
|
453
453
|
*/
|
|
454
454
|
|
|
455
|
-
type Props$
|
|
455
|
+
type Props$a = {
|
|
456
456
|
LogMetadata: LogMetadataType;
|
|
457
457
|
onClose: () => void;
|
|
458
458
|
};
|
|
459
|
-
declare const LogReviewer: React$1.FC<Props$
|
|
459
|
+
declare const LogReviewer: React$1.FC<Props$a>;
|
|
460
460
|
|
|
461
461
|
/**
|
|
462
462
|
* Column description for a column in the IntelliTable
|
|
@@ -474,7 +474,7 @@ type IntelliTableColumn = {
|
|
|
474
474
|
* @author Gabe Abrams
|
|
475
475
|
*/
|
|
476
476
|
|
|
477
|
-
type Props$
|
|
477
|
+
type Props$9 = {
|
|
478
478
|
title: string;
|
|
479
479
|
id: string;
|
|
480
480
|
data: {
|
|
@@ -484,14 +484,14 @@ type Props$8 = {
|
|
|
484
484
|
columns: IntelliTableColumn[];
|
|
485
485
|
csvName?: string;
|
|
486
486
|
};
|
|
487
|
-
declare const IntelliTable: React$1.FC<Props$
|
|
487
|
+
declare const IntelliTable: React$1.FC<Props$9>;
|
|
488
488
|
|
|
489
489
|
/**
|
|
490
490
|
* Button for downloading a csv file
|
|
491
491
|
* @author Gabe Abrams
|
|
492
492
|
*/
|
|
493
493
|
|
|
494
|
-
type Props$
|
|
494
|
+
type Props$8 = {
|
|
495
495
|
filename: string;
|
|
496
496
|
csv: string;
|
|
497
497
|
label?: string;
|
|
@@ -504,7 +504,7 @@ type Props$7 = {
|
|
|
504
504
|
onClick?: () => void;
|
|
505
505
|
children?: React$1.ReactNode;
|
|
506
506
|
};
|
|
507
|
-
declare const CSVDownloadButton: React$1.FC<Props$
|
|
507
|
+
declare const CSVDownloadButton: React$1.FC<Props$8>;
|
|
508
508
|
|
|
509
509
|
/**
|
|
510
510
|
* Generic type for an object
|
|
@@ -580,7 +580,7 @@ type DBEntryField = ({
|
|
|
580
580
|
* @author Gabe Abrams
|
|
581
581
|
*/
|
|
582
582
|
|
|
583
|
-
type Props$
|
|
583
|
+
type Props$7 = {
|
|
584
584
|
entryFields: DBEntryField[];
|
|
585
585
|
idPropName: string;
|
|
586
586
|
titlePropName: string;
|
|
@@ -606,18 +606,18 @@ type Props$6 = {
|
|
|
606
606
|
[k: string]: any;
|
|
607
607
|
};
|
|
608
608
|
};
|
|
609
|
-
declare const DBEntryManagerPanel: React$1.FC<Props$
|
|
609
|
+
declare const DBEntryManagerPanel: React$1.FC<Props$7>;
|
|
610
610
|
|
|
611
611
|
/**
|
|
612
612
|
* Simple tooltip component
|
|
613
613
|
* @author Gabe Abrams
|
|
614
614
|
*/
|
|
615
615
|
|
|
616
|
-
type Props$
|
|
616
|
+
type Props$6 = {
|
|
617
617
|
text: string;
|
|
618
618
|
children: any;
|
|
619
619
|
};
|
|
620
|
-
declare const Tooltip: React$1.FC<Props$
|
|
620
|
+
declare const Tooltip: React$1.FC<Props$6>;
|
|
621
621
|
|
|
622
622
|
/**
|
|
623
623
|
* A toggle switch that toggles on or off
|
|
@@ -625,7 +625,7 @@ declare const Tooltip: React$1.FC<Props$5>;
|
|
|
625
625
|
* @author Gabe Abrams
|
|
626
626
|
*/
|
|
627
627
|
|
|
628
|
-
type Props$
|
|
628
|
+
type Props$5 = {
|
|
629
629
|
isOn: boolean;
|
|
630
630
|
/**
|
|
631
631
|
* A handler to call when the switch is toggled
|
|
@@ -637,7 +637,7 @@ type Props$4 = {
|
|
|
637
637
|
description: string;
|
|
638
638
|
backgroundVariantWhenOn?: Variant;
|
|
639
639
|
};
|
|
640
|
-
declare const ToggleSwitch: React$1.FC<Props$
|
|
640
|
+
declare const ToggleSwitch: React$1.FC<Props$5>;
|
|
641
641
|
|
|
642
642
|
/**
|
|
643
643
|
* Container that automatically scrolls when new items are added,
|
|
@@ -648,7 +648,7 @@ declare const ToggleSwitch: React$1.FC<Props$4>;
|
|
|
648
648
|
* @author Gabe Abrams
|
|
649
649
|
*/
|
|
650
650
|
|
|
651
|
-
type Props$
|
|
651
|
+
type Props$4 = {
|
|
652
652
|
itemsName?: string;
|
|
653
653
|
items: AutoScrollItem[];
|
|
654
654
|
jumpToBottomButtonVariant?: Variant;
|
|
@@ -659,7 +659,7 @@ type AutoScrollItem = {
|
|
|
659
659
|
id: string | number;
|
|
660
660
|
item: React$1.ReactNode;
|
|
661
661
|
};
|
|
662
|
-
declare const AutoscrollToBottomContainer: React$1.FC<Props$
|
|
662
|
+
declare const AutoscrollToBottomContainer: React$1.FC<Props$4>;
|
|
663
663
|
|
|
664
664
|
/**
|
|
665
665
|
* A switch with multiple options for selection
|
|
@@ -668,7 +668,7 @@ declare const AutoscrollToBottomContainer: React$1.FC<Props$3>;
|
|
|
668
668
|
* @author Austen Money
|
|
669
669
|
*/
|
|
670
670
|
|
|
671
|
-
type Props$
|
|
671
|
+
type Props$3 = {
|
|
672
672
|
options: Option[];
|
|
673
673
|
selectedOptionId: string;
|
|
674
674
|
/**
|
|
@@ -683,7 +683,7 @@ type Option = {
|
|
|
683
683
|
icon: IconProp;
|
|
684
684
|
id: string;
|
|
685
685
|
};
|
|
686
|
-
declare const MultiSwitch: React$1.FC<Props$
|
|
686
|
+
declare const MultiSwitch: React$1.FC<Props$3>;
|
|
687
687
|
|
|
688
688
|
declare enum DropdownItemType {
|
|
689
689
|
Header = "Header",
|
|
@@ -698,7 +698,7 @@ declare enum DropdownItemType {
|
|
|
698
698
|
* @author Gabe Abrams
|
|
699
699
|
*/
|
|
700
700
|
|
|
701
|
-
type Props$
|
|
701
|
+
type Props$2 = {
|
|
702
702
|
items: DropdownItem[];
|
|
703
703
|
dropdownButton: {
|
|
704
704
|
ariaLabel: string;
|
|
@@ -719,7 +719,7 @@ type DropdownItem = ({
|
|
|
719
719
|
id: string;
|
|
720
720
|
onClick: () => void;
|
|
721
721
|
});
|
|
722
|
-
declare const Dropdown: React$1.FC<Props$
|
|
722
|
+
declare const Dropdown: React$1.FC<Props$2>;
|
|
723
723
|
|
|
724
724
|
/**
|
|
725
725
|
* Progress bar sizes
|
|
@@ -735,7 +735,7 @@ declare enum ProgressBarSize {
|
|
|
735
735
|
* @author Allison Zhang
|
|
736
736
|
*/
|
|
737
737
|
|
|
738
|
-
type Props = (({
|
|
738
|
+
type Props$1 = (({
|
|
739
739
|
percentProgress: number;
|
|
740
740
|
numDecimalPlaces?: number;
|
|
741
741
|
} | {
|
|
@@ -748,7 +748,32 @@ type Props = (({
|
|
|
748
748
|
showOutline?: boolean;
|
|
749
749
|
size?: ProgressBarSize;
|
|
750
750
|
});
|
|
751
|
-
declare const ProgressBar: React$1.FC<Props>;
|
|
751
|
+
declare const ProgressBar: React$1.FC<Props$1>;
|
|
752
|
+
|
|
753
|
+
/**
|
|
754
|
+
* Fake progress bar that approaches completion but never fully finishes.
|
|
755
|
+
* Built on top of the existing ProgressBar component.
|
|
756
|
+
*
|
|
757
|
+
* Two phases:
|
|
758
|
+
* 1. Fast phase (0–90%): random jumps of 1–5% at randomized intervals,
|
|
759
|
+
* paced to reach ~90% in roughly estimatedTimeSec seconds.
|
|
760
|
+
* 2. Slow phase (90–99%): crawls 1% at a time with longer random delays,
|
|
761
|
+
* never reaching 100% on its own.
|
|
762
|
+
*
|
|
763
|
+
* When isFinished becomes true, the bar immediately jumps to 100%.
|
|
764
|
+
* @author Yuen Ler Chow
|
|
765
|
+
*/
|
|
766
|
+
|
|
767
|
+
type Props = {
|
|
768
|
+
isFinished?: boolean;
|
|
769
|
+
estimatedTimeSec?: number;
|
|
770
|
+
striped?: boolean;
|
|
771
|
+
variant?: Variant;
|
|
772
|
+
bgVariant?: Variant;
|
|
773
|
+
showOutline?: boolean;
|
|
774
|
+
size?: ProgressBarSize;
|
|
775
|
+
};
|
|
776
|
+
declare const FakeProgressBar: React$1.FC<Props>;
|
|
752
777
|
|
|
753
778
|
/**
|
|
754
779
|
* Dynamic words determined by the user's platform
|
|
@@ -916,4 +941,4 @@ declare const useForceRender: (useReducer: any) => () => void;
|
|
|
916
941
|
*/
|
|
917
942
|
declare const isSelectAdmin: () => Promise<boolean>;
|
|
918
943
|
|
|
919
|
-
export { AppWrapper, AutoscrollToBottomContainer, ButtonInputGroup, CSVDownloadButton, CheckboxButton, CopiableBox, DBEntry, DBEntryField, DBEntryFieldType, DBEntryManagerPanel, Drawer, Dropdown, DropdownItemType, DynamicWord, ErrorBox, IntelliTable, IntelliTableColumn, ItemPicker, LoadingSpinner, LogReviewer, Modal, ModalButtonType, ModalSize, ModalType, MultiSwitch, PickableItem, PopFailureMark, PopPendingMark, PopSuccessMark, ProgressBar, ProgressBarSize, RadioButton, SimpleDateChooser, SimpleTimeChooser, TabBox, ToggleSwitch, Tooltip, Variant, addFatalErrorHandler, alert, canReviewLogs, combineClassNames, confirm, initClient, isMobileOrTablet, isSelectAdmin, leaveToURL, logClientEvent, makeLinksClickable, prompt, setClientEventMetadataPopulator, showFatalError, stubServerEndpoint, useForceRender, visitServerEndpoint };
|
|
944
|
+
export { AppWrapper, AutoscrollToBottomContainer, ButtonInputGroup, CSVDownloadButton, CheckboxButton, CopiableBox, DBEntry, DBEntryField, DBEntryFieldType, DBEntryManagerPanel, Drawer, Dropdown, DropdownItemType, DynamicWord, ErrorBox, FakeProgressBar, IntelliTable, IntelliTableColumn, ItemPicker, LoadingSpinner, LogReviewer, Modal, ModalButtonType, ModalSize, ModalType, MultiSwitch, PickableItem, PopFailureMark, PopPendingMark, PopSuccessMark, ProgressBar, ProgressBarSize, RadioButton, SimpleDateChooser, SimpleTimeChooser, TabBox, ToggleSwitch, Tooltip, Variant, addFatalErrorHandler, alert, canReviewLogs, combineClassNames, confirm, initClient, isMobileOrTablet, isSelectAdmin, leaveToURL, logClientEvent, makeLinksClickable, prompt, setClientEventMetadataPopulator, showFatalError, stubServerEndpoint, useForceRender, visitServerEndpoint };
|