@visns-studio/visns-components 4.9.2 → 4.9.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.
package/package.json CHANGED
@@ -75,7 +75,7 @@
75
75
  "react-dom": "^17.0.0 || ^18.0.0"
76
76
  },
77
77
  "name": "@visns-studio/visns-components",
78
- "version": "4.9.2",
78
+ "version": "4.9.4",
79
79
  "description": "Various packages to assist in the development of our Custom Applications.",
80
80
  "main": "src/index.js",
81
81
  "files": [
@@ -529,7 +529,10 @@ const DataGrid = forwardRef(
529
529
  modalGalleryOpen();
530
530
  break;
531
531
  case 'link':
532
- const url = `${s.baseUrl}/${d[s.key]}`;
532
+ const url = s.baseUrl
533
+ ? `${s.baseUrl}/${d[s.key]}`
534
+ : `${d[s.key]}`;
535
+
533
536
  navigator.clipboard.writeText(url).then(
534
537
  () => {
535
538
  toast.success(
@@ -44,13 +44,6 @@ const Reset = ({ logo }) => {
44
44
  return (
45
45
  <div className={styles.lcontainer}>
46
46
  <div className={styles.lwrap}>
47
- <aside
48
- className={styles.aside}
49
- style={{
50
- backgroundImage: `url(${loginBg})`,
51
- backgroundSize: 'cover',
52
- }}
53
- ></aside>
54
47
  <div className={styles.logincontainer}>
55
48
  <form onSubmit={handleSubmit}>
56
49
  <Reveal effect="fadeInUp">
@@ -96,13 +96,6 @@ const Verify = ({ logo }) => {
96
96
  return (
97
97
  <div className={styles.lcontainer}>
98
98
  <div className={styles.lwrap}>
99
- <aside
100
- className={styles.aside}
101
- style={{
102
- backgroundImage: `url(${loginBg})`,
103
- backgroundSize: 'cover',
104
- }}
105
- ></aside>
106
99
  <div className={styles.logincontainer}>
107
100
  <form onSubmit={handleSubmit}>
108
101
  <Reveal effect="fadeInUp">
@@ -397,10 +397,27 @@ const GenericDynamic = ({
397
397
  });
398
398
  }
399
399
 
400
- const res = await Download(s.url, s.method, payload);
400
+ const resSave = await Download(s.url, s.method, payload);
401
401
 
402
- if (res.data) {
403
- saveAs(res.data);
402
+ if (resSave.data) {
403
+ saveAs(resSave.data);
404
+ }
405
+ break;
406
+ case 'fetch':
407
+ if (s.payload?.length > 0) {
408
+ s.payload.forEach((p) => {
409
+ if (data[p]) {
410
+ payload[p] = data[p];
411
+ }
412
+ });
413
+ }
414
+
415
+ const resFetch = await CustomFetch(s.url, s.method, payload);
416
+
417
+ if (resFetch.data.error === '') {
418
+ toast.success(
419
+ s.message ? s.message : 'Form fetched successfully'
420
+ );
404
421
  }
405
422
  break;
406
423
  default: