@availity/mui-spaces 1.0.29 → 1.0.30
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 +7 -0
- package/dist/index.js +7 -7
- package/dist/index.mjs +7 -7
- package/package.json +1 -1
- package/src/lib/SpacesLink/linkHandlers.tsx +1 -1
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.30](https://github.com/Availity/element/compare/@availity/mui-spaces@1.0.29...@availity/mui-spaces@1.0.30) (2025-08-21)
|
|
6
|
+
|
|
7
|
+
|
|
8
|
+
### Bug Fixes
|
|
9
|
+
|
|
10
|
+
* spaces link full url only if starts with web ([5db57d4](https://github.com/Availity/element/commit/5db57d4c0e58f1b1c98b95186b6600ebb9d44493))
|
|
11
|
+
|
|
5
12
|
## [1.0.29](https://github.com/Availity/element/compare/@availity/mui-spaces@1.0.28...@availity/mui-spaces@1.0.29) (2025-07-02)
|
|
6
13
|
|
|
7
14
|
|
package/dist/index.js
CHANGED
|
@@ -118,7 +118,7 @@ var spacesReducer = (state, action) => {
|
|
|
118
118
|
const { type } = action;
|
|
119
119
|
return actions[type](state, action);
|
|
120
120
|
};
|
|
121
|
-
var fetchSpaces = (_0) => __async(
|
|
121
|
+
var fetchSpaces = (_0) => __async(null, [_0], function* ({ query, clientId, variables }) {
|
|
122
122
|
const headers = {};
|
|
123
123
|
if (clientId) {
|
|
124
124
|
headers["X-Client-ID"] = clientId;
|
|
@@ -144,7 +144,7 @@ var fetchSpaces = (_0) => __async(void 0, [_0], function* ({ query, clientId, va
|
|
|
144
144
|
hasNextPage
|
|
145
145
|
};
|
|
146
146
|
});
|
|
147
|
-
var fetchAllSpaces = (_0) => __async(
|
|
147
|
+
var fetchAllSpaces = (_0) => __async(null, [_0], function* ({
|
|
148
148
|
query,
|
|
149
149
|
clientId,
|
|
150
150
|
variables,
|
|
@@ -330,7 +330,7 @@ var getLocalStorageTopApps = (akaname) => {
|
|
|
330
330
|
const topAppsValues = getItemLocalStorage(`${TOP_APPS.KEYS.VALUES}-${akaname}`);
|
|
331
331
|
return topAppsValues;
|
|
332
332
|
};
|
|
333
|
-
var updateTopApps = (space, akaname) => __async(
|
|
333
|
+
var updateTopApps = (space, akaname) => __async(null, null, function* () {
|
|
334
334
|
if (!space.configurationId || !space.type) return;
|
|
335
335
|
if (canTrackSpace(space.configurationId, space.type)) {
|
|
336
336
|
const today = (0, import_dayjs.default)();
|
|
@@ -363,7 +363,7 @@ var disclaimerQuery = `query disclaimerFindOne($id: ID!) {
|
|
|
363
363
|
var DisclaimerModal = ({ disclaimerId }) => {
|
|
364
364
|
const [disclaimer, setDisclaimer] = (0, import_react.useState)("");
|
|
365
365
|
(0, import_react.useEffect)(() => {
|
|
366
|
-
const fetchDisclaimer = () => __async(
|
|
366
|
+
const fetchDisclaimer = () => __async(null, null, function* () {
|
|
367
367
|
if (disclaimerId) {
|
|
368
368
|
const result = yield import_api_axios2.avWebQLApi.create({ query: disclaimerQuery, variables: { id: disclaimerId } });
|
|
369
369
|
setDisclaimer(result.data.data.configurationFindOne.description);
|
|
@@ -780,7 +780,7 @@ var import_hooks = require("@availity/hooks");
|
|
|
780
780
|
// src/lib/SpacesLink/linkHandlers.tsx
|
|
781
781
|
var import_native_form = __toESM(require("@availity/native-form"));
|
|
782
782
|
var import_resolve_url2 = require("@availity/resolve-url");
|
|
783
|
-
var openLink = (space, params) => __async(
|
|
783
|
+
var openLink = (space, params) => __async(null, null, function* () {
|
|
784
784
|
var _a, _b, _c;
|
|
785
785
|
if (!((_a = space == null ? void 0 : space.link) == null ? void 0 : _a.url)) {
|
|
786
786
|
return;
|
|
@@ -791,14 +791,14 @@ var openLink = (space, params) => __async(void 0, null, function* () {
|
|
|
791
791
|
const needsSpaceId = !(0, import_resolve_url2.isAbsoluteUrl)(space.link.url) || essentialsDomainRegex.test(space.link.url);
|
|
792
792
|
const urlWithParams = needsSpaceId ? updateUrl(space.link.url, "spaceId", spaceId) : space.link.url;
|
|
793
793
|
let url = !(0, import_resolve_url2.isAbsoluteUrl)(space.link.url) ? getUrl(urlWithParams, false, false) : urlWithParams;
|
|
794
|
-
if (!(0, import_resolve_url2.isAbsoluteUrl)(url) && !essentialsDomainRegex.test(document.referrer) &&
|
|
794
|
+
if (!(0, import_resolve_url2.isAbsoluteUrl)(url) && !essentialsDomainRegex.test(document.referrer) && /^\/web\/|\/public\/(apps|spaces)/.test(url)) {
|
|
795
795
|
const referrer = new URL(document.referrer);
|
|
796
796
|
url = `${referrer.origin}${url}`;
|
|
797
797
|
}
|
|
798
798
|
const target = getTarget(space.link.target);
|
|
799
799
|
window.open(url, target);
|
|
800
800
|
});
|
|
801
|
-
var openLinkWithSso = (_0, _1) => __async(
|
|
801
|
+
var openLinkWithSso = (_0, _1) => __async(null, [_0, _1], function* (space, { akaname, clientId, payerSpaceId, ssoParams }) {
|
|
802
802
|
var _a, _b;
|
|
803
803
|
if (space.meta && space.meta.ssoId) {
|
|
804
804
|
let options;
|
package/dist/index.mjs
CHANGED
|
@@ -76,7 +76,7 @@ var spacesReducer = (state, action) => {
|
|
|
76
76
|
const { type } = action;
|
|
77
77
|
return actions[type](state, action);
|
|
78
78
|
};
|
|
79
|
-
var fetchSpaces = (_0) => __async(
|
|
79
|
+
var fetchSpaces = (_0) => __async(null, [_0], function* ({ query, clientId, variables }) {
|
|
80
80
|
const headers = {};
|
|
81
81
|
if (clientId) {
|
|
82
82
|
headers["X-Client-ID"] = clientId;
|
|
@@ -102,7 +102,7 @@ var fetchSpaces = (_0) => __async(void 0, [_0], function* ({ query, clientId, va
|
|
|
102
102
|
hasNextPage
|
|
103
103
|
};
|
|
104
104
|
});
|
|
105
|
-
var fetchAllSpaces = (_0) => __async(
|
|
105
|
+
var fetchAllSpaces = (_0) => __async(null, [_0], function* ({
|
|
106
106
|
query,
|
|
107
107
|
clientId,
|
|
108
108
|
variables,
|
|
@@ -288,7 +288,7 @@ var getLocalStorageTopApps = (akaname) => {
|
|
|
288
288
|
const topAppsValues = getItemLocalStorage(`${TOP_APPS.KEYS.VALUES}-${akaname}`);
|
|
289
289
|
return topAppsValues;
|
|
290
290
|
};
|
|
291
|
-
var updateTopApps = (space, akaname) => __async(
|
|
291
|
+
var updateTopApps = (space, akaname) => __async(null, null, function* () {
|
|
292
292
|
if (!space.configurationId || !space.type) return;
|
|
293
293
|
if (canTrackSpace(space.configurationId, space.type)) {
|
|
294
294
|
const today = dayjs();
|
|
@@ -321,7 +321,7 @@ var disclaimerQuery = `query disclaimerFindOne($id: ID!) {
|
|
|
321
321
|
var DisclaimerModal = ({ disclaimerId }) => {
|
|
322
322
|
const [disclaimer, setDisclaimer] = useState("");
|
|
323
323
|
useEffect(() => {
|
|
324
|
-
const fetchDisclaimer = () => __async(
|
|
324
|
+
const fetchDisclaimer = () => __async(null, null, function* () {
|
|
325
325
|
if (disclaimerId) {
|
|
326
326
|
const result = yield avWebQLApi2.create({ query: disclaimerQuery, variables: { id: disclaimerId } });
|
|
327
327
|
setDisclaimer(result.data.data.configurationFindOne.description);
|
|
@@ -738,7 +738,7 @@ import { useCurrentUser } from "@availity/hooks";
|
|
|
738
738
|
// src/lib/SpacesLink/linkHandlers.tsx
|
|
739
739
|
import nativeForm from "@availity/native-form";
|
|
740
740
|
import { isAbsoluteUrl as isAbsoluteUrl2 } from "@availity/resolve-url";
|
|
741
|
-
var openLink = (space, params) => __async(
|
|
741
|
+
var openLink = (space, params) => __async(null, null, function* () {
|
|
742
742
|
var _a, _b, _c;
|
|
743
743
|
if (!((_a = space == null ? void 0 : space.link) == null ? void 0 : _a.url)) {
|
|
744
744
|
return;
|
|
@@ -749,14 +749,14 @@ var openLink = (space, params) => __async(void 0, null, function* () {
|
|
|
749
749
|
const needsSpaceId = !isAbsoluteUrl2(space.link.url) || essentialsDomainRegex.test(space.link.url);
|
|
750
750
|
const urlWithParams = needsSpaceId ? updateUrl(space.link.url, "spaceId", spaceId) : space.link.url;
|
|
751
751
|
let url = !isAbsoluteUrl2(space.link.url) ? getUrl(urlWithParams, false, false) : urlWithParams;
|
|
752
|
-
if (!isAbsoluteUrl2(url) && !essentialsDomainRegex.test(document.referrer) &&
|
|
752
|
+
if (!isAbsoluteUrl2(url) && !essentialsDomainRegex.test(document.referrer) && /^\/web\/|\/public\/(apps|spaces)/.test(url)) {
|
|
753
753
|
const referrer = new URL(document.referrer);
|
|
754
754
|
url = `${referrer.origin}${url}`;
|
|
755
755
|
}
|
|
756
756
|
const target = getTarget(space.link.target);
|
|
757
757
|
window.open(url, target);
|
|
758
758
|
});
|
|
759
|
-
var openLinkWithSso = (_0, _1) => __async(
|
|
759
|
+
var openLinkWithSso = (_0, _1) => __async(null, [_0, _1], function* (space, { akaname, clientId, payerSpaceId, ssoParams }) {
|
|
760
760
|
var _a, _b;
|
|
761
761
|
if (space.meta && space.meta.ssoId) {
|
|
762
762
|
let options;
|
package/package.json
CHANGED
|
@@ -20,7 +20,7 @@ export const openLink: OpenLink = async (space, params) => {
|
|
|
20
20
|
|
|
21
21
|
let url = !isAbsoluteUrl(space.link.url) ? getUrl(urlWithParams, false, false) : urlWithParams;
|
|
22
22
|
|
|
23
|
-
if (!isAbsoluteUrl(url) && !essentialsDomainRegex.test(document.referrer) &&
|
|
23
|
+
if (!isAbsoluteUrl(url) && !essentialsDomainRegex.test(document.referrer) && /^\/web\/|\/public\/(apps|spaces)/.test(url)) {
|
|
24
24
|
const referrer = new URL(document.referrer);
|
|
25
25
|
url = `${referrer.origin}${url}`
|
|
26
26
|
}
|