react-ecosistema-unp 1.7.9-pre.4 → 1.7.9-pre.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.
|
@@ -1 +1 @@
|
|
|
1
|
-
.nav{background:#f8f9fa;padding-top:.66rem}.nav-tabs{padding-left:.66rem;padding-right:1.75rem;--bs-nav-tabs-link-active-color: #074470;--bs-nav-tabs-link-active-bg: #ffffff;--bs-nav-tabs-link-hover-border-color: #c3c3c3 !important;--bs-nav-link-color: #697580;--bs-nav-link-hover-color: #344754}.nav-item{font-weight:500}.nav-link{padding:.55rem 1.75rem .66rem;border-top-color:#e8e8e8!important;border-right-color:#e8e8e8!important;--bs-nav-tabs-border-radius: 10px}.nav-link:hover{border-top-color:#c3c3c3!important;border-right-color:#c3c3c3!important}.nav-link.active{border-top-color:#dee2e6!important;border-right-color:#dee2e6!important}.tab-content{padding:.5rem;height:calc(100vh - 3.813rem);overflow-y:auto}.tab-content::-webkit-scrollbar{width:12px}.tab-content::-webkit-scrollbar-track{background:transparent}.tab-content::-webkit-scrollbar-thumb{background-color:#303d50;border-radius:20px;border:3px solid transparent;background-clip:padding-box}
|
|
1
|
+
.nav{background:#f8f9fa;padding-top:.66rem}.nav-tabs{padding-left:.66rem;padding-right:1.75rem;--bs-nav-tabs-link-active-color: #074470;--bs-nav-tabs-link-active-bg: #ffffff;--bs-nav-tabs-link-hover-border-color: #c3c3c3 !important;--bs-nav-link-color: #697580;--bs-nav-link-hover-color: #344754}.nav-item{font-weight:500}.nav-link{padding:.55rem 1.75rem .66rem;border-top-color:#e8e8e8!important;border-right-color:#e8e8e8!important;border-left-color:#e8e8e8!important;--bs-nav-tabs-border-radius: 10px}.nav-link:hover{border-top-color:#c3c3c3!important;border-right-color:#c3c3c3!important;border-left-color:#c3c3c3!important}.nav-link.active{border-top-color:#dee2e6!important;border-right-color:#dee2e6!important;border-left-color:#dee2e6!important}.tab-content{padding:.5rem;height:calc(100vh - 3.813rem);overflow-y:auto}.tab-content::-webkit-scrollbar{width:12px}.tab-content::-webkit-scrollbar-track{background:transparent}.tab-content::-webkit-scrollbar-thumb{background-color:#303d50;border-radius:20px;border:3px solid transparent;background-clip:padding-box}
|
package/dist/assets/Tabla.css
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
.table_container{display:flex;flex-direction:column;gap:1.5rem;text-align:center}.table-scroll{position:relative;max-height:70vh;overflow-y:auto;overflow-x:auto;margin-right:5px;margin-left:5px;border-radius:10px;box-shadow:0 2px 12px #00000016;background:#f9fafa}@media (max-height: 780px){.table-scroll{max-height:65vh!important}}@media (max-height: 670px){.table-scroll{max-height:60vh!important}}@media (max-height: 590px){.table-scroll{max-height:55vh!important}}@media (max-height: 520px){.table-scroll{max-height:50vh!important}}@media (max-height: 470px){.table-scroll{max-height:40vh!important}}.table-scroll th,.table-scroll td{white-space:nowrap;word-wrap:normal;min-width:100px;padding-left:15px;padding-right:15px}.table-scroll::-webkit-scrollbar{width:16px}.table-scroll::-webkit-scrollbar-track{background:linear-gradient(to bottom right,#f9fafa,#f9fafa,#fff);border-top-right-radius:10px;border-bottom-right-radius:10px}.table-scroll::-webkit-scrollbar-thumb{background-color:#303d50;border-radius:10px;border:6px solid transparent;background-clip:padding-box}thead tr th{background-color:#fff!important;border-bottom:1px solid #DEE2E6!important;position:sticky;top:0;z-index:2}.table td,.table th{text-align:center;vertical-align:middle}.table{margin-bottom:0!important}.table-header-unp{background-color:#f9fafa!important;color:#2c2c2c!important;font-weight:600;font-size:1.1rem;padding:1.25rem
|
|
1
|
+
.table_container{display:flex;flex-direction:column;gap:1.5rem;text-align:center}.table-scroll{position:relative;max-height:70vh;overflow-y:auto;overflow-x:auto;margin-right:5px;margin-left:5px;border-radius:10px;box-shadow:0 2px 12px #00000016;background:#f9fafa}@media (max-height: 780px){.table-scroll{max-height:65vh!important}}@media (max-height: 670px){.table-scroll{max-height:60vh!important}}@media (max-height: 590px){.table-scroll{max-height:55vh!important}}@media (max-height: 520px){.table-scroll{max-height:50vh!important}}@media (max-height: 470px){.table-scroll{max-height:40vh!important}}.table-scroll th,.table-scroll td{white-space:nowrap;word-wrap:normal;min-width:100px;padding-left:15px;padding-right:15px}.table-scroll::-webkit-scrollbar{width:16px}.table-scroll::-webkit-scrollbar-track{background:linear-gradient(to bottom right,#f9fafa,#f9fafa,#fff);border-top-right-radius:10px;border-bottom-right-radius:10px}.table-scroll::-webkit-scrollbar-thumb{background-color:#303d50;border-radius:10px;border:6px solid transparent;background-clip:padding-box}thead tr th{background-color:#fff!important;border-bottom:1px solid #DEE2E6!important;position:sticky;top:0;z-index:2}.table td,.table th{text-align:center;vertical-align:middle}.table{margin-bottom:0!important}.table-header-unp{background-color:#f9fafa!important;color:#2c2c2c!important;font-weight:600;font-size:1.1rem;padding:1.25rem 1rem!important}.cell-with-modal{transition:background-color .3s ease}.cell-with-modal:hover{background-color:#303d50!important;color:#fff;font-weight:600}.data-count,.data-unp{font-weight:500;font-size:.85rem;margin-top:1rem;margin-left:5px;margin-right:5px;color:#8c8c8f}.animation-container{gap:2rem;height:73vh;display:flex;flex-direction:column;justify-content:center;align-items:center;color:#919191}@media (min-width: 1800px){.table-scroll{max-height:75vh}}.search-column-input{border-radius:11px!important;padding-right:25px!important;box-shadow:0 1px 6px #00000012!important}.cell-redirect:hover{background-color:#3c2970;color:#fff;font-weight:600;cursor:pointer}
|
|
@@ -1,18 +1,17 @@
|
|
|
1
1
|
window.originalFetch = window.fetch.bind(window);
|
|
2
2
|
let l = !1, h = null;
|
|
3
|
-
const
|
|
4
|
-
async function
|
|
5
|
-
const e = `${`${window.location.protocol}//${window.location.host}/`}api-auth/auth/refresh_token/`,
|
|
3
|
+
const s = [];
|
|
4
|
+
async function k() {
|
|
5
|
+
const e = `${`${window.location.protocol}//${window.location.host}/`}api-auth/auth/refresh_token/`, i = await window.originalFetch(e, {
|
|
6
6
|
method: "POST",
|
|
7
7
|
credentials: "include"
|
|
8
8
|
});
|
|
9
|
-
if (!
|
|
10
|
-
throw new Error("Error al refrescar token, status " +
|
|
9
|
+
if (!i.ok)
|
|
10
|
+
throw new Error("Error al refrescar token, status " + i.status);
|
|
11
11
|
return "Token refreshed";
|
|
12
12
|
}
|
|
13
13
|
window.fetch = async function(o, e) {
|
|
14
|
-
|
|
15
|
-
if (console.log("URL petición librería:", t), t.includes("/api-auth/"))
|
|
14
|
+
if ((typeof o == "string" ? o : o.toString()).includes("/api-auth/"))
|
|
16
15
|
return window.originalFetch(o, e);
|
|
17
16
|
e = e || {};
|
|
18
17
|
const u = sessionStorage.getItem("user_token");
|
|
@@ -21,36 +20,36 @@ window.fetch = async function(o, e) {
|
|
|
21
20
|
...u ? { Authorization: u } : {}
|
|
22
21
|
};
|
|
23
22
|
try {
|
|
24
|
-
const a = `${window.location.protocol}//${window.location.host}/`,
|
|
25
|
-
if (
|
|
26
|
-
const
|
|
27
|
-
if (!
|
|
28
|
-
return
|
|
29
|
-
if (
|
|
23
|
+
const a = `${window.location.protocol}//${window.location.host}/`, t = await window.originalFetch(o, e);
|
|
24
|
+
if (t.status !== 401) {
|
|
25
|
+
const r = await t.clone().text();
|
|
26
|
+
if (!r.includes("Signature has expired"))
|
|
27
|
+
return t;
|
|
28
|
+
if (r.includes("Invalid or expired token"))
|
|
30
29
|
return sessionStorage.removeItem("user_token"), setTimeout(() => {
|
|
31
30
|
window.location.href = a;
|
|
32
|
-
}, 1e3),
|
|
31
|
+
}, 1e3), t;
|
|
33
32
|
}
|
|
34
|
-
return new Promise((w,
|
|
35
|
-
|
|
36
|
-
|
|
33
|
+
return new Promise((w, r) => {
|
|
34
|
+
s.push({ input: o, init: e, resolve: w, reject: r }), l || (l = !0, h = k(), h.then(() => {
|
|
35
|
+
s.forEach(({ input: c, init: n, resolve: d, reject: f }) => {
|
|
37
36
|
const g = {
|
|
38
|
-
...
|
|
39
|
-
headers: { ...
|
|
37
|
+
...n,
|
|
38
|
+
headers: { ...n.headers, Authorization: sessionStorage.getItem("user_token") }
|
|
40
39
|
};
|
|
41
40
|
window.originalFetch(c, g).then(d).catch(f);
|
|
42
41
|
});
|
|
43
42
|
}).catch((c) => {
|
|
44
|
-
|
|
43
|
+
s.forEach(({ reject: n }) => n(c));
|
|
45
44
|
}).finally(() => {
|
|
46
|
-
|
|
45
|
+
s.length = 0, l = !1, h = null;
|
|
47
46
|
}));
|
|
48
47
|
});
|
|
49
48
|
} catch (a) {
|
|
50
49
|
return Promise.reject(a);
|
|
51
50
|
}
|
|
52
51
|
};
|
|
53
|
-
const
|
|
52
|
+
const p = {};
|
|
54
53
|
export {
|
|
55
|
-
|
|
54
|
+
p as default
|
|
56
55
|
};
|
package/package.json
CHANGED
|
@@ -2,7 +2,7 @@
|
|
|
2
2
|
"name": "react-ecosistema-unp",
|
|
3
3
|
"author": "Ecosistema de Información - Unidad Nacional de Protección",
|
|
4
4
|
"private": false,
|
|
5
|
-
"version": "1.7.9-pre.
|
|
5
|
+
"version": "1.7.9-pre.6",
|
|
6
6
|
"type": "module",
|
|
7
7
|
"exports": {
|
|
8
8
|
".": {
|
|
@@ -37,6 +37,7 @@
|
|
|
37
37
|
"types": "./dist/lib/data.d.ts",
|
|
38
38
|
"default": "./dist/data.js"
|
|
39
39
|
},
|
|
40
|
+
"./styles/EcoStyles.css": "./dist/assets/Bootstrap.css",
|
|
40
41
|
"./utils/fetchInterceptor.js": "./dist/utils/fetch-interceptor/fetchInterceptor.js"
|
|
41
42
|
},
|
|
42
43
|
"files": [
|