@availity/mui-spaces 1.0.27 → 1.0.28

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/CHANGELOG.md CHANGED
@@ -2,6 +2,13 @@
2
2
 
3
3
  This file was generated using [@jscutlery/semver](https://github.com/jscutlery/semver).
4
4
 
5
+ ## [1.0.28](https://github.com/Availity/element/compare/@availity/mui-spaces@1.0.27...@availity/mui-spaces@1.0.28) (2025-07-01)
6
+
7
+
8
+ ### Bug Fixes
9
+
10
+ * allow onprem sso ([3985456](https://github.com/Availity/element/commit/3985456532bbe6f1cf095f87d5c159aa41b05621))
11
+
5
12
  ## [1.0.27](https://github.com/Availity/element/compare/@availity/mui-spaces@1.0.26...@availity/mui-spaces@1.0.27) (2025-06-25)
6
13
 
7
14
 
package/dist/index.js CHANGED
@@ -799,9 +799,14 @@ var openLink = (space, params) => __async(void 0, null, function* () {
799
799
  window.open(url, target);
800
800
  });
801
801
  var openLinkWithSso = (_0, _1) => __async(void 0, [_0, _1], function* (space, { akaname, clientId, payerSpaceId, ssoParams }) {
802
- var _a;
802
+ var _a, _b;
803
803
  if (space.meta && space.meta.ssoId) {
804
- const options = ((_a = space.link) == null ? void 0 : _a.target) ? { target: getTarget(space.link.target) } : void 0;
804
+ let options;
805
+ if (space.meta.appsDomain === "true") {
806
+ options = ((_a = space.link) == null ? void 0 : _a.target) ? { target: getTarget(space.link.target) } : { action: `${new URL(document.referrer).origin}/ms/api/availity/internal/spc/magneto/sso/v1/saml/${space.meta.ssoId}` };
807
+ } else {
808
+ options = ((_b = space.link) == null ? void 0 : _b.target) ? { target: getTarget(space.link.target) } : void 0;
809
+ }
805
810
  const attributes = __spreadValues({
806
811
  X_XSRF_TOKEN: document.cookie.replace(/(?:(?:^|.*;\s*)XSRF-TOKEN\s*=\s*([^;]*).*$)|^.*$/, "$1"),
807
812
  spaceId: payerSpaceId
package/dist/index.mjs CHANGED
@@ -757,9 +757,14 @@ var openLink = (space, params) => __async(void 0, null, function* () {
757
757
  window.open(url, target);
758
758
  });
759
759
  var openLinkWithSso = (_0, _1) => __async(void 0, [_0, _1], function* (space, { akaname, clientId, payerSpaceId, ssoParams }) {
760
- var _a;
760
+ var _a, _b;
761
761
  if (space.meta && space.meta.ssoId) {
762
- const options = ((_a = space.link) == null ? void 0 : _a.target) ? { target: getTarget(space.link.target) } : void 0;
762
+ let options;
763
+ if (space.meta.appsDomain === "true") {
764
+ options = ((_a = space.link) == null ? void 0 : _a.target) ? { target: getTarget(space.link.target) } : { action: `${new URL(document.referrer).origin}/ms/api/availity/internal/spc/magneto/sso/v1/saml/${space.meta.ssoId}` };
765
+ } else {
766
+ options = ((_b = space.link) == null ? void 0 : _b.target) ? { target: getTarget(space.link.target) } : void 0;
767
+ }
763
768
  const attributes = __spreadValues({
764
769
  X_XSRF_TOKEN: document.cookie.replace(/(?:(?:^|.*;\s*)XSRF-TOKEN\s*=\s*([^;]*).*$)|^.*$/, "$1"),
765
770
  spaceId: payerSpaceId
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@availity/mui-spaces",
3
- "version": "1.0.27",
3
+ "version": "1.0.28",
4
4
  "description": "Availity MUI Spaces Component - part of the @availity/element design system",
5
5
  "keywords": [
6
6
  "react",
@@ -32,7 +32,12 @@ export const openLink: OpenLink = async (space, params) => {
32
32
 
33
33
  export const openLinkWithSso: OpenLinkWithSso = async (space, { akaname, clientId, payerSpaceId, ssoParams }) => {
34
34
  if (space.meta && space.meta.ssoId) {
35
- const options = space.link?.target ? { target: getTarget(space.link.target) } : undefined;
35
+ let options;
36
+ if (space.meta.appsDomain === 'true') {
37
+ options = space.link?.target ? { target: getTarget(space.link.target) } : { action: `${new URL(document.referrer).origin}/ms/api/availity/internal/spc/magneto/sso/v1/saml/${space.meta.ssoId}`};
38
+ } else {
39
+ options = space.link?.target ? { target: getTarget(space.link.target) } : undefined;
40
+ }
36
41
 
37
42
  const attributes: Record<string, string> = {
38
43
  X_XSRF_TOKEN: document.cookie.replace(/(?:(?:^|.*;\s*)XSRF-TOKEN\s*=\s*([^;]*).*$)|^.*$/, '$1'),