@iress-oss/ids-mcp-server 0.0.1-dev.2 → 0.0.1-dev.4

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.
@@ -54,104 +54,7 @@ Page Size:
54
54
 
55
55
  Page 1 of 1
56
56
 
57
- Hide code
58
-
59
- \[data-radix-scroll-area-viewport\] { scrollbar-width: none; -ms-overflow-style: none; -webkit-overflow-scrolling: touch; } \[data-radix-scroll-area-viewport\]::-webkit-scrollbar { display: none; } :where(\[data-radix-scroll-area-viewport\]) { display: flex; flex-direction: column; align-items: stretch; } :where(\[data-radix-scroll-area-content\]) { flex-grow: 1; }
60
-
61
- import { useState } from 'react';
62
- import {
63
- IressButton,
64
- IressModal,
65
- IressText,
66
- IressToasterProvider,
67
- useToaster,
68
- } from '@iress-oss/ids-components';
69
- import { AG\_THEME\_IRESS\_ICONS, IressAgGridContainer } from '@iress/ids-themes';
70
- import { AgGridReact, AgGridReactProps } from 'ag-grid-react';
71
- import { AllCommunityModule, ModuleRegistry, provideGlobalGridOptions, type ColDef, type ICellRendererParams } from 'ag-grid-community';
72
- import styles from '@iress-storybook/styles.module.scss';
73
- ModuleRegistry.registerModules(\[AllCommunityModule\]);
74
- provideGlobalGridOptions({ theme: 'legacy' });
75
- const OrderCar \= ({ data }: ICellRendererParams) \=> {
76
- const \[show, setShow\] \= useState(false);
77
- const { success } \= useToaster();
78
- return (
79
- <\>
80
- <IressButton onClick\={() \=> setShow(true)}\>Order</IressButton\>
81
- <IressModal show\={show} onShowChange\={setShow}\>
82
- <IressText\>
83
- <h2\>Order a car</h2\>
84
- <p\>
85
- Car: {data.make} {data.model}
86
- </p\>
87
- <p\>
88
- <IressButton
89
- onClick\={() \=> {
90
- success({
91
- children: 'Order submitted',
92
- });
93
- setShow(false);
94
- }}
95
- \>
96
- Submit </IressButton\>
97
- </p\>
98
- </IressText\>
99
- </IressModal\>
100
- </\>
101
- );
102
- };
103
- export const AgGridSimple \= (args: AgGridReactProps) \=> {
104
- // Row Data: The data to be displayed.
105
- const \[rowData\] \= useState(\[
106
- { make: 'Tesla', model: 'Model Y', price: 64950, electric: true },
107
- { make: 'Ford', model: 'F-Series', price: 33850, electric: false },
108
- { make: 'Toyota', model: 'Corolla', price: 29600, electric: false },
109
- \]);
110
- // Column Definitions: Defines the columns to be displayed.
111
- const \[colDefs\] \= useState<ColDef\[\]\>(\[
112
- {
113
- field: 'make',
114
- filter: true,
115
- floatingFilter: true,
116
- flex: 2,
117
- checkboxSelection: true,
118
- },
119
- { field: 'model', flex: 1, autoHeight: true },
120
- {
121
- field: 'price',
122
- flex: 1,
123
- autoHeight: true,
124
- valueFormatter: (price) \=> \`$${price.value.toLocaleString()}\`,
125
- },
126
- { field: 'electric', flex: 1, editable: true, autoHeight: true },
127
- { field: 'order', flex: 1, cellRenderer: OrderCar },
128
- \]);
129
- return (
130
- <IressToasterProvider\>
131
- <IressAgGridContainer
132
- alignMiddle
133
- style\={{ height: '300px' }}
134
- \>
135
- <AgGridReact
136
- {...args}
137
- rowData\={rowData}
138
- rowClassRules\={{
139
- \[styles.highlightDanger\]: (params) \=> params.data.make \=== 'Toyota',
140
- }}
141
- rowSelection\="multiple"
142
- columnDefs\={colDefs}
143
- icons\={AG\_THEME\_IRESS\_ICONS}
144
- pagination
145
- paginationPageSize\={500}
146
- paginationPageSizeSelector\={\[200, 500, 1000\]}
147
- />
148
- </IressAgGridContainer\>
149
- </IressToasterProvider\>
150
- );
151
- };
152
- export default AgGridSimple;
153
-
154
- Copy
57
+ Show code
155
58
 
156
59
  [](#props-api)Props (API)
157
60
  -------------------------
@@ -254,104 +157,7 @@ Page Size:
254
157
 
255
158
  Page 1 of 1
256
159
 
257
- Hide code
258
-
259
- \[data-radix-scroll-area-viewport\] { scrollbar-width: none; -ms-overflow-style: none; -webkit-overflow-scrolling: touch; } \[data-radix-scroll-area-viewport\]::-webkit-scrollbar { display: none; } :where(\[data-radix-scroll-area-viewport\]) { display: flex; flex-direction: column; align-items: stretch; } :where(\[data-radix-scroll-area-content\]) { flex-grow: 1; }
260
-
261
- import { useState } from 'react';
262
- import {
263
- IressButton,
264
- IressModal,
265
- IressText,
266
- IressToasterProvider,
267
- useToaster,
268
- } from '@iress-oss/ids-components';
269
- import { AG\_THEME\_IRESS\_ICONS, IressAgGridContainer } from '@iress/ids-themes';
270
- import { AgGridReact, AgGridReactProps } from 'ag-grid-react';
271
- import { AllCommunityModule, ModuleRegistry, provideGlobalGridOptions, type ColDef, type ICellRendererParams } from 'ag-grid-community';
272
- import styles from '@iress-storybook/styles.module.scss';
273
- ModuleRegistry.registerModules(\[AllCommunityModule\]);
274
- provideGlobalGridOptions({ theme: 'legacy' });
275
- const OrderCar \= ({ data }: ICellRendererParams) \=> {
276
- const \[show, setShow\] \= useState(false);
277
- const { success } \= useToaster();
278
- return (
279
- <\>
280
- <IressButton onClick\={() \=> setShow(true)}\>Order</IressButton\>
281
- <IressModal show\={show} onShowChange\={setShow}\>
282
- <IressText\>
283
- <h2\>Order a car</h2\>
284
- <p\>
285
- Car: {data.make} {data.model}
286
- </p\>
287
- <p\>
288
- <IressButton
289
- onClick\={() \=> {
290
- success({
291
- children: 'Order submitted',
292
- });
293
- setShow(false);
294
- }}
295
- \>
296
- Submit </IressButton\>
297
- </p\>
298
- </IressText\>
299
- </IressModal\>
300
- </\>
301
- );
302
- };
303
- export const AgGridSimple \= (args: AgGridReactProps) \=> {
304
- // Row Data: The data to be displayed.
305
- const \[rowData\] \= useState(\[
306
- { make: 'Tesla', model: 'Model Y', price: 64950, electric: true },
307
- { make: 'Ford', model: 'F-Series', price: 33850, electric: false },
308
- { make: 'Toyota', model: 'Corolla', price: 29600, electric: false },
309
- \]);
310
- // Column Definitions: Defines the columns to be displayed.
311
- const \[colDefs\] \= useState<ColDef\[\]\>(\[
312
- {
313
- field: 'make',
314
- filter: true,
315
- floatingFilter: true,
316
- flex: 2,
317
- checkboxSelection: true,
318
- },
319
- { field: 'model', flex: 1, autoHeight: true },
320
- {
321
- field: 'price',
322
- flex: 1,
323
- autoHeight: true,
324
- valueFormatter: (price) \=> \`$${price.value.toLocaleString()}\`,
325
- },
326
- { field: 'electric', flex: 1, editable: true, autoHeight: true },
327
- { field: 'order', flex: 1, cellRenderer: OrderCar },
328
- \]);
329
- return (
330
- <IressToasterProvider\>
331
- <IressAgGridContainer
332
- alignMiddle
333
- style\={{ height: '300px' }}
334
- \>
335
- <AgGridReact
336
- {...args}
337
- rowData\={rowData}
338
- rowClassRules\={{
339
- \[styles.highlightDanger\]: (params) \=> params.data.make \=== 'Toyota',
340
- }}
341
- rowSelection\="multiple"
342
- columnDefs\={colDefs}
343
- icons\={AG\_THEME\_IRESS\_ICONS}
344
- pagination
345
- paginationPageSize\={500}
346
- paginationPageSizeSelector\={\[200, 500, 1000\]}
347
- />
348
- </IressAgGridContainer\>
349
- </IressToasterProvider\>
350
- );
351
- };
352
- export default AgGridSimple;
353
-
354
- Copy
160
+ Show code
355
161
 
356
162
  ### [](#complex)Complex
357
163
 
@@ -385,9 +191,9 @@ Country
385
191
 
386
192
  Shellie
387
193
 
388
- 49,446
194
+ 55,893
389
195
 
390
- \-£627.30
196
+ \-£500.66
391
197
 
392
198
  aliquet@purus.com
393
199
 
@@ -397,9 +203,9 @@ French Polynesia
397
203
 
398
204
  Jade
399
205
 
400
- 78,893
206
+ 70,139
401
207
 
402
- \-£906.36
208
+ £433.86
403
209
 
404
210
  mi.pede.nonummy@senectus.org
405
211
 
@@ -409,9 +215,9 @@ Tonga
409
215
 
410
216
  Wyoming
411
217
 
412
- 8,882
218
+ 21,497
413
219
 
414
- £55.76
220
+ £353.82
415
221
 
416
222
  Nulla.tempor.augue@aliquamiaculis.org
417
223
 
@@ -421,9 +227,9 @@ Rwanda
421
227
 
422
228
  Christine
423
229
 
424
- 69,518
230
+ 97,687
425
231
 
426
- £125.04
232
+ £119.40
427
233
 
428
234
  neque.sed.dictum@ultricesVivamus.ca
429
235
 
@@ -433,9 +239,9 @@ Bahamas
433
239
 
434
240
  Jameson
435
241
 
436
- 4,238
242
+ 87,554
437
243
 
438
- £170.98
244
+ \-£634.67
439
245
 
440
246
  sem.semper@liberoProin.com
441
247
 
@@ -445,9 +251,9 @@ Nauru
445
251
 
446
252
  Driscoll
447
253
 
448
- 21,692
254
+ 45,610
449
255
 
450
- \-£594.06
256
+ £338.76
451
257
 
452
258
  libero.dui@estacfacilisis.edu
453
259
 
@@ -457,9 +263,9 @@ Tajikistan
457
263
 
458
264
  Morgan
459
265
 
460
- 79,436
266
+ 14,480
461
267
 
462
- £115.01
268
+ £477.15
463
269
 
464
270
  mauris.eu@ipsum.ca
465
271
 
@@ -469,9 +275,9 @@ Colombia
469
275
 
470
276
  Kylee
471
277
 
472
- 62,388
278
+ 91,901
473
279
 
474
- £437.11
280
+ £470.74
475
281
 
476
282
  libero.Proin@malesuadafamesac.com
477
283
 
@@ -481,9 +287,9 @@ Papua New Guinea
481
287
 
482
288
  Cathleen
483
289
 
484
- 29,723
290
+ 76,234
485
291
 
486
- \-£540.19
292
+ \-£705.99
487
293
 
488
294
  risus.Donec@augue.edu
489
295
 
@@ -493,9 +299,9 @@ Guinea-Bissau
493
299
 
494
300
  Sierra
495
301
 
496
- 95,017
302
+ 70,719
497
303
 
498
- \-£742.40
304
+ £117.34
499
305
 
500
306
  dictum.eleifend.nunc@tellus.net
501
307
 
@@ -505,9 +311,9 @@ Isle of Man
505
311
 
506
312
  Levi
507
313
 
508
- 66,937
314
+ 7,491
509
315
 
510
- £87.91
316
+ \-£945.21
511
317
 
512
318
  Nulla.tempor.augue@nibhdolor.ca
513
319
 
@@ -517,9 +323,9 @@ Tuvalu
517
323
 
518
324
  Kyle
519
325
 
520
- 2,510
326
+ 79,958
521
327
 
522
- £454.30
328
+ \-£890.17
523
329
 
524
330
  lacinia@senectus.org
525
331
 
@@ -529,9 +335,9 @@ Qatar
529
335
 
530
336
  Emery
531
337
 
532
- 42,677
338
+ 90,476
533
339
 
534
- \-£869.12
340
+ £166.33
535
341
 
536
342
  Nulla.facilisis@nonummyultriciesornare.co.uk
537
343
 
@@ -541,9 +347,9 @@ Belize
541
347
 
542
348
  Nadine
543
349
 
544
- 84,276
350
+ 50,708
545
351
 
546
- \-£724.56
352
+ £212.92
547
353
 
548
354
  Duis@Sed.ca
549
355
 
@@ -553,9 +359,9 @@ Uruguay
553
359
 
554
360
  Dalton
555
361
 
556
- 66,926
362
+ 86,981
557
363
 
558
- \-£779.42
364
+ \-£748.63
559
365
 
560
366
  nibh.dolor.nonummy@laoreetlibero.org
561
367
 
@@ -565,9 +371,9 @@ Cayman Islands
565
371
 
566
372
  Zeph
567
373
 
568
- 51,688
374
+ 57,495
569
375
 
570
- \-£639.95
376
+ \-£619.75
571
377
 
572
378
  non.dui@felisorci.com
573
379
 
@@ -577,9 +383,9 @@ Niger
577
383
 
578
384
  Shannon
579
385
 
580
- 12,040
386
+ 59,268
581
387
 
582
- \-£778.18
388
+ \-£566.59
583
389
 
584
390
  leo@lobortis.co.uk
585
391
 
@@ -589,9 +395,9 @@ Somalia
589
395
 
590
396
  Erich
591
397
 
592
- 69,877
398
+ 24,529
593
399
 
594
- \-£610.68
400
+ \-£977.18
595
401
 
596
402
  cursus.non.egestas@aliquet.org
597
403
 
@@ -601,9 +407,9 @@ Sao Tome and Principe
601
407
 
602
408
  Rhiannon
603
409
 
604
- 8,184
410
+ 92,499
605
411
 
606
- £459.01
412
+ \-£932.96
607
413
 
608
414
  arcu.Morbi.sit@cursus.edu
609
415
 
@@ -613,9 +419,9 @@ Croatia
613
419
 
614
420
  Elijah
615
421
 
616
- 80,582
422
+ 20,589
617
423
 
618
- \-£845.80
424
+ £276.69
619
425
 
620
426
  ipsum.Donec.sollicitudin@leo.co.uk
621
427
 
@@ -625,9 +431,9 @@ San Marino
625
431
 
626
432
  Grady
627
433
 
628
- 20,501
434
+ 59,496
629
435
 
630
- £488.20
436
+ 0.00
631
437
 
632
438
  mollis.nec.cursus@malesuadamalesuadaInteger.edu
633
439
 
@@ -637,9 +443,9 @@ Cuba
637
443
 
638
444
  Quentin
639
445
 
640
- 33,800
446
+ 74,931
641
447
 
642
- \-£948.93
448
+ \-£910.76
643
449
 
644
450
  erat.vel@auctor.net
645
451
 
@@ -649,9 +455,9 @@ Mayotte
649
455
 
650
456
  Samuel
651
457
 
652
- 64,503
458
+ 55,034
653
459
 
654
- £142.21
460
+ \-£645.15
655
461
 
656
462
  tellus@magnaSed.edu
657
463
 
@@ -661,9 +467,9 @@ Lebanon
661
467
 
662
468
  Merritt
663
469
 
664
- 8,725
470
+ 31,896
665
471
 
666
- \-£572.96
472
+ \-£808.31
667
473
 
668
474
  interdum.Nunc.sollicitudin@elitpellentesque.edu
669
475
 
@@ -763,703 +569,7 @@ to of
763
569
 
764
570
  Page of
765
571
 
766
- Hide code
767
-
768
- \[data-radix-scroll-area-viewport\] { scrollbar-width: none; -ms-overflow-style: none; -webkit-overflow-scrolling: touch; } \[data-radix-scroll-area-viewport\]::-webkit-scrollbar { display: none; } :where(\[data-radix-scroll-area-viewport\]) { display: flex; flex-direction: column; align-items: stretch; } :where(\[data-radix-scroll-area-content\]) { flex-grow: 1; }
769
-
770
- import { useCallback, useEffect, useRef, useState } from 'react';
771
- import { AG\_GRID\_LICENSE\_KEY } from '@iress/ag-grid-license-key';
772
- import type {
773
- GridApi,
774
- GridReadyEvent,
775
- ValueFormatterParams,
776
- } from 'ag-grid-community';
777
- import { AgGridReact, AgGridReactProps } from 'ag-grid-react';
778
- import { AllEnterpriseModule, LicenseManager, ModuleRegistry, provideGlobalGridOptions } from 'ag-grid-enterprise';
779
- import { AG\_THEME\_IRESS\_ICONS, IressAgGridContainer } from '@iress/ids-themes';
780
- import styles from '@iress-storybook/styles.module.scss';
781
- LicenseManager.setLicenseKey(AG\_GRID\_LICENSE\_KEY);
782
- ModuleRegistry.registerModules(\[AllEnterpriseModule\]);
783
- provideGlobalGridOptions({ theme: 'legacy' });
784
- const formatter2dp \= new Intl.NumberFormat('en-UK', {
785
- minimumFractionDigits: 2,
786
- maximumFractionDigits: 2,
787
- });
788
- const formatterCurrency \= new Intl.NumberFormat('en-UK', {
789
- minimumFractionDigits: 2,
790
- maximumFractionDigits: 2,
791
- currencySign: 'standard',
792
- currency: 'GBP',
793
- style: 'currency',
794
- });
795
- const getSales \= (number: number) \=> {
796
- const no \= number \* 100000;
797
- return Math.ceil(no);
798
- };
799
- const getProfit \= (number: number) \=> {
800
- const no \= number \> 0.5 ? number \* \-1000 : number \* 1000;
801
- return formatter2dp.format(no);
802
- };
803
- const getRating \= () \=> (Math.random() \> 0.5 ? 'red' : 'green');
804
- const BIG\_DATA \= \[
805
- {
806
- firstName: 'Shellie',
807
- lastName: 'Cantu',
808
- email: 'aliquet@purus.com',
809
- phoneNo: '0828 746 6831',
810
- street: '639-9644 Eget Street',
811
- city: 'Weißenfels',
812
- postcode: '37962',
813
- country: 'French Polynesia',
814
- personalID: '16011210 9582',
815
- },
816
- {
817
- firstName: 'Jade',
818
- lastName: 'Sellers',
819
- email: 'mi.pede.nonummy@senectus.org',
820
- phoneNo: '0800 360062',
821
- street: 'P.O. Box 511, 3099 In Rd.',
822
- city: 'Cochrane',
823
- postcode: 'K8I 3RB',
824
- country: 'Tonga',
825
- personalID: '16870328 2056',
826
- },
827
- {
828
- firstName: 'Wyoming',
829
- lastName: 'Fox',
830
- email: 'Nulla.tempor.augue@aliquamiaculis.org',
831
- phoneNo: '0800 377 7753',
832
- street: '7354 Ac Ave',
833
- city: 'East Kilbride',
834
- postcode: '233010',
835
- country: 'Rwanda',
836
- personalID: '16070816 5048',
837
- },
838
- {
839
- firstName: 'Christine',
840
- lastName: 'Holcomb',
841
- email: 'neque.sed.dictum@ultricesVivamus.ca',
842
- phoneNo: '07578 190673',
843
- street: 'Ap #121-4421 Iaculis Av.',
844
- city: 'Etroubles',
845
- postcode: '6742',
846
- country: 'Bahamas',
847
- personalID: '16401211 0773',
848
- },
849
- {
850
- firstName: 'Jameson',
851
- lastName: 'Sutton',
852
- email: 'sem.semper@liberoProin.com',
853
- phoneNo: '07489 442639',
854
- street: 'Ap #700-1481 Porttitor Ave',
855
- city: 'Nice',
856
- postcode: '14655',
857
- country: 'Nauru',
858
- personalID: '16301129 4323',
859
- },
860
- {
861
- firstName: 'Driscoll',
862
- lastName: 'Jenkins',
863
- email: 'libero.dui@estacfacilisis.edu',
864
- phoneNo: '0843 298 8205',
865
- street: 'Ap #775-8090 Sed Avenue',
866
- city: 'Natales',
867
- postcode: '622109',
868
- country: 'Tajikistan',
869
- personalID: '16430908 1950',
870
- },
871
- {
872
- firstName: 'Morgan',
873
- lastName: 'Hutchinson',
874
- email: 'mauris.eu@ipsum.ca',
875
- phoneNo: '070 6292 4498',
876
- street: '3135 Curabitur Rd.',
877
- city: 'Darmstadt',
878
- postcode: '010900',
879
- country: 'Colombia',
880
- personalID: '16890811 2991',
881
- },
882
- {
883
- firstName: 'Kylee',
884
- lastName: 'Riddle',
885
- email: 'libero.Proin@malesuadafamesac.com',
886
- phoneNo: '(017177) 84788',
887
- street: '7336 Ipsum St.',
888
- city: 'Semarang',
889
- postcode: '9828',
890
- country: 'Papua New Guinea',
891
- personalID: '16260701 0093',
892
- },
893
- {
894
- firstName: 'Cathleen',
895
- lastName: 'Dale',
896
- email: 'risus.Donec@augue.edu',
897
- phoneNo: '(0115) 224 4142',
898
- street: 'Ap #568-2948 Fringilla Rd.',
899
- city: 'Brandenburg',
900
- postcode: 'CH2L 4EH',
901
- country: 'Guinea-Bissau',
902
- personalID: '16161203 4817',
903
- },
904
- {
905
- firstName: 'Sierra',
906
- lastName: 'Robbins',
907
- email: 'dictum.eleifend.nunc@tellus.net',
908
- phoneNo: '(01266) 957950',
909
- street: '481-6201 Mattis. Rd.',
910
- city: 'Upper Hutt',
911
- postcode: '23945',
912
- country: 'Isle of Man',
913
- personalID: '16691217 6010',
914
- },
915
- {
916
- firstName: 'Levi',
917
- lastName: 'Simpson',
918
- email: 'Nulla.tempor.augue@nibhdolor.ca',
919
- phoneNo: '0855 608 0347',
920
- street: '555-4187 Integer Av.',
921
- city: 'Curacaví',
922
- postcode: '439311',
923
- country: 'Tuvalu',
924
- personalID: '16000330 9499',
925
- },
926
- {
927
- firstName: 'Kyle',
928
- lastName: 'Mendez',
929
- email: 'lacinia@senectus.org',
930
- phoneNo: '0845 46 40',
931
- street: '814-4647 Nec, St.',
932
- city: 'Akron',
933
- postcode: '199413',
934
- country: 'Qatar',
935
- personalID: '16471029 5397',
936
- },
937
- {
938
- firstName: 'Emery',
939
- lastName: 'Hurley',
940
- email: 'Nulla.facilisis@nonummyultriciesornare.co.uk',
941
- phoneNo: '(01553) 502913',
942
- street: '4540 Luctus Ave',
943
- city: 'Meux',
944
- postcode: '36612',
945
- country: 'Belize',
946
- personalID: '16440228 3842',
947
- },
948
- {
949
- firstName: 'Nadine',
950
- lastName: 'Buchanan',
951
- email: 'Duis@Sed.ca',
952
- phoneNo: '055 2785 0228',
953
- street: '694 Mi, Av.',
954
- city: 'Middelburg',
955
- postcode: '62232-88887',
956
- country: 'Uruguay',
957
- personalID: '16721129 5857',
958
- },
959
- {
960
- firstName: 'Dalton',
961
- lastName: 'Nieves',
962
- email: 'nibh.dolor.nonummy@laoreetlibero.org',
963
- phoneNo: '0395 486 9374',
964
- street: '797-8170 Enim, Street',
965
- city: 'Burhanpur',
966
- postcode: '29633-93750',
967
- country: 'Cayman Islands',
968
- personalID: '16600205 0067',
969
- },
970
- {
971
- firstName: 'Zeph',
972
- lastName: 'Ruiz',
973
- email: 'non.dui@felisorci.com',
974
- phoneNo: '0845 46 41',
975
- street: 'Ap #282-8369 Malesuada Ave',
976
- city: 'Cavallino',
977
- postcode: 'EW2V 1ZE',
978
- country: 'Niger',
979
- personalID: '16580706 9124',
980
- },
981
- {
982
- firstName: 'Shannon',
983
- lastName: 'Decker',
984
- email: 'leo@lobortis.co.uk',
985
- phoneNo: '0800 135593',
986
- street: 'P.O. Box 587, 6871 Eleifend. Ave',
987
- city: 'Rocca San Felice',
988
- postcode: '42271-38735',
989
- country: 'Somalia',
990
- personalID: '16090810 4763',
991
- },
992
- {
993
- firstName: 'Erich',
994
- lastName: 'Daniels',
995
- email: 'cursus.non.egestas@aliquet.org',
996
- phoneNo: '0845 46 44',
997
- street: '689-4565 Velit. Avenue',
998
- city: 'Edmundston',
999
- postcode: 'JR32 7QA',
1000
- country: 'Sao Tome and Principe',
1001
- personalID: '16720401 5049',
1002
- },
1003
- {
1004
- firstName: 'Rhiannon',
1005
- lastName: 'Malone',
1006
- email: 'arcu.Morbi.sit@cursus.edu',
1007
- phoneNo: '0361 311 4051',
1008
- street: 'Ap #971-1781 Vehicula Road',
1009
- city: 'Wood Buffalo',
1010
- postcode: '71682',
1011
- country: 'Croatia',
1012
- personalID: '16931028 3388',
1013
- },
1014
- {
1015
- firstName: 'Elijah',
1016
- lastName: 'Sosa',
1017
- email: 'ipsum.Donec.sollicitudin@leo.co.uk',
1018
- phoneNo: '0800 365 8250',
1019
- street: 'P.O. Box 169, 2562 Commodo Ave',
1020
- city: 'Montoggio',
1021
- postcode: '42092',
1022
- country: 'San Marino',
1023
- personalID: '16251107 2403',
1024
- },
1025
- {
1026
- firstName: 'Grady',
1027
- lastName: 'Crosby',
1028
- email: 'mollis.nec.cursus@malesuadamalesuadaInteger.edu',
1029
- phoneNo: '070 2824 3427',
1030
- street: '821-5145 Id, Ave',
1031
- city: 'Rosoux-Crenwick',
1032
- postcode: '56176',
1033
- country: 'Cuba',
1034
- personalID: '16520115 9133',
1035
- },
1036
- {
1037
- firstName: 'Quentin',
1038
- lastName: 'Armstrong',
1039
- email: 'erat.vel@auctor.net',
1040
- phoneNo: '(029) 5052 0365',
1041
- street: '157-253 Hendrerit Av.',
1042
- city: 'Aubervilliers',
1043
- postcode: '2151',
1044
- country: 'Mayotte',
1045
- personalID: '16730607 0553',
1046
- },
1047
- {
1048
- firstName: 'Samuel',
1049
- lastName: 'Harrell',
1050
- email: 'tellus@magnaSed.edu',
1051
- phoneNo: '07064 102166',
1052
- street: 'P.O. Box 713, 4115 Ut Rd.',
1053
- city: 'Kingston',
1054
- postcode: '23315',
1055
- country: 'Lebanon',
1056
- personalID: '16361016 5551',
1057
- },
1058
- {
1059
- firstName: 'Merritt',
1060
- lastName: 'Holland',
1061
- email: 'interdum.Nunc.sollicitudin@elitpellentesque.edu',
1062
- phoneNo: '0800 825458',
1063
- street: 'P.O. Box 261, 3590 Nascetur Road',
1064
- city: 'Drancy',
1065
- postcode: '760017',
1066
- country: 'French Southern Territories',
1067
- personalID: '16040311 2121',
1068
- },
1069
- {
1070
- firstName: 'Harlan',
1071
- lastName: 'Brennan',
1072
- email: 'nascetur.ridiculus@feugiatmetussit.net',
1073
- phoneNo: '(012812) 59410',
1074
- street: '8210 Torquent Av.',
1075
- city: 'Grantham',
1076
- postcode: '01537',
1077
- country: 'Saint Pierre and Miquelon',
1078
- personalID: '16431216 0239',
1079
- },
1080
- {
1081
- firstName: 'Stuart',
1082
- lastName: 'Deleon',
1083
- email: 'sed.pede.nec@maurisMorbinon.com',
1084
- phoneNo: '0807 013 3815',
1085
- street: 'P.O. Box 143, 4909 At Street',
1086
- city: 'Terrance',
1087
- postcode: '27218',
1088
- country: 'Jersey',
1089
- personalID: '16330207 5852',
1090
- },
1091
- {
1092
- firstName: 'Clarke',
1093
- lastName: 'Middleton',
1094
- email: 'in@estacfacilisis.org',
1095
- phoneNo: '(028) 5013 9648',
1096
- street: '9856 Eget, Avenue',
1097
- city: 'Solihull',
1098
- postcode: '72893',
1099
- country: 'Seychelles',
1100
- personalID: '16340804 3325',
1101
- },
1102
- {
1103
- firstName: 'Roanna',
1104
- lastName: 'Gentry',
1105
- email: 'dui@nascetur.net',
1106
- phoneNo: '(024) 3023 2962',
1107
- street: '3566 Ornare. Rd.',
1108
- city: 'Freiberg',
1109
- postcode: '3899',
1110
- country: 'Lesotho',
1111
- personalID: '16680618 3791',
1112
- },
1113
- {
1114
- firstName: 'Delilah',
1115
- lastName: 'Bird',
1116
- email: 'laoreet.lectus.quis@utaliquam.edu',
1117
- phoneNo: '07160 224163',
1118
- street: 'P.O. Box 332, 8565 Molestie Avenue',
1119
- city: 'Washuk',
1120
- postcode: '607065',
1121
- country: 'Indonesia',
1122
- personalID: '16891112 9461',
1123
- },
1124
- {
1125
- firstName: 'Georgia',
1126
- lastName: 'Cash',
1127
- email: 'dui@enimnisl.net',
1128
- phoneNo: '(0113) 542 3955',
1129
- street: '900-3252 Fusce Avenue',
1130
- city: 'Sint-Michiels',
1131
- postcode: 'Z8203',
1132
- country: 'Niue',
1133
- personalID: '16340718 4716',
1134
- },
1135
- {
1136
- firstName: 'Aiko',
1137
- lastName: 'Mclean',
1138
- email: 'cubilia.Curae.Phasellus@augueid.com',
1139
- phoneNo: '055 9506 2116',
1140
- street: 'P.O. Box 786, 1756 Fringilla St.',
1141
- city: 'Malonne',
1142
- postcode: 'Y8E 7M2',
1143
- country: 'Belize',
1144
- personalID: '16680622 4207',
1145
- },
1146
- {
1147
- firstName: 'Winter',
1148
- lastName: 'Jacobs',
1149
- email: 'aliquet@Duisac.ca',
1150
- phoneNo: '0800 693847',
1151
- street: '774-9011 Arcu Road',
1152
- city: 'Bilbo',
1153
- postcode: '05558',
1154
- country: 'Equatorial Guinea',
1155
- personalID: '16611201 4144',
1156
- },
1157
- {
1158
- firstName: 'Jolene',
1159
- lastName: 'Rios',
1160
- email: 'odio.Aliquam.vulputate@ac.ca',
1161
- phoneNo: '(023) 4876 2215',
1162
- street: 'Ap #325-8225 Amet Road',
1163
- city: 'Limena',
1164
- postcode: 'K56 0YJ',
1165
- country: 'Morocco',
1166
- personalID: '16170215 3485',
1167
- },
1168
- {
1169
- firstName: 'Kaden',
1170
- lastName: 'Morrow',
1171
- email: 'rutrum@eleifendnec.ca',
1172
- phoneNo: '07305 685548',
1173
- street: '8870 Aliquam Road',
1174
- city: 'Sète',
1175
- postcode: '04908',
1176
- country: 'Peru',
1177
- personalID: '16820820 6675',
1178
- },
1179
- {
1180
- firstName: 'Kaseem',
1181
- lastName: 'Norris',
1182
- email: 'mauris.erat.eget@nequeMorbi.com',
1183
- phoneNo: '07275 403152',
1184
- street: 'P.O. Box 776, 7115 Integer Avenue',
1185
- city: 'Jönköping',
1186
- postcode: '42236-83471',
1187
- country: 'Sudan',
1188
- personalID: '16440829 7895',
1189
- },
1190
- {
1191
- firstName: 'Vladimir',
1192
- lastName: 'Mcguire',
1193
- email: 'id@nonarcuVivamus.edu',
1194
- phoneNo: '0500 950469',
1195
- street: '2067 Est Ave',
1196
- city: 'Ziano di Fiemme',
1197
- postcode: '774056',
1198
- country: 'Mexico',
1199
- personalID: '16771016 3796',
1200
- },
1201
- {
1202
- firstName: 'Jocelyn',
1203
- lastName: 'Schroeder',
1204
- email: 'dolor@nec.ca',
1205
- phoneNo: '07302 403156',
1206
- street: 'Ap #155-3999 Vivamus St.',
1207
- city: 'Malloa',
1208
- postcode: '4059',
1209
- country: 'Canada',
1210
- personalID: '16530314 9388',
1211
- },
1212
- {
1213
- firstName: 'Howard',
1214
- lastName: 'Villarreal',
1215
- email: 'Donec.felis@insodales.com',
1216
- phoneNo: '07624 830239',
1217
- street: '540-7057 Cras Rd.',
1218
- city: 'Siverek',
1219
- postcode: '8701',
1220
- country: 'Seychelles',
1221
- personalID: '16640823 8530',
1222
- },
1223
- {
1224
- firstName: 'Adam',
1225
- lastName: 'Miranda',
1226
- email: 'amet.dapibus@faucibus.edu',
1227
- phoneNo: '0845 46 49',
1228
- street: 'Ap #931-6286 Diam. Avenue',
1229
- city: 'Warburg',
1230
- postcode: '01972',
1231
- country: 'Jordan',
1232
- personalID: '16370414 7911',
1233
- },
1234
- {
1235
- firstName: 'Aiko',
1236
- lastName: 'Elliott',
1237
- email: 'sodales@mauris.edu',
1238
- phoneNo: '0800 1111',
1239
- street: 'P.O. Box 583, 6119 Ut St.',
1240
- city: 'Villavicencio',
1241
- postcode: '4864 XQ',
1242
- country: 'Faroe Islands',
1243
- personalID: '16940907 6115',
1244
- },
1245
- \].map((person) \=> ({
1246
- ...person,
1247
- sales: getSales(Math.random()),
1248
- profit: getProfit(Math.random()),
1249
- redOrGreen: getRating(),
1250
- date: new Date(Math.floor(Math.random() \* \-10000000000)).toDateString(),
1251
- }));
1252
- const createClassNameMutationObserver \= (
1253
- element: HTMLElement,
1254
- callback: (className: string) \=> void,
1255
- ): MutationObserver \=> {
1256
- const observer \= new MutationObserver(() \=> {
1257
- callback(element.className);
1258
- });
1259
- observer.observe(element, {
1260
- attributes: true,
1261
- attributeFilter: \['class'\],
1262
- childList: false,
1263
- characterData: false,
1264
- });
1265
- return observer;
1266
- };
1267
- const useClassNameMutationObserver \= (
1268
- element: HTMLElement,
1269
- callback: () \=> void,
1270
- ): void \=> {
1271
- useEffect(() \=> {
1272
- const observer \= createClassNameMutationObserver(element, callback);
1273
- // Cleanup listener
1274
- return (): void \=> {
1275
- observer.disconnect();
1276
- };
1277
- });
1278
- };
1279
- const RedOrGreenFormatter \= (params: ValueFormatterParams) \=> {
1280
- const dotStyle \= styles\[\`dot--${params.value}\`\];
1281
- return <span className\={\`${styles.dot} ${dotStyle}\`} />;
1282
- };
1283
- const CommaFormatter \= (params: ValueFormatterParams): string \=> {
1284
- return params.value.toString().replace(/\\B(?=(\\d{3})+(?!\\d))/g, ',');
1285
- };
1286
- const CurrencyFormatter \= (params: ValueFormatterParams): string \=> {
1287
- if (params.value \=== '0.00') {
1288
- return formatter2dp.format(params.value);
1289
- }
1290
- return formatterCurrency.format(params.value);
1291
- };
1292
- export const AgGridComplex \= (args: AgGridReactProps) \=> {
1293
- const \[rowData, setRowData\] \= useState(BIG\_DATA);
1294
- const api \= useRef<GridApi\>();
1295
- // pick one row at random to show data updating in the grid
1296
- useEffect(() \=> {
1297
- const updateTick \= setInterval(() \=> {
1298
- const randomNo \= Math.random();
1299
- const index \= Math.floor(Math.random() \* rowData.length);
1300
- const itemToUpdate \= rowData\[index\];
1301
- if (randomNo < 0.5) {
1302
- itemToUpdate.sales \= getSales(Math.random());
1303
- } else if (randomNo \> 0.9) {
1304
- itemToUpdate.profit \= getProfit(0);
1305
- } else {
1306
- itemToUpdate.profit \= getProfit(Math.random());
1307
- }
1308
- setRowData(rowData);
1309
- api.current?.refreshCells();
1310
- }, 500);
1311
- return () \=> {
1312
- clearInterval(updateTick);
1313
- };
1314
- }, \[rowData\]);
1315
- const onGridReady \= useCallback((event: GridReadyEvent): void \=> {
1316
- api.current \= event.api;
1317
- api.current.resetRowHeights();
1318
- }, \[\]);
1319
- useClassNameMutationObserver(document.documentElement, () \=> {
1320
- if (api.current) {
1321
- api.current.resetRowHeights();
1322
- }
1323
- });
1324
- return (
1325
- <IressAgGridContainer
1326
- alignMiddle
1327
- style\={{ height: '100vh', width: '100%' }}
1328
- \>
1329
- <AgGridReact {...args}
1330
- onGridReady={onGridReady}
1331
- rowDragManaged animateRows enableRangeSelection={true}
1332
- enableCharts={true}
1333
- sideBar={true}
1334
- rowData={rowData}
1335
- rowSelection="multiple" rowMultiSelectWithClick components={{
1336
- redGreenDots: RedOrGreenFormatter,
1337
- }}
1338
- defaultColDef={{
1339
- enableCellChangeFlash: true,
1340
- resizable: true,
1341
- sortable: true,
1342
- unSortIcon: true,
1343
- filter: true,
1344
- floatingFilter: true,
1345
- enablePivot: false,
1346
- filterParams: {
1347
- buttons: \['reset', 'apply'\],
1348
- },
1349
- autoHeight: true,
1350
- wrapText: true,
1351
- }}
1352
- icons={AG\_THEME\_IRESS\_ICONS}
1353
- columnDefs={\[
1354
- {
1355
- headerName: 'Employee',
1356
- children: \[
1357
- {
1358
- field: 'firstName',
1359
- editable: true,
1360
- filter: 'agTextColumnFilter',
1361
- headerTooltip: 'First name',
1362
- rowDrag: true,
1363
- lockVisible: true,
1364
- tooltipField: 'firstName',
1365
- },
1366
- {
1367
- field: 'lastName',
1368
- editable: true,
1369
- filter: 'agTextColumnFilter',
1370
- headerTooltip: 'Surname',
1371
- lockVisible: true,
1372
- cellClass: 'iress-cell--divider',
1373
- headerClass: 'iress-cell--divider',
1374
- columnGroupShow: 'open',
1375
- },
1376
- {
1377
- field: 'personalID',
1378
- filter: 'agTextColumnFilter',
1379
- headerTooltip: 'Personal ID',
1380
- columnGroupShow: 'open',
1381
- },
1382
- {
1383
- field: 'date',
1384
- filter: 'agDateColumnFilter',
1385
- headerTooltip: 'Date',
1386
- columnGroupShow: 'open',
1387
- },
1388
- \],
1389
- },
1390
- {
1391
- headerName: 'Sales performance',
1392
- children: \[
1393
- {
1394
- field: 'redOrGreen',
1395
- headerName: 'Rating',
1396
- cellRenderer: 'redGreenDots',
1397
- filter: false,
1398
- },
1399
- {
1400
- field: 'sales',
1401
- filter: 'agNumberColumnFilter',
1402
- valueFormatter: CommaFormatter,
1403
- },
1404
- {
1405
- field: 'profit',
1406
- valueFormatter: CurrencyFormatter,
1407
- cellClassRules: {
1408
- 'iress--positive': (params) \=> parseInt(params.value, 10) \> 0,
1409
- 'iress--negative': (params) \=> parseInt(params.value, 10) < 0,
1410
- 'iress--zero': (params) \=> params.value \=== '0.00',
1411
- },
1412
- },
1413
- \],
1414
- },
1415
- {
1416
- headerName: 'Contact details',
1417
- children: \[
1418
- {
1419
- field: 'email',
1420
- width: 350,
1421
- filter: 'agTextColumnFilter',
1422
- headerTooltip: 'Email address',
1423
- cellClass: 'iress-cell--ellipsis',
1424
- },
1425
- {
1426
- field: 'phoneNo',
1427
- enableValue: true,
1428
- filter: 'agTextColumnFilter',
1429
- headerTooltip: 'Phone number',
1430
- },
1431
- \],
1432
- },
1433
- {
1434
- headerName: 'Address',
1435
- children: \[
1436
- {
1437
- field: 'street',
1438
- width: 350,
1439
- filter: 'agTextColumnFilter',
1440
- cellClass: 'iress-cell--ellipsis',
1441
- columnGroupShow: 'open',
1442
- },
1443
- {
1444
- field: 'city',
1445
- filter: 'agTextColumnFilter',
1446
- columnGroupShow: 'open',
1447
- },
1448
- {
1449
- field: 'postcode',
1450
- filter: 'agTextColumnFilter',
1451
- columnGroupShow: 'open',
1452
- },
1453
- { field: 'country', filter: 'agTextColumnFilter' },
1454
- \],
1455
- },
1456
- \]}
1457
- /> </IressAgGridContainer\>
1458
- );
1459
- };
1460
- export default AgGridComplex;
1461
-
1462
- Copy
572
+ Show code
1463
573
 
1464
574
  ### [](#compact)Compact
1465
575
 
@@ -1493,9 +603,9 @@ Country
1493
603
 
1494
604
  Shellie
1495
605
 
1496
- 3,489
606
+ 17,972
1497
607
 
1498
- £21.68
608
+ \-£688.02
1499
609
 
1500
610
  aliquet@purus.com
1501
611
 
@@ -1505,9 +615,9 @@ French Polynesia
1505
615
 
1506
616
  Jade
1507
617
 
1508
- 12,963
618
+ 65,080
1509
619
 
1510
- £306.21
620
+ £152.28
1511
621
 
1512
622
  mi.pede.nonummy@senectus.org
1513
623
 
@@ -1517,9 +627,9 @@ Tonga
1517
627
 
1518
628
  Wyoming
1519
629
 
1520
- 23,715
630
+ 8,750
1521
631
 
1522
- \-£745.77
632
+ £10.93
1523
633
 
1524
634
  Nulla.tempor.augue@aliquamiaculis.org
1525
635
 
@@ -1529,9 +639,9 @@ Rwanda
1529
639
 
1530
640
  Christine
1531
641
 
1532
- 61,370
642
+ 16,278
1533
643
 
1534
- \-£662.81
644
+ \-£795.88
1535
645
 
1536
646
  neque.sed.dictum@ultricesVivamus.ca
1537
647
 
@@ -1541,9 +651,9 @@ Bahamas
1541
651
 
1542
652
  Jameson
1543
653
 
1544
- 95,958
654
+ 42,804
1545
655
 
1546
- \-£953.31
656
+ \-£972.10
1547
657
 
1548
658
  sem.semper@liberoProin.com
1549
659
 
@@ -1553,9 +663,9 @@ Nauru
1553
663
 
1554
664
  Driscoll
1555
665
 
1556
- 7,579
666
+ 11,266
1557
667
 
1558
- £268.43
668
+ \-£610.75
1559
669
 
1560
670
  libero.dui@estacfacilisis.edu
1561
671
 
@@ -1565,9 +675,9 @@ Tajikistan
1565
675
 
1566
676
  Morgan
1567
677
 
1568
- 41,229
678
+ 84,926
1569
679
 
1570
- £204.74
680
+ \-£653.18
1571
681
 
1572
682
  mauris.eu@ipsum.ca
1573
683
 
@@ -1577,9 +687,9 @@ Colombia
1577
687
 
1578
688
  Kylee
1579
689
 
1580
- 80,559
690
+ 5,227
1581
691
 
1582
- \-£698.67
692
+ 0.00
1583
693
 
1584
694
  libero.Proin@malesuadafamesac.com
1585
695
 
@@ -1589,9 +699,9 @@ Papua New Guinea
1589
699
 
1590
700
  Cathleen
1591
701
 
1592
- 85,185
702
+ 11,127
1593
703
 
1594
- \-£927.22
704
+ \-£931.98
1595
705
 
1596
706
  risus.Donec@augue.edu
1597
707
 
@@ -1601,9 +711,9 @@ Guinea-Bissau
1601
711
 
1602
712
  Sierra
1603
713
 
1604
- 43,903
714
+ 68,369
1605
715
 
1606
- £287.01
716
+ \-£686.59
1607
717
 
1608
718
  dictum.eleifend.nunc@tellus.net
1609
719
 
@@ -1613,9 +723,9 @@ Isle of Man
1613
723
 
1614
724
  Levi
1615
725
 
1616
- 27,410
726
+ 56,491
1617
727
 
1618
- \-£598.32
728
+ \-£897.31
1619
729
 
1620
730
  Nulla.tempor.augue@nibhdolor.ca
1621
731
 
@@ -1625,9 +735,9 @@ Tuvalu
1625
735
 
1626
736
  Kyle
1627
737
 
1628
- 59,394
738
+ 4,929
1629
739
 
1630
- £19.79
740
+ \-£537.12
1631
741
 
1632
742
  lacinia@senectus.org
1633
743
 
@@ -1637,9 +747,9 @@ Qatar
1637
747
 
1638
748
  Emery
1639
749
 
1640
- 69,852
750
+ 25,854
1641
751
 
1642
- \-£784.52
752
+ £87.24
1643
753
 
1644
754
  Nulla.facilisis@nonummyultriciesornare.co.uk
1645
755
 
@@ -1649,9 +759,9 @@ Belize
1649
759
 
1650
760
  Nadine
1651
761
 
1652
- 9,884
762
+ 9,152
1653
763
 
1654
- £97.94
764
+ \-£973.34
1655
765
 
1656
766
  Duis@Sed.ca
1657
767
 
@@ -1661,9 +771,9 @@ Uruguay
1661
771
 
1662
772
  Dalton
1663
773
 
1664
- 60,037
774
+ 52,780
1665
775
 
1666
- £429.75
776
+ £353.64
1667
777
 
1668
778
  nibh.dolor.nonummy@laoreetlibero.org
1669
779
 
@@ -1673,9 +783,9 @@ Cayman Islands
1673
783
 
1674
784
  Zeph
1675
785
 
1676
- 61,632
786
+ 44,588
1677
787
 
1678
- £256.51
788
+ \-£709.00
1679
789
 
1680
790
  non.dui@felisorci.com
1681
791
 
@@ -1685,9 +795,9 @@ Niger
1685
795
 
1686
796
  Shannon
1687
797
 
1688
- 6,613
798
+ 54,700
1689
799
 
1690
- £57.82
800
+ £151.31
1691
801
 
1692
802
  leo@lobortis.co.uk
1693
803
 
@@ -1697,9 +807,9 @@ Somalia
1697
807
 
1698
808
  Erich
1699
809
 
1700
- 34,643
810
+ 31,612
1701
811
 
1702
- 0.00
812
+ \-£557.04
1703
813
 
1704
814
  cursus.non.egestas@aliquet.org
1705
815
 
@@ -1709,9 +819,9 @@ Sao Tome and Principe
1709
819
 
1710
820
  Rhiannon
1711
821
 
1712
- 57,478
822
+ 69,501
1713
823
 
1714
- £125.61
824
+ £116.64
1715
825
 
1716
826
  arcu.Morbi.sit@cursus.edu
1717
827
 
@@ -1721,9 +831,9 @@ Croatia
1721
831
 
1722
832
  Elijah
1723
833
 
1724
- 8,032
834
+ 32,390
1725
835
 
1726
- \-£936.24
836
+ £115.44
1727
837
 
1728
838
  ipsum.Donec.sollicitudin@leo.co.uk
1729
839
 
@@ -1733,9 +843,9 @@ San Marino
1733
843
 
1734
844
  Grady
1735
845
 
1736
- 27,873
846
+ 53,408
1737
847
 
1738
- £474.66
848
+ £82.94
1739
849
 
1740
850
  mollis.nec.cursus@malesuadamalesuadaInteger.edu
1741
851
 
@@ -1745,9 +855,9 @@ Cuba
1745
855
 
1746
856
  Quentin
1747
857
 
1748
- 56,391
858
+ 62,717
1749
859
 
1750
- \-£879.89
860
+ \-£830.80
1751
861
 
1752
862
  erat.vel@auctor.net
1753
863
 
@@ -1757,9 +867,9 @@ Mayotte
1757
867
 
1758
868
  Samuel
1759
869
 
1760
- 76,919
870
+ 65,380
1761
871
 
1762
- £431.98
872
+ \-£799.63
1763
873
 
1764
874
  tellus@magnaSed.edu
1765
875
 
@@ -1769,9 +879,9 @@ Lebanon
1769
879
 
1770
880
  Merritt
1771
881
 
1772
- 53,310
882
+ 10,433
1773
883
 
1774
- £103.21
884
+ \-£505.97
1775
885
 
1776
886
  interdum.Nunc.sollicitudin@elitpellentesque.edu
1777
887
 
@@ -1781,9 +891,9 @@ French Southern Territories
1781
891
 
1782
892
  Harlan
1783
893
 
1784
- 88,270
894
+ 50,760
1785
895
 
1786
- £365.29
896
+ £295.19
1787
897
 
1788
898
  nascetur.ridiculus@feugiatmetussit.net
1789
899
 
@@ -1793,9 +903,9 @@ Saint Pierre and Miquelon
1793
903
 
1794
904
  Stuart
1795
905
 
1796
- 83,845
906
+ 60,138
1797
907
 
1798
- £465.92
908
+ \-£863.95
1799
909
 
1800
910
  sed.pede.nec@maurisMorbinon.com
1801
911
 
@@ -1899,709 +1009,7 @@ to of
1899
1009
 
1900
1010
  Page of
1901
1011
 
1902
- Hide code
1903
-
1904
- \[data-radix-scroll-area-viewport\] { scrollbar-width: none; -ms-overflow-style: none; -webkit-overflow-scrolling: touch; } \[data-radix-scroll-area-viewport\]::-webkit-scrollbar { display: none; } :where(\[data-radix-scroll-area-viewport\]) { display: flex; flex-direction: column; align-items: stretch; } :where(\[data-radix-scroll-area-content\]) { flex-grow: 1; }
1905
-
1906
- import { useCallback, useEffect, useRef, useState } from 'react';
1907
- import { AG\_GRID\_LICENSE\_KEY } from '@iress/ag-grid-license-key';
1908
- import type {
1909
- GridApi,
1910
- GridReadyEvent,
1911
- ValueFormatterParams,
1912
- } from 'ag-grid-community';
1913
- import { AgGridReact, AgGridReactProps } from 'ag-grid-react';
1914
- import {
1915
- AllEnterpriseModule,
1916
- LicenseManager,
1917
- ModuleRegistry,
1918
- provideGlobalGridOptions,
1919
- } from 'ag-grid-enterprise';
1920
- import { AG\_THEME\_IRESS\_ICONS, IressAgGridContainer } from '@iress/ids-themes';
1921
- import styles from '@iress-storybook/styles.module.scss';
1922
- LicenseManager.setLicenseKey(AG\_GRID\_LICENSE\_KEY);
1923
- ModuleRegistry.registerModules(\[AllEnterpriseModule\]);
1924
- provideGlobalGridOptions({ theme: 'legacy' });
1925
- const formatter2dp \= new Intl.NumberFormat('en-UK', {
1926
- minimumFractionDigits: 2,
1927
- maximumFractionDigits: 2,
1928
- });
1929
- const formatterCurrency \= new Intl.NumberFormat('en-UK', {
1930
- minimumFractionDigits: 2,
1931
- maximumFractionDigits: 2,
1932
- currencySign: 'standard',
1933
- currency: 'GBP',
1934
- style: 'currency',
1935
- });
1936
- const getSales \= (number: number) \=> {
1937
- const no \= number \* 100000;
1938
- return Math.ceil(no);
1939
- };
1940
- const getProfit \= (number: number) \=> {
1941
- const no \= number \> 0.5 ? number \* \-1000 : number \* 1000;
1942
- return formatter2dp.format(no);
1943
- };
1944
- const getRating \= () \=> (Math.random() \> 0.5 ? 'red' : 'green');
1945
- const BIG\_DATA \= \[
1946
- {
1947
- firstName: 'Shellie',
1948
- lastName: 'Cantu',
1949
- email: 'aliquet@purus.com',
1950
- phoneNo: '0828 746 6831',
1951
- street: '639-9644 Eget Street',
1952
- city: 'Weißenfels',
1953
- postcode: '37962',
1954
- country: 'French Polynesia',
1955
- personalID: '16011210 9582',
1956
- },
1957
- {
1958
- firstName: 'Jade',
1959
- lastName: 'Sellers',
1960
- email: 'mi.pede.nonummy@senectus.org',
1961
- phoneNo: '0800 360062',
1962
- street: 'P.O. Box 511, 3099 In Rd.',
1963
- city: 'Cochrane',
1964
- postcode: 'K8I 3RB',
1965
- country: 'Tonga',
1966
- personalID: '16870328 2056',
1967
- },
1968
- {
1969
- firstName: 'Wyoming',
1970
- lastName: 'Fox',
1971
- email: 'Nulla.tempor.augue@aliquamiaculis.org',
1972
- phoneNo: '0800 377 7753',
1973
- street: '7354 Ac Ave',
1974
- city: 'East Kilbride',
1975
- postcode: '233010',
1976
- country: 'Rwanda',
1977
- personalID: '16070816 5048',
1978
- },
1979
- {
1980
- firstName: 'Christine',
1981
- lastName: 'Holcomb',
1982
- email: 'neque.sed.dictum@ultricesVivamus.ca',
1983
- phoneNo: '07578 190673',
1984
- street: 'Ap #121-4421 Iaculis Av.',
1985
- city: 'Etroubles',
1986
- postcode: '6742',
1987
- country: 'Bahamas',
1988
- personalID: '16401211 0773',
1989
- },
1990
- {
1991
- firstName: 'Jameson',
1992
- lastName: 'Sutton',
1993
- email: 'sem.semper@liberoProin.com',
1994
- phoneNo: '07489 442639',
1995
- street: 'Ap #700-1481 Porttitor Ave',
1996
- city: 'Nice',
1997
- postcode: '14655',
1998
- country: 'Nauru',
1999
- personalID: '16301129 4323',
2000
- },
2001
- {
2002
- firstName: 'Driscoll',
2003
- lastName: 'Jenkins',
2004
- email: 'libero.dui@estacfacilisis.edu',
2005
- phoneNo: '0843 298 8205',
2006
- street: 'Ap #775-8090 Sed Avenue',
2007
- city: 'Natales',
2008
- postcode: '622109',
2009
- country: 'Tajikistan',
2010
- personalID: '16430908 1950',
2011
- },
2012
- {
2013
- firstName: 'Morgan',
2014
- lastName: 'Hutchinson',
2015
- email: 'mauris.eu@ipsum.ca',
2016
- phoneNo: '070 6292 4498',
2017
- street: '3135 Curabitur Rd.',
2018
- city: 'Darmstadt',
2019
- postcode: '010900',
2020
- country: 'Colombia',
2021
- personalID: '16890811 2991',
2022
- },
2023
- {
2024
- firstName: 'Kylee',
2025
- lastName: 'Riddle',
2026
- email: 'libero.Proin@malesuadafamesac.com',
2027
- phoneNo: '(017177) 84788',
2028
- street: '7336 Ipsum St.',
2029
- city: 'Semarang',
2030
- postcode: '9828',
2031
- country: 'Papua New Guinea',
2032
- personalID: '16260701 0093',
2033
- },
2034
- {
2035
- firstName: 'Cathleen',
2036
- lastName: 'Dale',
2037
- email: 'risus.Donec@augue.edu',
2038
- phoneNo: '(0115) 224 4142',
2039
- street: 'Ap #568-2948 Fringilla Rd.',
2040
- city: 'Brandenburg',
2041
- postcode: 'CH2L 4EH',
2042
- country: 'Guinea-Bissau',
2043
- personalID: '16161203 4817',
2044
- },
2045
- {
2046
- firstName: 'Sierra',
2047
- lastName: 'Robbins',
2048
- email: 'dictum.eleifend.nunc@tellus.net',
2049
- phoneNo: '(01266) 957950',
2050
- street: '481-6201 Mattis. Rd.',
2051
- city: 'Upper Hutt',
2052
- postcode: '23945',
2053
- country: 'Isle of Man',
2054
- personalID: '16691217 6010',
2055
- },
2056
- {
2057
- firstName: 'Levi',
2058
- lastName: 'Simpson',
2059
- email: 'Nulla.tempor.augue@nibhdolor.ca',
2060
- phoneNo: '0855 608 0347',
2061
- street: '555-4187 Integer Av.',
2062
- city: 'Curacaví',
2063
- postcode: '439311',
2064
- country: 'Tuvalu',
2065
- personalID: '16000330 9499',
2066
- },
2067
- {
2068
- firstName: 'Kyle',
2069
- lastName: 'Mendez',
2070
- email: 'lacinia@senectus.org',
2071
- phoneNo: '0845 46 40',
2072
- street: '814-4647 Nec, St.',
2073
- city: 'Akron',
2074
- postcode: '199413',
2075
- country: 'Qatar',
2076
- personalID: '16471029 5397',
2077
- },
2078
- {
2079
- firstName: 'Emery',
2080
- lastName: 'Hurley',
2081
- email: 'Nulla.facilisis@nonummyultriciesornare.co.uk',
2082
- phoneNo: '(01553) 502913',
2083
- street: '4540 Luctus Ave',
2084
- city: 'Meux',
2085
- postcode: '36612',
2086
- country: 'Belize',
2087
- personalID: '16440228 3842',
2088
- },
2089
- {
2090
- firstName: 'Nadine',
2091
- lastName: 'Buchanan',
2092
- email: 'Duis@Sed.ca',
2093
- phoneNo: '055 2785 0228',
2094
- street: '694 Mi, Av.',
2095
- city: 'Middelburg',
2096
- postcode: '62232-88887',
2097
- country: 'Uruguay',
2098
- personalID: '16721129 5857',
2099
- },
2100
- {
2101
- firstName: 'Dalton',
2102
- lastName: 'Nieves',
2103
- email: 'nibh.dolor.nonummy@laoreetlibero.org',
2104
- phoneNo: '0395 486 9374',
2105
- street: '797-8170 Enim, Street',
2106
- city: 'Burhanpur',
2107
- postcode: '29633-93750',
2108
- country: 'Cayman Islands',
2109
- personalID: '16600205 0067',
2110
- },
2111
- {
2112
- firstName: 'Zeph',
2113
- lastName: 'Ruiz',
2114
- email: 'non.dui@felisorci.com',
2115
- phoneNo: '0845 46 41',
2116
- street: 'Ap #282-8369 Malesuada Ave',
2117
- city: 'Cavallino',
2118
- postcode: 'EW2V 1ZE',
2119
- country: 'Niger',
2120
- personalID: '16580706 9124',
2121
- },
2122
- {
2123
- firstName: 'Shannon',
2124
- lastName: 'Decker',
2125
- email: 'leo@lobortis.co.uk',
2126
- phoneNo: '0800 135593',
2127
- street: 'P.O. Box 587, 6871 Eleifend. Ave',
2128
- city: 'Rocca San Felice',
2129
- postcode: '42271-38735',
2130
- country: 'Somalia',
2131
- personalID: '16090810 4763',
2132
- },
2133
- {
2134
- firstName: 'Erich',
2135
- lastName: 'Daniels',
2136
- email: 'cursus.non.egestas@aliquet.org',
2137
- phoneNo: '0845 46 44',
2138
- street: '689-4565 Velit. Avenue',
2139
- city: 'Edmundston',
2140
- postcode: 'JR32 7QA',
2141
- country: 'Sao Tome and Principe',
2142
- personalID: '16720401 5049',
2143
- },
2144
- {
2145
- firstName: 'Rhiannon',
2146
- lastName: 'Malone',
2147
- email: 'arcu.Morbi.sit@cursus.edu',
2148
- phoneNo: '0361 311 4051',
2149
- street: 'Ap #971-1781 Vehicula Road',
2150
- city: 'Wood Buffalo',
2151
- postcode: '71682',
2152
- country: 'Croatia',
2153
- personalID: '16931028 3388',
2154
- },
2155
- {
2156
- firstName: 'Elijah',
2157
- lastName: 'Sosa',
2158
- email: 'ipsum.Donec.sollicitudin@leo.co.uk',
2159
- phoneNo: '0800 365 8250',
2160
- street: 'P.O. Box 169, 2562 Commodo Ave',
2161
- city: 'Montoggio',
2162
- postcode: '42092',
2163
- country: 'San Marino',
2164
- personalID: '16251107 2403',
2165
- },
2166
- {
2167
- firstName: 'Grady',
2168
- lastName: 'Crosby',
2169
- email: 'mollis.nec.cursus@malesuadamalesuadaInteger.edu',
2170
- phoneNo: '070 2824 3427',
2171
- street: '821-5145 Id, Ave',
2172
- city: 'Rosoux-Crenwick',
2173
- postcode: '56176',
2174
- country: 'Cuba',
2175
- personalID: '16520115 9133',
2176
- },
2177
- {
2178
- firstName: 'Quentin',
2179
- lastName: 'Armstrong',
2180
- email: 'erat.vel@auctor.net',
2181
- phoneNo: '(029) 5052 0365',
2182
- street: '157-253 Hendrerit Av.',
2183
- city: 'Aubervilliers',
2184
- postcode: '2151',
2185
- country: 'Mayotte',
2186
- personalID: '16730607 0553',
2187
- },
2188
- {
2189
- firstName: 'Samuel',
2190
- lastName: 'Harrell',
2191
- email: 'tellus@magnaSed.edu',
2192
- phoneNo: '07064 102166',
2193
- street: 'P.O. Box 713, 4115 Ut Rd.',
2194
- city: 'Kingston',
2195
- postcode: '23315',
2196
- country: 'Lebanon',
2197
- personalID: '16361016 5551',
2198
- },
2199
- {
2200
- firstName: 'Merritt',
2201
- lastName: 'Holland',
2202
- email: 'interdum.Nunc.sollicitudin@elitpellentesque.edu',
2203
- phoneNo: '0800 825458',
2204
- street: 'P.O. Box 261, 3590 Nascetur Road',
2205
- city: 'Drancy',
2206
- postcode: '760017',
2207
- country: 'French Southern Territories',
2208
- personalID: '16040311 2121',
2209
- },
2210
- {
2211
- firstName: 'Harlan',
2212
- lastName: 'Brennan',
2213
- email: 'nascetur.ridiculus@feugiatmetussit.net',
2214
- phoneNo: '(012812) 59410',
2215
- street: '8210 Torquent Av.',
2216
- city: 'Grantham',
2217
- postcode: '01537',
2218
- country: 'Saint Pierre and Miquelon',
2219
- personalID: '16431216 0239',
2220
- },
2221
- {
2222
- firstName: 'Stuart',
2223
- lastName: 'Deleon',
2224
- email: 'sed.pede.nec@maurisMorbinon.com',
2225
- phoneNo: '0807 013 3815',
2226
- street: 'P.O. Box 143, 4909 At Street',
2227
- city: 'Terrance',
2228
- postcode: '27218',
2229
- country: 'Jersey',
2230
- personalID: '16330207 5852',
2231
- },
2232
- {
2233
- firstName: 'Clarke',
2234
- lastName: 'Middleton',
2235
- email: 'in@estacfacilisis.org',
2236
- phoneNo: '(028) 5013 9648',
2237
- street: '9856 Eget, Avenue',
2238
- city: 'Solihull',
2239
- postcode: '72893',
2240
- country: 'Seychelles',
2241
- personalID: '16340804 3325',
2242
- },
2243
- {
2244
- firstName: 'Roanna',
2245
- lastName: 'Gentry',
2246
- email: 'dui@nascetur.net',
2247
- phoneNo: '(024) 3023 2962',
2248
- street: '3566 Ornare. Rd.',
2249
- city: 'Freiberg',
2250
- postcode: '3899',
2251
- country: 'Lesotho',
2252
- personalID: '16680618 3791',
2253
- },
2254
- {
2255
- firstName: 'Delilah',
2256
- lastName: 'Bird',
2257
- email: 'laoreet.lectus.quis@utaliquam.edu',
2258
- phoneNo: '07160 224163',
2259
- street: 'P.O. Box 332, 8565 Molestie Avenue',
2260
- city: 'Washuk',
2261
- postcode: '607065',
2262
- country: 'Indonesia',
2263
- personalID: '16891112 9461',
2264
- },
2265
- {
2266
- firstName: 'Georgia',
2267
- lastName: 'Cash',
2268
- email: 'dui@enimnisl.net',
2269
- phoneNo: '(0113) 542 3955',
2270
- street: '900-3252 Fusce Avenue',
2271
- city: 'Sint-Michiels',
2272
- postcode: 'Z8203',
2273
- country: 'Niue',
2274
- personalID: '16340718 4716',
2275
- },
2276
- {
2277
- firstName: 'Aiko',
2278
- lastName: 'Mclean',
2279
- email: 'cubilia.Curae.Phasellus@augueid.com',
2280
- phoneNo: '055 9506 2116',
2281
- street: 'P.O. Box 786, 1756 Fringilla St.',
2282
- city: 'Malonne',
2283
- postcode: 'Y8E 7M2',
2284
- country: 'Belize',
2285
- personalID: '16680622 4207',
2286
- },
2287
- {
2288
- firstName: 'Winter',
2289
- lastName: 'Jacobs',
2290
- email: 'aliquet@Duisac.ca',
2291
- phoneNo: '0800 693847',
2292
- street: '774-9011 Arcu Road',
2293
- city: 'Bilbo',
2294
- postcode: '05558',
2295
- country: 'Equatorial Guinea',
2296
- personalID: '16611201 4144',
2297
- },
2298
- {
2299
- firstName: 'Jolene',
2300
- lastName: 'Rios',
2301
- email: 'odio.Aliquam.vulputate@ac.ca',
2302
- phoneNo: '(023) 4876 2215',
2303
- street: 'Ap #325-8225 Amet Road',
2304
- city: 'Limena',
2305
- postcode: 'K56 0YJ',
2306
- country: 'Morocco',
2307
- personalID: '16170215 3485',
2308
- },
2309
- {
2310
- firstName: 'Kaden',
2311
- lastName: 'Morrow',
2312
- email: 'rutrum@eleifendnec.ca',
2313
- phoneNo: '07305 685548',
2314
- street: '8870 Aliquam Road',
2315
- city: 'Sète',
2316
- postcode: '04908',
2317
- country: 'Peru',
2318
- personalID: '16820820 6675',
2319
- },
2320
- {
2321
- firstName: 'Kaseem',
2322
- lastName: 'Norris',
2323
- email: 'mauris.erat.eget@nequeMorbi.com',
2324
- phoneNo: '07275 403152',
2325
- street: 'P.O. Box 776, 7115 Integer Avenue',
2326
- city: 'Jönköping',
2327
- postcode: '42236-83471',
2328
- country: 'Sudan',
2329
- personalID: '16440829 7895',
2330
- },
2331
- {
2332
- firstName: 'Vladimir',
2333
- lastName: 'Mcguire',
2334
- email: 'id@nonarcuVivamus.edu',
2335
- phoneNo: '0500 950469',
2336
- street: '2067 Est Ave',
2337
- city: 'Ziano di Fiemme',
2338
- postcode: '774056',
2339
- country: 'Mexico',
2340
- personalID: '16771016 3796',
2341
- },
2342
- {
2343
- firstName: 'Jocelyn',
2344
- lastName: 'Schroeder',
2345
- email: 'dolor@nec.ca',
2346
- phoneNo: '07302 403156',
2347
- street: 'Ap #155-3999 Vivamus St.',
2348
- city: 'Malloa',
2349
- postcode: '4059',
2350
- country: 'Canada',
2351
- personalID: '16530314 9388',
2352
- },
2353
- {
2354
- firstName: 'Howard',
2355
- lastName: 'Villarreal',
2356
- email: 'Donec.felis@insodales.com',
2357
- phoneNo: '07624 830239',
2358
- street: '540-7057 Cras Rd.',
2359
- city: 'Siverek',
2360
- postcode: '8701',
2361
- country: 'Seychelles',
2362
- personalID: '16640823 8530',
2363
- },
2364
- {
2365
- firstName: 'Adam',
2366
- lastName: 'Miranda',
2367
- email: 'amet.dapibus@faucibus.edu',
2368
- phoneNo: '0845 46 49',
2369
- street: 'Ap #931-6286 Diam. Avenue',
2370
- city: 'Warburg',
2371
- postcode: '01972',
2372
- country: 'Jordan',
2373
- personalID: '16370414 7911',
2374
- },
2375
- {
2376
- firstName: 'Aiko',
2377
- lastName: 'Elliott',
2378
- email: 'sodales@mauris.edu',
2379
- phoneNo: '0800 1111',
2380
- street: 'P.O. Box 583, 6119 Ut St.',
2381
- city: 'Villavicencio',
2382
- postcode: '4864 XQ',
2383
- country: 'Faroe Islands',
2384
- personalID: '16940907 6115',
2385
- },
2386
- \].map((person) \=> ({
2387
- ...person,
2388
- sales: getSales(Math.random()),
2389
- profit: getProfit(Math.random()),
2390
- redOrGreen: getRating(),
2391
- date: new Date(Math.floor(Math.random() \* \-10000000000)).toDateString(),
2392
- }));
2393
- const createClassNameMutationObserver \= (
2394
- element: HTMLElement,
2395
- callback: (className: string) \=> void,
2396
- ): MutationObserver \=> {
2397
- const observer \= new MutationObserver(() \=> {
2398
- callback(element.className);
2399
- });
2400
- observer.observe(element, {
2401
- attributes: true,
2402
- attributeFilter: \['class'\],
2403
- childList: false,
2404
- characterData: false,
2405
- });
2406
- return observer;
2407
- };
2408
- const useClassNameMutationObserver \= (
2409
- element: HTMLElement,
2410
- callback: () \=> void,
2411
- ): void \=> {
2412
- useEffect(() \=> {
2413
- const observer \= createClassNameMutationObserver(element, callback);
2414
- // Cleanup listener
2415
- return (): void \=> {
2416
- observer.disconnect();
2417
- };
2418
- });
2419
- };
2420
- const RedOrGreenFormatter \= (params: ValueFormatterParams) \=> {
2421
- const dotStyle \= styles\[\`dot--${params.value}\`\];
2422
- return <span className\={\`${styles.dot} ${dotStyle}\`} />;
2423
- };
2424
- const CommaFormatter \= (params: ValueFormatterParams): string \=> {
2425
- return params.value.toString().replace(/\\B(?=(\\d{3})+(?!\\d))/g, ',');
2426
- };
2427
- const CurrencyFormatter \= (params: ValueFormatterParams): string \=> {
2428
- if (params.value \=== '0.00') {
2429
- return formatter2dp.format(params.value);
2430
- }
2431
- return formatterCurrency.format(params.value);
2432
- };
2433
- export const AgGridCompact \= (args: AgGridReactProps) \=> {
2434
- const \[rowData, setRowData\] \= useState(BIG\_DATA);
2435
- const api \= useRef<GridApi\>();
2436
- // pick one row at random to show data updating in the grid
2437
- useEffect(() \=> {
2438
- const updateTick \= setInterval(() \=> {
2439
- const randomNo \= Math.random();
2440
- const index \= Math.floor(Math.random() \* rowData.length);
2441
- const itemToUpdate \= rowData\[index\];
2442
- if (randomNo < 0.5) {
2443
- itemToUpdate.sales \= getSales(Math.random());
2444
- } else if (randomNo \> 0.9) {
2445
- itemToUpdate.profit \= getProfit(0);
2446
- } else {
2447
- itemToUpdate.profit \= getProfit(Math.random());
2448
- }
2449
- setRowData(rowData);
2450
- api.current?.refreshCells();
2451
- }, 500);
2452
- return () \=> {
2453
- clearInterval(updateTick);
2454
- };
2455
- }, \[rowData\]);
2456
- const onGridReady \= useCallback((event: GridReadyEvent): void \=> {
2457
- api.current \= event.api;
2458
- api.current.resetRowHeights();
2459
- }, \[\]);
2460
- useClassNameMutationObserver(document.documentElement, () \=> {
2461
- if (api.current) {
2462
- api.current.resetRowHeights();
2463
- }
2464
- });
2465
- return (
2466
- <IressAgGridContainer
2467
- alignMiddle
2468
- compact
2469
- style\={{ height: '100vh', width: '100%' }}
2470
- \>
2471
- <AgGridReact {...args}
2472
- onGridReady={onGridReady}
2473
- rowDragManaged animateRows enableRangeSelection={true}
2474
- enableCharts={true}
2475
- sideBar={true}
2476
- rowData={rowData}
2477
- rowSelection="multiple" rowMultiSelectWithClick components={{
2478
- redGreenDots: RedOrGreenFormatter,
2479
- }}
2480
- defaultColDef={{
2481
- enableCellChangeFlash: true,
2482
- resizable: true,
2483
- sortable: true,
2484
- unSortIcon: true,
2485
- filter: true,
2486
- floatingFilter: true,
2487
- enablePivot: false,
2488
- filterParams: {
2489
- buttons: \['reset', 'apply'\],
2490
- },
2491
- autoHeight: true,
2492
- wrapText: true,
2493
- }}
2494
- icons={AG\_THEME\_IRESS\_ICONS}
2495
- columnDefs={\[
2496
- {
2497
- headerName: 'Employee',
2498
- children: \[
2499
- {
2500
- field: 'firstName',
2501
- editable: true,
2502
- filter: 'agTextColumnFilter',
2503
- headerTooltip: 'First name',
2504
- rowDrag: true,
2505
- lockVisible: true,
2506
- tooltipField: 'firstName',
2507
- },
2508
- {
2509
- field: 'lastName',
2510
- editable: true,
2511
- filter: 'agTextColumnFilter',
2512
- headerTooltip: 'Surname',
2513
- lockVisible: true,
2514
- cellClass: 'iress-cell--divider',
2515
- headerClass: 'iress-cell--divider',
2516
- columnGroupShow: 'open',
2517
- },
2518
- {
2519
- field: 'personalID',
2520
- filter: 'agTextColumnFilter',
2521
- headerTooltip: 'Personal ID',
2522
- columnGroupShow: 'open',
2523
- },
2524
- {
2525
- field: 'date',
2526
- filter: 'agDateColumnFilter',
2527
- headerTooltip: 'Date',
2528
- columnGroupShow: 'open',
2529
- },
2530
- \],
2531
- },
2532
- {
2533
- headerName: 'Sales performance',
2534
- children: \[
2535
- {
2536
- field: 'redOrGreen',
2537
- headerName: 'Rating',
2538
- cellRenderer: 'redGreenDots',
2539
- filter: false,
2540
- },
2541
- {
2542
- field: 'sales',
2543
- filter: 'agNumberColumnFilter',
2544
- valueFormatter: CommaFormatter,
2545
- },
2546
- {
2547
- field: 'profit',
2548
- valueFormatter: CurrencyFormatter,
2549
- cellClassRules: {
2550
- 'iress--positive': (params) \=> parseInt(params.value, 10) \> 0,
2551
- 'iress--negative': (params) \=> parseInt(params.value, 10) < 0,
2552
- 'iress--zero': (params) \=> params.value \=== '0.00',
2553
- },
2554
- },
2555
- \],
2556
- },
2557
- {
2558
- headerName: 'Contact details',
2559
- children: \[
2560
- {
2561
- field: 'email',
2562
- width: 350,
2563
- filter: 'agTextColumnFilter',
2564
- headerTooltip: 'Email address',
2565
- cellClass: 'iress-cell--ellipsis',
2566
- },
2567
- {
2568
- field: 'phoneNo',
2569
- enableValue: true,
2570
- filter: 'agTextColumnFilter',
2571
- headerTooltip: 'Phone number',
2572
- },
2573
- \],
2574
- },
2575
- {
2576
- headerName: 'Address',
2577
- children: \[
2578
- {
2579
- field: 'street',
2580
- width: 350,
2581
- filter: 'agTextColumnFilter',
2582
- cellClass: 'iress-cell--ellipsis',
2583
- columnGroupShow: 'open',
2584
- },
2585
- {
2586
- field: 'city',
2587
- filter: 'agTextColumnFilter',
2588
- columnGroupShow: 'open',
2589
- },
2590
- {
2591
- field: 'postcode',
2592
- filter: 'agTextColumnFilter',
2593
- columnGroupShow: 'open',
2594
- },
2595
- { field: 'country', filter: 'agTextColumnFilter' },
2596
- \],
2597
- },
2598
- \]}
2599
- /> </IressAgGridContainer\>
2600
- );
2601
- };
2602
- export default AgGridCompact;
2603
-
2604
- Copy
1012
+ Show code
2605
1013
 
2606
1014
  [](#utility-classes)Utility classes
2607
1015
  -----------------------------------