@visns-studio/visns-components 3.4.7 → 3.4.8

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.
@@ -1,5 +1,5 @@
1
1
  import React, { useEffect, useState } from 'react';
2
- import { useParams } from 'react-router-dom';
2
+ import { Link, useParams } from 'react-router-dom';
3
3
  import moment from 'moment';
4
4
  import parse from 'html-react-parser';
5
5
  import Popup from 'reactjs-popup';
@@ -598,9 +598,37 @@ function GenericDetail({ extraUrlParam, setting, urlParam, userProfile }) {
598
598
  ? `${item.label}:`
599
599
  : null}
600
600
  </strong>{' '}
601
- {renderValue(
602
- item,
603
- data
601
+ {item
602
+ .href
603
+ ?.url &&
604
+ item
605
+ .href
606
+ ?.key ? (
607
+ <Link
608
+ to={`${
609
+ item
610
+ .href
611
+ .url
612
+ }${
613
+ data[
614
+ item
615
+ .href
616
+ .key
617
+ ]
618
+ }`}
619
+ >
620
+ {renderValue(
621
+ item,
622
+ data
623
+ )}
624
+ </Link>
625
+ ) : (
626
+ <>
627
+ {renderValue(
628
+ item,
629
+ data
630
+ )}
631
+ </>
604
632
  )}
605
633
  </li>
606
634
  )
package/package.json CHANGED
@@ -49,7 +49,7 @@
49
49
  "react-dom": "^17.0.1"
50
50
  },
51
51
  "name": "@visns-studio/visns-components",
52
- "version": "3.4.7",
52
+ "version": "3.4.8",
53
53
  "description": "Various packages to assist in the development of our Custom Applications.",
54
54
  "main": "index.js",
55
55
  "scripts": {