@visns-studio/visns-components 1.1.3 → 1.1.5

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.
@@ -13,6 +13,7 @@ import {
13
13
  Check,
14
14
  Clock,
15
15
  CloudDownload,
16
+ Copy,
16
17
  Edit,
17
18
  Ribbon,
18
19
  Search,
@@ -322,6 +323,8 @@ const DataGrid = (props) => {
322
323
  switch (s.id) {
323
324
  case "complete":
324
325
  return getIconComponent(Check);
326
+ case "copy":
327
+ return getIconComponent(Copy);
325
328
  case "delete":
326
329
  return getIconComponent(Backspace);
327
330
  case "primary":
@@ -357,6 +360,10 @@ const DataGrid = (props) => {
357
360
  header: column.label,
358
361
  defaultFlex: 1,
359
362
  link: column.link ? column.link : {},
363
+ defaultWidth:
364
+ column.width && column.width > 0
365
+ ? column.width
366
+ : undefined,
360
367
  render: ({ data }) => {
361
368
  let value = data.audits[0].user.name;
362
369
 
@@ -368,6 +375,10 @@ const DataGrid = (props) => {
368
375
  name: column.id,
369
376
  header: column.label,
370
377
  defaultFlex: 1,
378
+ defaultWidth:
379
+ column.width && column.width > 0
380
+ ? column.width
381
+ : undefined,
371
382
  link: column.link ? column.link : {},
372
383
  render: ({ data }) => {
373
384
  if (data) {
@@ -383,6 +394,10 @@ const DataGrid = (props) => {
383
394
  name: column.id,
384
395
  header: column.label,
385
396
  defaultFlex: 1,
397
+ defaultWidth:
398
+ column.width && column.width > 0
399
+ ? column.width
400
+ : undefined,
386
401
  link: column.link ? column.link : {},
387
402
  render: ({ data }) => {
388
403
  if (data && data[column.id]) {
@@ -398,6 +413,10 @@ const DataGrid = (props) => {
398
413
  name: column.id,
399
414
  header: column.label,
400
415
  defaultFlex: 1,
416
+ defaultWidth:
417
+ column.width && column.width > 0
418
+ ? column.width
419
+ : undefined,
401
420
  link: column.link ? column.link : {},
402
421
  render: ({ data }) => {
403
422
  if (data && data[column.id]) {
@@ -415,6 +434,10 @@ const DataGrid = (props) => {
415
434
  name: column.id,
416
435
  header: column.label,
417
436
  defaultFlex: 1,
437
+ defaultWidth:
438
+ column.width && column.width > 0
439
+ ? column.width
440
+ : undefined,
418
441
  link: column.link ? column.link : {},
419
442
  render: ({ data }) => {
420
443
  if (data) {
@@ -439,6 +462,10 @@ const DataGrid = (props) => {
439
462
  name: column.id,
440
463
  header: column.label,
441
464
  defaultFlex: 1,
465
+ defaultWidth:
466
+ column.width && column.width > 0
467
+ ? column.width
468
+ : undefined,
442
469
  link: column.link ? column.link : {},
443
470
  render: ({ data }) => {
444
471
  let icons = [];
@@ -464,6 +491,10 @@ const DataGrid = (props) => {
464
491
  name: column.id,
465
492
  header: column.label,
466
493
  defaultFlex: 1,
494
+ defaultWidth:
495
+ column.width && column.width > 0
496
+ ? column.width
497
+ : undefined,
467
498
  link: column.link ? column.link : {},
468
499
  render: ({ data }) => {
469
500
  if (
@@ -484,6 +515,10 @@ const DataGrid = (props) => {
484
515
  name: column.id,
485
516
  header: column.label,
486
517
  defaultFlex: 1,
518
+ defaultWidth:
519
+ column.width && column.width > 0
520
+ ? column.width
521
+ : undefined,
487
522
  link: column.link ? column.link : {},
488
523
  type: "number",
489
524
  };
@@ -492,6 +527,10 @@ const DataGrid = (props) => {
492
527
  name: column.id,
493
528
  header: column.label,
494
529
  defaultFlex: 1,
530
+ defaultWidth:
531
+ column.width && column.width > 0
532
+ ? column.width
533
+ : undefined,
495
534
  link: column.link ? column.link : {},
496
535
  render: ({ data }) => {
497
536
  if (data) {
@@ -505,6 +544,10 @@ const DataGrid = (props) => {
505
544
  name: column.id,
506
545
  header: column.label,
507
546
  defaultFlex: 1,
547
+ defaultWidth:
548
+ column.width && column.width > 0
549
+ ? column.width
550
+ : undefined,
508
551
  link: column.link ? column.link : {},
509
552
  render: ({ data }) => {
510
553
  return <span>{column.placeholder}</span>;
@@ -521,6 +564,10 @@ const DataGrid = (props) => {
521
564
  name: relationName,
522
565
  header: column.label,
523
566
  defaultFlex: 1,
567
+ defaultWidth:
568
+ column.width && column.width > 0
569
+ ? column.width
570
+ : undefined,
524
571
  link: column.link ? column.link : {},
525
572
  render: ({ data }) => {
526
573
  let value = column.id.reduce((acc, id) => {
@@ -549,6 +596,10 @@ const DataGrid = (props) => {
549
596
  name: column.id,
550
597
  header: column.label,
551
598
  defaultFlex: 1,
599
+ defaultWidth:
600
+ column.width && column.width > 0
601
+ ? column.width
602
+ : undefined,
552
603
  link: column.link ? column.link : {},
553
604
  render: ({ data }) => {
554
605
  let stage = "";
@@ -567,6 +618,10 @@ const DataGrid = (props) => {
567
618
  name: column.id,
568
619
  header: column.label,
569
620
  defaultFlex: 1,
621
+ defaultWidth:
622
+ column.width && column.width > 0
623
+ ? column.width
624
+ : undefined,
570
625
  link: column.link ? column.link : {},
571
626
  render: ({ data }) => {
572
627
  if (data && data[column.id]) {
@@ -582,6 +637,10 @@ const DataGrid = (props) => {
582
637
  name: column.id,
583
638
  header: column.label,
584
639
  defaultFlex: 1,
640
+ defaultWidth:
641
+ column.width && column.width > 0
642
+ ? column.width
643
+ : undefined,
585
644
  link: column.link ? column.link : {},
586
645
  render: ({ data }) => {
587
646
  return (
@@ -598,6 +657,10 @@ const DataGrid = (props) => {
598
657
  name: column.id,
599
658
  header: column.label,
600
659
  defaultFlex: 1,
660
+ defaultWidth:
661
+ column.width && column.width > 0
662
+ ? column.width
663
+ : undefined,
601
664
  link: column.link ? column.link : {},
602
665
  };
603
666
  }
package/package.json CHANGED
@@ -32,7 +32,7 @@
32
32
  "react-dom": ">=18.2.0"
33
33
  },
34
34
  "name": "@visns-studio/visns-components",
35
- "version": "1.1.3",
35
+ "version": "1.1.5",
36
36
  "description": "Various packages to assist in the development of our Custom Applications.",
37
37
  "main": "index.js",
38
38
  "devDependencies": {},