@ukpc-lib/react 0.10.5 → 0.10.6
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/dist/components/Notification/models/NotiticationDto.d.ts +4 -0
- package/dist/components/index.cjs +17 -17
- package/dist/components/index.js +1636 -1600
- package/dist/{index.module-9fbc52eb.cjs → index.module-939d1280.cjs} +6 -6
- package/dist/{index.module-0d16ee2f.js → index.module-aa83269c.js} +202 -203
- package/dist/share/index.cjs +1 -1
- package/dist/share/index.js +7 -7
- package/package.json +2 -2
- package/web-components-bundle/favorite-menu/index.js +1 -1
- package/web-components-bundle/global-menu/index.js +1 -1
- package/web-components-bundle/global-topbar/index.js +1 -1
- package/web-components-bundle/has-permission/index.js +1 -1
- package/web-components-bundle/{index-54d2e9b8.js → index-f73ddb24.js} +9931 -9896
package/dist/share/index.cjs
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
"use strict";Object.defineProperty(exports,Symbol.toStringTag,{value:"Module"});const e=require("../index.module-
|
|
1
|
+
"use strict";Object.defineProperty(exports,Symbol.toStringTag,{value:"Module"});const e=require("../index.module-939d1280.cjs"),m=require("axios"),u=require("react"),i=require("react/jsx-runtime");require("@r2wc/react-to-web-component");const l=require("react-router-dom");require("@mui/material");const c=r=>{const[t,o]=u.useState([]);return u.useEffect(()=>{m.get(`${r}/user-management/api/v1/users/my-account/permissions`,{withCredentials:!0}).then(s=>o(s.data)).catch(s=>{console.error("Getting user permission error:",s)})},[r]),t},a=r=>(t,o)=>{const s=c(r);return o?t.every(n=>s==null?void 0:s.includes(n)):t.some(n=>s==null?void 0:s.includes(n))},h=({baseUrl:r,accessWith:t,requireAll:o,children:s})=>a(r)(t,o)?i.jsx(i.Fragment,{children:s}):null,P=({accessWith:r,requireAll:t,baseUrl:o,unAuthorizedPath:s,children:n})=>a(o)(r,t)?i.jsx(i.Fragment,{children:n}):i.jsx(l.Navigate,{to:s,replace:!0});exports.AuthContext=e.AuthContext;exports.AuthProvider=e.AuthProvider;exports.ERROR_MESSAGE=e.ERROR_MESSAGE;exports.SaasThemeProvider=e.SaasThemeProvider;exports.TranslationProvider=e.TranslationProvider;exports.axiosInstance=e.axiosInstance;exports.color=e.color;exports.createCustomTheme=e.createCustomTheme;exports.handleErrorAxios=e.handleErrorAxios;exports.login=e.login;exports.logout=e.logout;exports.responseInterceptor=e.responseInterceptor;exports.search=e.search;exports.setFavicon=e.setFavicon;exports.translate=e.translate;exports.translationConfig=e.translationConfig;exports.useAuth=e.useAuth;exports.useCustomTranslation=e.useCustomTranslation;exports.useTheme=e.useTheme;exports.useTranslation=e.useTranslation$1;exports.HasPermission=h;exports.PermissionRoute=P;exports.getUseHasPermission=a;exports.useGetPermission=c;
|
package/dist/share/index.js
CHANGED
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
import {
|
|
1
|
+
import { N as R, O as S, R as G, a1 as y, Z as F, a as H, c as I, $ as N, V as O, T as $, U as j, W as w, v as M, a0 as U, t as V, X, b as Y, u as Z, g as _, Y as b } from "../index.module-aa83269c.js";
|
|
2
2
|
import u from "axios";
|
|
3
3
|
import { useState as m, useEffect as c } from "react";
|
|
4
4
|
import { jsx as a, Fragment as n } from "react/jsx-runtime";
|
|
@@ -43,13 +43,13 @@ export {
|
|
|
43
43
|
F as TranslationProvider,
|
|
44
44
|
H as axiosInstance,
|
|
45
45
|
I as color,
|
|
46
|
-
|
|
46
|
+
N as createCustomTheme,
|
|
47
47
|
i as getUseHasPermission,
|
|
48
|
-
|
|
49
|
-
|
|
50
|
-
|
|
51
|
-
|
|
52
|
-
|
|
48
|
+
O as handleErrorAxios,
|
|
49
|
+
$ as login,
|
|
50
|
+
j as logout,
|
|
51
|
+
w as responseInterceptor,
|
|
52
|
+
M as search,
|
|
53
53
|
U as setFavicon,
|
|
54
54
|
V as translate,
|
|
55
55
|
X as translationConfig,
|
package/package.json
CHANGED
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@ukpc-lib/react",
|
|
3
3
|
"private": false,
|
|
4
|
-
"version": "0.10.
|
|
4
|
+
"version": "0.10.6",
|
|
5
5
|
"type": "module",
|
|
6
6
|
"main": "./dist/",
|
|
7
7
|
"module": "./dist/",
|
|
@@ -112,4 +112,4 @@
|
|
|
112
112
|
"author": "Thinh Phung",
|
|
113
113
|
"description": "React components library",
|
|
114
114
|
"license": "ISC"
|
|
115
|
-
}
|
|
115
|
+
}
|