@visns-studio/visns-components 2.2.12 → 2.3.0

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.
@@ -23,42 +23,45 @@ const Login = ({ logo, providers, setSystemAuth, setUserProfile }) => {
23
23
 
24
24
  const renderSsoButton = () => {
25
25
  let content =
26
- providers.length > 0 ? (
26
+ providers && providers.length > 0 ? (
27
27
  <div className="formItem fwItem lastItem forgotten">
28
28
  <span>OR</span>
29
29
  </div>
30
30
  ) : null;
31
31
 
32
- providers.forEach((provider) => {
33
- switch (provider) {
34
- case 'azure':
35
- content = (
36
- <>
37
- {content}
38
- <div className="formItem fwItem lastItem forgotten">
39
- <button
40
- className="btn"
41
- onClick={(e) => {
42
- e.preventDefault();
43
-
44
- window.location.href = '/auth/azure';
45
- }}
46
- >
47
- <img
48
- src={
49
- 'https://d16lktya8ojp5z.cloudfront.net/generic/images/microsoft.png'
50
- }
51
- width="13px"
52
- height="13px"
53
- />{' '}
54
- Microsoft
55
- </button>
56
- </div>
57
- </>
58
- );
59
- break;
60
- }
61
- });
32
+ if (providers) {
33
+ providers.forEach((provider) => {
34
+ switch (provider) {
35
+ case 'azure':
36
+ content = (
37
+ <>
38
+ {content}
39
+ <div className="formItem fwItem lastItem forgotten">
40
+ <button
41
+ className="btn"
42
+ onClick={(e) => {
43
+ e.preventDefault();
44
+
45
+ window.location.href =
46
+ '/auth/azure';
47
+ }}
48
+ >
49
+ <img
50
+ src={
51
+ 'https://d16lktya8ojp5z.cloudfront.net/generic/images/microsoft.png'
52
+ }
53
+ width="13px"
54
+ height="13px"
55
+ />{' '}
56
+ Microsoft
57
+ </button>
58
+ </div>
59
+ </>
60
+ );
61
+ break;
62
+ }
63
+ });
64
+ }
62
65
 
63
66
  return content;
64
67
  };
package/package.json CHANGED
@@ -40,7 +40,7 @@
40
40
  "react-dom": "^17.0.1"
41
41
  },
42
42
  "name": "@visns-studio/visns-components",
43
- "version": "2.2.12",
43
+ "version": "2.3.0",
44
44
  "description": "Various packages to assist in the development of our Custom Applications.",
45
45
  "main": "index.js",
46
46
  "scripts": {