@prozilla-os/settings 1.1.15 → 1.1.17
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/LICENSE +20 -20
- package/README.md +80 -80
- package/dist/main.js +568 -562
- package/dist/main.js.map +1 -1
- package/package.json +5 -5
package/dist/main.js
CHANGED
|
@@ -1,40 +1,40 @@
|
|
|
1
|
-
(function(){"use strict";try{if(typeof document<"u"){var o=document.createElement("style");o.appendChild(document.createTextNode('.
|
|
2
|
-
import { App as bt, AppsConfig as mt, useVirtualRoot as we, useWindowsManager as Ye, useSystemManager as me, useHistory as Ot, useAlert as At, useWindowedModal as ht, useContextMenu as
|
|
3
|
-
import { jsxs as
|
|
1
|
+
(function(){"use strict";try{if(typeof document<"u"){var o=document.createElement("style");o.appendChild(document.createTextNode('._SettingsContainer_12j2h_1{width:100%;height:100%;position:sticky;top:0;left:0}._Settings_12j2h_1{--tabs-width: 10rem;flex:1;display:flex;width:100%;height:100%;background-color:var(--background-color-2)}._Tabs_12j2h_19{display:flex;gap:.25rem;flex-direction:column;min-width:calc(var(--tabs-width) / 2);width:var(--tabs-width);height:100%;max-width:50%;padding:.5rem;margin:0;background-color:var(--background-color-2);resize:horizontal;overflow:hidden}._TabButton_12j2h_34{display:flex;gap:.5rem;align-items:center;width:100%;min-width:fit-content;padding:.75rem;border-radius:var(--border-radius-1);font-size:.875rem}._TabButton_12j2h_34._ActiveTab_12j2h_45{background-color:var(--background-color-0)}._TabButton_12j2h_34:not(._ActiveTab_12j2h_45):hover,._TabButton_12j2h_34:not(._ActiveTab_12j2h_45):focus-visible{background-color:color-mix(in srgb,var(--background-color-0) 50%,transparent)}._TabButton_12j2h_34>svg{height:1.35rem;aspect-ratio:1}._TabButton_12j2h_34>p{margin:0}._TabPanel_12j2h_63{flex:1;display:flex;flex-direction:column;align-content:flex-start;height:100%;padding:.5rem 1rem;background-color:var(--background-color-3);overflow:auto}._TabPanel_12j2h_63:not(._ActivePanel_12j2h_74){display:none}._Option_12j2h_78{display:flex;flex-direction:column;align-items:flex-start;justify-content:flex-start;text-align:start;width:100%;padding-bottom:1rem}._OptionList_12j2h_88{gap:.5rem}._OptionList_12j2h_88 ._Option_12j2h_78{padding-bottom:0}._OptionHorizontal_12j2h_96{flex-direction:row;justify-content:space-between}._Option_12j2h_78>._Label_12j2h_101{color:var(--foreground-color-0)}._Input_12j2h_105{display:flex;gap:.5rem;flex-wrap:wrap}._Input_12j2h_105>label{flex:1;display:flex}._ImageSelectContainer_12j2h_116{display:grid;grid-template-columns:repeat(auto-fit,minmax(15rem,1fr));gap:.5rem}._ImageSelect_12j2h_116{display:block;width:100%}._ImageSelect_12j2h_116>input{position:absolute;opacity:0;width:0;height:0}._ImageSelect_12j2h_116>input:hover+img,._ImageSelect_12j2h_116>input:focus-visible+img{filter:brightness(110%)}._ImageSelect_12j2h_116>input:checked+img{outline:.25em solid var(--foreground-color-0)}._ImageSelect_12j2h_116>img{width:100%;height:100%;border-radius:var(--border-radius-1);transition:filter var(--transition-duration-0) var(--ease-in-out-default);cursor:pointer}._ButtonGroup_12j2h_151{display:flex;gap:1rem;flex-wrap:wrap;margin:.75rem 0}._ButtonGroup_12j2h_151 ._Button_12j2h_151{margin-bottom:0}._Button_12j2h_151{--normal-color: var(--background-color-0) !important;--hover-color: var(--background-color-1) !important;margin-bottom:.75rem!important;padding:.5rem 1rem;border-radius:var(--border-radius-1)}._ButtonDanger_12j2h_171{--text-color: var(--black-1) !important;--normal-color: var(--red-0) !important;--hover-color: var(--red-1) !important}._IconButton_12j2h_177{--color: var(--foreground-color-0);position:relative;height:1.25rem;width:auto;padding:0;background:none;border:none;outline:none;aspect-ratio:1;cursor:pointer}._IconButton_12j2h_177:after{content:"";position:absolute;top:0;left:0;width:100%;height:100%;background-color:#fff0;border-radius:var(--border-radius-99);transform:scale(1);transform-origin:center;transition:all var(--transition-duration-1) var(--ease-in-out-default)}._IconButton_12j2h_177:hover:after,._IconButton_12j2h_177:focus-visible:after{background-color:#ffffff1a;transform:scale(1.5)}._IconButton_12j2h_177:disabled{--color: var(--foreground-color-2)}._IconButton_12j2h_177 svg{height:100%}._IconButton_12j2h_177 svg path{fill:var(--color);transition:fill var(--transition-duration-0) var(--ease-in-out-default)}._ProgressBarContainer_12j2h_223{width:100%;max-width:35rem}._ProgressBar_12j2h_223{width:100%!important}._ProgressBarLabels_12j2h_232{display:flex;justify-content:space-between;width:100%}._Option_12j2h_78>span._Label_12j2h_101{display:flex;gap:.5rem;align-items:center}._Icon_12j2h_177{display:inline-block;width:2rem;height:2rem}._Icon_12j2h_177 div{width:inherit;height:inherit}._Icon_12j2h_177 div>svg{width:inherit;height:inherit;object-fit:contain}._Dropdown_12j2h_261{width:auto;max-width:calc(60% - var(--gap));padding:.5rem 1rem;color:var(--text-color);background-color:var(--background-color-0);border:none;border-radius:var(--border-radius-1);outline:none;font-size:.875em}._Dropdown_12j2h_261>*{color:inherit;background-color:inherit;border:none;border-radius:var(--border-radius-1);outline:none;font-family:inherit;font-size:inherit}')),document.head.appendChild(o)}}catch(r){console.error("vite-plugin-css-injected-by-js",r)}})();
|
|
2
|
+
import { App as bt, AppsConfig as mt, useVirtualRoot as we, useWindowsManager as Ye, useSystemManager as me, useHistory as Ot, useAlert as At, useWindowedModal as ht, useContextMenu as Me, Actions as Fe, ClickAction as re, Vector2 as be, Divider as Rt, VirtualRoot as Je, DialogBox as Ze, ModalsConfig as Qe, DirectoryList as $t, CODE_EXTENSIONS as jt, utilStyles as H, WindowedModal as Bt, ImagePreview as Ue, StorageManager as ue, VirtualFile as Lt, useSettingsManager as qe, SettingsManager as Ee, Button as Se, IMAGE_EXTENSIONS as kt, ProgressBar as Dt } from "@prozilla-os/core";
|
|
3
|
+
import { jsxs as x, jsx as s, Fragment as vt } from "react/jsx-runtime";
|
|
4
4
|
import { FontAwesomeIcon as X } from "@fortawesome/react-fontawesome";
|
|
5
|
-
import { faTrash as et, faCircleInfo as
|
|
6
|
-
import pe, { Children as
|
|
5
|
+
import { faUpload as Mt, faTrash as et, faCircleInfo as yt, faCaretLeft as Ft, faCaretRight as Ut, faArrowUp as zt, faPlus as Wt, faSearch as Yt, faCog as qt, faHouse as Vt, faDesktop as Kt, faImage as Ht, faFileLines as Gt, faDownload as Xt, faThumbTack as Jt, faEllipsisVertical as Zt, faShapes as Qt, faPalette as en, faHardDrive as tn } from "@fortawesome/free-solid-svg-icons";
|
|
6
|
+
import pe, { Children as gt, cloneElement as _e, useRef as Te, useId as nn, useState as te, useEffect as se, useCallback as rn } from "react";
|
|
7
7
|
import { Theme as tt } from "@prozilla-os/skins";
|
|
8
|
-
import { round as Ae, removeFromArray as
|
|
9
|
-
const
|
|
10
|
-
SettingsContainer:
|
|
11
|
-
Settings:
|
|
12
|
-
Tabs:
|
|
8
|
+
import { round as Ae, removeFromArray as on } from "@prozilla-os/shared";
|
|
9
|
+
const an = "_SettingsContainer_12j2h_1", sn = "_Settings_12j2h_1", ln = "_Tabs_12j2h_19", cn = "_TabButton_12j2h_34", un = "_ActiveTab_12j2h_45", dn = "_TabPanel_12j2h_63", fn = "_ActivePanel_12j2h_74", pn = "_Option_12j2h_78", bn = "_OptionList_12j2h_88", mn = "_OptionHorizontal_12j2h_96", hn = "_Label_12j2h_101", vn = "_Input_12j2h_105", yn = "_ImageSelectContainer_12j2h_116", gn = "_ImageSelect_12j2h_116", _n = "_ButtonGroup_12j2h_151", Tn = "_Button_12j2h_151", xn = "_ButtonDanger_12j2h_171", En = "_IconButton_12j2h_177", Sn = "_ProgressBarContainer_12j2h_223", Cn = "_ProgressBar_12j2h_223", Pn = "_ProgressBarLabels_12j2h_232", wn = "_Icon_12j2h_177", Nn = "_Dropdown_12j2h_261", E = {
|
|
10
|
+
SettingsContainer: an,
|
|
11
|
+
Settings: sn,
|
|
12
|
+
Tabs: ln,
|
|
13
13
|
TabButton: cn,
|
|
14
|
-
ActiveTab:
|
|
15
|
-
TabPanel:
|
|
16
|
-
ActivePanel:
|
|
17
|
-
Option:
|
|
18
|
-
OptionList:
|
|
19
|
-
OptionHorizontal:
|
|
20
|
-
Label:
|
|
21
|
-
Input:
|
|
22
|
-
ImageSelectContainer:
|
|
14
|
+
ActiveTab: un,
|
|
15
|
+
TabPanel: dn,
|
|
16
|
+
ActivePanel: fn,
|
|
17
|
+
Option: pn,
|
|
18
|
+
OptionList: bn,
|
|
19
|
+
OptionHorizontal: mn,
|
|
20
|
+
Label: hn,
|
|
21
|
+
Input: vn,
|
|
22
|
+
ImageSelectContainer: yn,
|
|
23
23
|
ImageSelect: gn,
|
|
24
|
-
ButtonGroup:
|
|
25
|
-
Button:
|
|
26
|
-
ButtonDanger:
|
|
24
|
+
ButtonGroup: _n,
|
|
25
|
+
Button: Tn,
|
|
26
|
+
ButtonDanger: xn,
|
|
27
27
|
IconButton: En,
|
|
28
28
|
ProgressBarContainer: Sn,
|
|
29
|
-
ProgressBar:
|
|
30
|
-
ProgressBarLabels:
|
|
31
|
-
Icon:
|
|
32
|
-
Dropdown:
|
|
29
|
+
ProgressBar: Cn,
|
|
30
|
+
ProgressBarLabels: Pn,
|
|
31
|
+
Icon: wn,
|
|
32
|
+
Dropdown: Nn
|
|
33
33
|
};
|
|
34
|
-
function
|
|
34
|
+
function In(e) {
|
|
35
35
|
return e && e.__esModule && Object.prototype.hasOwnProperty.call(e, "default") ? e.default : e;
|
|
36
36
|
}
|
|
37
|
-
var ze = { exports: {} },
|
|
37
|
+
var ze = { exports: {} }, ye = { exports: {} }, D = {};
|
|
38
38
|
/** @license React v16.13.1
|
|
39
39
|
* react-is.production.min.js
|
|
40
40
|
*
|
|
@@ -44,29 +44,29 @@ var ze = { exports: {} }, ge = { exports: {} }, D = {};
|
|
|
44
44
|
* LICENSE file in the root directory of this source tree.
|
|
45
45
|
*/
|
|
46
46
|
var nt;
|
|
47
|
-
function
|
|
47
|
+
function On() {
|
|
48
48
|
if (nt) return D;
|
|
49
49
|
nt = 1;
|
|
50
|
-
var e = typeof Symbol == "function" && Symbol.for, n = e ? Symbol.for("react.element") : 60103, t = e ? Symbol.for("react.portal") : 60106, r = e ? Symbol.for("react.fragment") : 60107,
|
|
50
|
+
var e = typeof Symbol == "function" && Symbol.for, n = e ? Symbol.for("react.element") : 60103, t = e ? Symbol.for("react.portal") : 60106, r = e ? Symbol.for("react.fragment") : 60107, l = e ? Symbol.for("react.strict_mode") : 60108, a = e ? Symbol.for("react.profiler") : 60114, h = e ? Symbol.for("react.provider") : 60109, i = e ? Symbol.for("react.context") : 60110, y = e ? Symbol.for("react.async_mode") : 60111, v = e ? Symbol.for("react.concurrent_mode") : 60111, d = e ? Symbol.for("react.forward_ref") : 60112, C = e ? Symbol.for("react.suspense") : 60113, k = e ? Symbol.for("react.suspense_list") : 60120, P = e ? Symbol.for("react.memo") : 60115, N = e ? Symbol.for("react.lazy") : 60116, S = e ? Symbol.for("react.block") : 60121, F = e ? Symbol.for("react.fundamental") : 60117, q = e ? Symbol.for("react.responder") : 60118, Q = e ? Symbol.for("react.scope") : 60119;
|
|
51
51
|
function z(u) {
|
|
52
52
|
if (typeof u == "object" && u !== null) {
|
|
53
53
|
var ee = u.$$typeof;
|
|
54
54
|
switch (ee) {
|
|
55
55
|
case n:
|
|
56
56
|
switch (u = u.type, u) {
|
|
57
|
-
case
|
|
57
|
+
case y:
|
|
58
58
|
case v:
|
|
59
59
|
case r:
|
|
60
60
|
case a:
|
|
61
|
-
case
|
|
62
|
-
case
|
|
61
|
+
case l:
|
|
62
|
+
case C:
|
|
63
63
|
return u;
|
|
64
64
|
default:
|
|
65
65
|
switch (u = u && u.$$typeof, u) {
|
|
66
66
|
case i:
|
|
67
67
|
case d:
|
|
68
68
|
case N:
|
|
69
|
-
case
|
|
69
|
+
case P:
|
|
70
70
|
case h:
|
|
71
71
|
return u;
|
|
72
72
|
default:
|
|
@@ -81,8 +81,8 @@ function In() {
|
|
|
81
81
|
function U(u) {
|
|
82
82
|
return z(u) === v;
|
|
83
83
|
}
|
|
84
|
-
return D.AsyncMode =
|
|
85
|
-
return U(u) || z(u) ===
|
|
84
|
+
return D.AsyncMode = y, D.ConcurrentMode = v, D.ContextConsumer = i, D.ContextProvider = h, D.Element = n, D.ForwardRef = d, D.Fragment = r, D.Lazy = N, D.Memo = P, D.Portal = t, D.Profiler = a, D.StrictMode = l, D.Suspense = C, D.isAsyncMode = function(u) {
|
|
85
|
+
return U(u) || z(u) === y;
|
|
86
86
|
}, D.isConcurrentMode = U, D.isContextConsumer = function(u) {
|
|
87
87
|
return z(u) === i;
|
|
88
88
|
}, D.isContextProvider = function(u) {
|
|
@@ -96,17 +96,17 @@ function In() {
|
|
|
96
96
|
}, D.isLazy = function(u) {
|
|
97
97
|
return z(u) === N;
|
|
98
98
|
}, D.isMemo = function(u) {
|
|
99
|
-
return z(u) ===
|
|
99
|
+
return z(u) === P;
|
|
100
100
|
}, D.isPortal = function(u) {
|
|
101
101
|
return z(u) === t;
|
|
102
102
|
}, D.isProfiler = function(u) {
|
|
103
103
|
return z(u) === a;
|
|
104
104
|
}, D.isStrictMode = function(u) {
|
|
105
|
-
return z(u) ===
|
|
105
|
+
return z(u) === l;
|
|
106
106
|
}, D.isSuspense = function(u) {
|
|
107
|
-
return z(u) ===
|
|
107
|
+
return z(u) === C;
|
|
108
108
|
}, D.isValidElementType = function(u) {
|
|
109
|
-
return typeof u == "string" || typeof u == "function" || u === r || u === v || u === a || u ===
|
|
109
|
+
return typeof u == "string" || typeof u == "function" || u === r || u === v || u === a || u === l || u === C || u === k || typeof u == "object" && u !== null && (u.$$typeof === N || u.$$typeof === P || u.$$typeof === h || u.$$typeof === i || u.$$typeof === d || u.$$typeof === F || u.$$typeof === q || u.$$typeof === Q || u.$$typeof === S);
|
|
110
110
|
}, D.typeOf = z, D;
|
|
111
111
|
}
|
|
112
112
|
var M = {};
|
|
@@ -119,26 +119,26 @@ var M = {};
|
|
|
119
119
|
* LICENSE file in the root directory of this source tree.
|
|
120
120
|
*/
|
|
121
121
|
var rt;
|
|
122
|
-
function
|
|
122
|
+
function An() {
|
|
123
123
|
return rt || (rt = 1, process.env.NODE_ENV !== "production" && function() {
|
|
124
|
-
var e = typeof Symbol == "function" && Symbol.for, n = e ? Symbol.for("react.element") : 60103, t = e ? Symbol.for("react.portal") : 60106, r = e ? Symbol.for("react.fragment") : 60107,
|
|
125
|
-
function z(
|
|
126
|
-
return typeof
|
|
127
|
-
|
|
124
|
+
var e = typeof Symbol == "function" && Symbol.for, n = e ? Symbol.for("react.element") : 60103, t = e ? Symbol.for("react.portal") : 60106, r = e ? Symbol.for("react.fragment") : 60107, l = e ? Symbol.for("react.strict_mode") : 60108, a = e ? Symbol.for("react.profiler") : 60114, h = e ? Symbol.for("react.provider") : 60109, i = e ? Symbol.for("react.context") : 60110, y = e ? Symbol.for("react.async_mode") : 60111, v = e ? Symbol.for("react.concurrent_mode") : 60111, d = e ? Symbol.for("react.forward_ref") : 60112, C = e ? Symbol.for("react.suspense") : 60113, k = e ? Symbol.for("react.suspense_list") : 60120, P = e ? Symbol.for("react.memo") : 60115, N = e ? Symbol.for("react.lazy") : 60116, S = e ? Symbol.for("react.block") : 60121, F = e ? Symbol.for("react.fundamental") : 60117, q = e ? Symbol.for("react.responder") : 60118, Q = e ? Symbol.for("react.scope") : 60119;
|
|
125
|
+
function z(c) {
|
|
126
|
+
return typeof c == "string" || typeof c == "function" || // Note: its typeof might be other than 'symbol' or 'number' if it's a polyfill.
|
|
127
|
+
c === r || c === v || c === a || c === l || c === C || c === k || typeof c == "object" && c !== null && (c.$$typeof === N || c.$$typeof === P || c.$$typeof === h || c.$$typeof === i || c.$$typeof === d || c.$$typeof === F || c.$$typeof === q || c.$$typeof === Q || c.$$typeof === S);
|
|
128
128
|
}
|
|
129
|
-
function U(
|
|
130
|
-
if (typeof
|
|
131
|
-
var Z =
|
|
129
|
+
function U(c) {
|
|
130
|
+
if (typeof c == "object" && c !== null) {
|
|
131
|
+
var Z = c.$$typeof;
|
|
132
132
|
switch (Z) {
|
|
133
133
|
case n:
|
|
134
|
-
var ve =
|
|
134
|
+
var ve = c.type;
|
|
135
135
|
switch (ve) {
|
|
136
|
-
case
|
|
136
|
+
case y:
|
|
137
137
|
case v:
|
|
138
138
|
case r:
|
|
139
139
|
case a:
|
|
140
|
-
case
|
|
141
|
-
case
|
|
140
|
+
case l:
|
|
141
|
+
case C:
|
|
142
142
|
return ve;
|
|
143
143
|
default:
|
|
144
144
|
var Xe = ve && ve.$$typeof;
|
|
@@ -146,7 +146,7 @@ function On() {
|
|
|
146
146
|
case i:
|
|
147
147
|
case d:
|
|
148
148
|
case N:
|
|
149
|
-
case
|
|
149
|
+
case P:
|
|
150
150
|
case h:
|
|
151
151
|
return Xe;
|
|
152
152
|
default:
|
|
@@ -158,52 +158,52 @@ function On() {
|
|
|
158
158
|
}
|
|
159
159
|
}
|
|
160
160
|
}
|
|
161
|
-
var u =
|
|
162
|
-
function G(
|
|
163
|
-
return V || (V = !0, console.warn("The ReactIs.isAsyncMode() alias has been deprecated, and will be removed in React 17+. Update your code to use ReactIs.isConcurrentMode() instead. It has the exact same API.")), o(
|
|
161
|
+
var u = y, ee = v, ne = i, le = h, ce = n, J = d, oe = r, ae = N, m = P, f = t, g = a, w = l, j = C, V = !1;
|
|
162
|
+
function G(c) {
|
|
163
|
+
return V || (V = !0, console.warn("The ReactIs.isAsyncMode() alias has been deprecated, and will be removed in React 17+. Update your code to use ReactIs.isConcurrentMode() instead. It has the exact same API.")), o(c) || U(c) === y;
|
|
164
164
|
}
|
|
165
|
-
function o(
|
|
166
|
-
return U(
|
|
165
|
+
function o(c) {
|
|
166
|
+
return U(c) === v;
|
|
167
167
|
}
|
|
168
|
-
function
|
|
169
|
-
return U(
|
|
168
|
+
function p(c) {
|
|
169
|
+
return U(c) === i;
|
|
170
170
|
}
|
|
171
|
-
function A(
|
|
172
|
-
return U(
|
|
171
|
+
function A(c) {
|
|
172
|
+
return U(c) === h;
|
|
173
173
|
}
|
|
174
|
-
function O(
|
|
175
|
-
return typeof
|
|
174
|
+
function O(c) {
|
|
175
|
+
return typeof c == "object" && c !== null && c.$$typeof === n;
|
|
176
176
|
}
|
|
177
|
-
function _(
|
|
178
|
-
return U(
|
|
177
|
+
function _(c) {
|
|
178
|
+
return U(c) === d;
|
|
179
179
|
}
|
|
180
|
-
function R(
|
|
181
|
-
return U(
|
|
180
|
+
function R(c) {
|
|
181
|
+
return U(c) === r;
|
|
182
182
|
}
|
|
183
|
-
function T(
|
|
184
|
-
return U(
|
|
183
|
+
function T(c) {
|
|
184
|
+
return U(c) === N;
|
|
185
185
|
}
|
|
186
|
-
function I(
|
|
187
|
-
return U(
|
|
186
|
+
function I(c) {
|
|
187
|
+
return U(c) === P;
|
|
188
188
|
}
|
|
189
|
-
function B(
|
|
190
|
-
return U(
|
|
189
|
+
function B(c) {
|
|
190
|
+
return U(c) === t;
|
|
191
191
|
}
|
|
192
|
-
function L(
|
|
193
|
-
return U(
|
|
192
|
+
function L(c) {
|
|
193
|
+
return U(c) === a;
|
|
194
194
|
}
|
|
195
|
-
function $(
|
|
196
|
-
return U(
|
|
195
|
+
function $(c) {
|
|
196
|
+
return U(c) === l;
|
|
197
197
|
}
|
|
198
|
-
function Y(
|
|
199
|
-
return U(
|
|
198
|
+
function Y(c) {
|
|
199
|
+
return U(c) === C;
|
|
200
200
|
}
|
|
201
|
-
M.AsyncMode = u, M.ConcurrentMode = ee, M.ContextConsumer = ne, M.ContextProvider =
|
|
201
|
+
M.AsyncMode = u, M.ConcurrentMode = ee, M.ContextConsumer = ne, M.ContextProvider = le, M.Element = ce, M.ForwardRef = J, M.Fragment = oe, M.Lazy = ae, M.Memo = m, M.Portal = f, M.Profiler = g, M.StrictMode = w, M.Suspense = j, M.isAsyncMode = G, M.isConcurrentMode = o, M.isContextConsumer = p, M.isContextProvider = A, M.isElement = O, M.isForwardRef = _, M.isFragment = R, M.isLazy = T, M.isMemo = I, M.isPortal = B, M.isProfiler = L, M.isStrictMode = $, M.isSuspense = Y, M.isValidElementType = z, M.typeOf = U;
|
|
202
202
|
}()), M;
|
|
203
203
|
}
|
|
204
204
|
var ot;
|
|
205
205
|
function _t() {
|
|
206
|
-
return ot || (ot = 1, process.env.NODE_ENV === "production" ?
|
|
206
|
+
return ot || (ot = 1, process.env.NODE_ENV === "production" ? ye.exports = On() : ye.exports = An()), ye.exports;
|
|
207
207
|
}
|
|
208
208
|
/*
|
|
209
209
|
object-assign
|
|
@@ -211,7 +211,7 @@ object-assign
|
|
|
211
211
|
@license MIT
|
|
212
212
|
*/
|
|
213
213
|
var Re, at;
|
|
214
|
-
function
|
|
214
|
+
function Rn() {
|
|
215
215
|
if (at) return Re;
|
|
216
216
|
at = 1;
|
|
217
217
|
var e = Object.getOwnPropertySymbols, n = Object.prototype.hasOwnProperty, t = Object.prototype.propertyIsEnumerable;
|
|
@@ -220,7 +220,7 @@ function An() {
|
|
|
220
220
|
throw new TypeError("Object.assign cannot be called with null or undefined");
|
|
221
221
|
return Object(a);
|
|
222
222
|
}
|
|
223
|
-
function
|
|
223
|
+
function l() {
|
|
224
224
|
try {
|
|
225
225
|
if (!Object.assign)
|
|
226
226
|
return !1;
|
|
@@ -229,10 +229,10 @@ function An() {
|
|
|
229
229
|
return !1;
|
|
230
230
|
for (var h = {}, i = 0; i < 10; i++)
|
|
231
231
|
h["_" + String.fromCharCode(i)] = i;
|
|
232
|
-
var
|
|
232
|
+
var y = Object.getOwnPropertyNames(h).map(function(d) {
|
|
233
233
|
return h[d];
|
|
234
234
|
});
|
|
235
|
-
if (
|
|
235
|
+
if (y.join("") !== "0123456789")
|
|
236
236
|
return !1;
|
|
237
237
|
var v = {};
|
|
238
238
|
return "abcdefghijklmnopqrst".split("").forEach(function(d) {
|
|
@@ -242,18 +242,18 @@ function An() {
|
|
|
242
242
|
return !1;
|
|
243
243
|
}
|
|
244
244
|
}
|
|
245
|
-
return Re =
|
|
246
|
-
for (var i,
|
|
245
|
+
return Re = l() ? Object.assign : function(a, h) {
|
|
246
|
+
for (var i, y = r(a), v, d = 1; d < arguments.length; d++) {
|
|
247
247
|
i = Object(arguments[d]);
|
|
248
|
-
for (var
|
|
249
|
-
n.call(i,
|
|
248
|
+
for (var C in i)
|
|
249
|
+
n.call(i, C) && (y[C] = i[C]);
|
|
250
250
|
if (e) {
|
|
251
251
|
v = e(i);
|
|
252
252
|
for (var k = 0; k < v.length; k++)
|
|
253
|
-
t.call(i, v[k]) && (
|
|
253
|
+
t.call(i, v[k]) && (y[v[k]] = i[v[k]]);
|
|
254
254
|
}
|
|
255
255
|
}
|
|
256
|
-
return
|
|
256
|
+
return y;
|
|
257
257
|
}, Re;
|
|
258
258
|
}
|
|
259
259
|
var $e, it;
|
|
@@ -263,14 +263,14 @@ function Ve() {
|
|
|
263
263
|
var e = "SECRET_DO_NOT_PASS_THIS_OR_YOU_WILL_BE_FIRED";
|
|
264
264
|
return $e = e, $e;
|
|
265
265
|
}
|
|
266
|
-
var
|
|
266
|
+
var je, st;
|
|
267
267
|
function Tt() {
|
|
268
|
-
return st || (st = 1,
|
|
268
|
+
return st || (st = 1, je = Function.call.bind(Object.prototype.hasOwnProperty)), je;
|
|
269
269
|
}
|
|
270
|
-
var
|
|
271
|
-
function
|
|
272
|
-
if (
|
|
273
|
-
|
|
270
|
+
var Be, lt;
|
|
271
|
+
function $n() {
|
|
272
|
+
if (lt) return Be;
|
|
273
|
+
lt = 1;
|
|
274
274
|
var e = function() {
|
|
275
275
|
};
|
|
276
276
|
if (process.env.NODE_ENV !== "production") {
|
|
@@ -284,63 +284,63 @@ function Rn() {
|
|
|
284
284
|
}
|
|
285
285
|
};
|
|
286
286
|
}
|
|
287
|
-
function
|
|
287
|
+
function l(a, h, i, y, v) {
|
|
288
288
|
if (process.env.NODE_ENV !== "production") {
|
|
289
289
|
for (var d in a)
|
|
290
290
|
if (r(a, d)) {
|
|
291
|
-
var
|
|
291
|
+
var C;
|
|
292
292
|
try {
|
|
293
293
|
if (typeof a[d] != "function") {
|
|
294
294
|
var k = Error(
|
|
295
|
-
(
|
|
295
|
+
(y || "React class") + ": " + i + " type `" + d + "` is invalid; it must be a function, usually from the `prop-types` package, but received `" + typeof a[d] + "`.This often happens because of typos such as `PropTypes.function` instead of `PropTypes.func`."
|
|
296
296
|
);
|
|
297
297
|
throw k.name = "Invariant Violation", k;
|
|
298
298
|
}
|
|
299
|
-
|
|
299
|
+
C = a[d](h, d, y, i, null, n);
|
|
300
300
|
} catch (N) {
|
|
301
|
-
|
|
301
|
+
C = N;
|
|
302
302
|
}
|
|
303
|
-
if (
|
|
304
|
-
(
|
|
305
|
-
),
|
|
306
|
-
t[
|
|
307
|
-
var
|
|
303
|
+
if (C && !(C instanceof Error) && e(
|
|
304
|
+
(y || "React class") + ": type specification of " + i + " `" + d + "` is invalid; the type checker function must return `null` or an `Error` but returned a " + typeof C + ". You may have forgotten to pass an argument to the type checker creator (arrayOf, instanceOf, objectOf, oneOf, oneOfType, and shape all require an argument)."
|
|
305
|
+
), C instanceof Error && !(C.message in t)) {
|
|
306
|
+
t[C.message] = !0;
|
|
307
|
+
var P = v ? v() : "";
|
|
308
308
|
e(
|
|
309
|
-
"Failed " + i + " type: " +
|
|
309
|
+
"Failed " + i + " type: " + C.message + (P ?? "")
|
|
310
310
|
);
|
|
311
311
|
}
|
|
312
312
|
}
|
|
313
313
|
}
|
|
314
314
|
}
|
|
315
|
-
return
|
|
315
|
+
return l.resetWarningCache = function() {
|
|
316
316
|
process.env.NODE_ENV !== "production" && (t = {});
|
|
317
|
-
},
|
|
317
|
+
}, Be = l, Be;
|
|
318
318
|
}
|
|
319
|
-
var
|
|
320
|
-
function
|
|
321
|
-
if (
|
|
322
|
-
|
|
323
|
-
var e = _t(), n =
|
|
319
|
+
var Le, ct;
|
|
320
|
+
function jn() {
|
|
321
|
+
if (ct) return Le;
|
|
322
|
+
ct = 1;
|
|
323
|
+
var e = _t(), n = Rn(), t = Ve(), r = Tt(), l = $n(), a = function() {
|
|
324
324
|
};
|
|
325
325
|
process.env.NODE_ENV !== "production" && (a = function(i) {
|
|
326
|
-
var
|
|
327
|
-
typeof console < "u" && console.error(
|
|
326
|
+
var y = "Warning: " + i;
|
|
327
|
+
typeof console < "u" && console.error(y);
|
|
328
328
|
try {
|
|
329
|
-
throw new Error(
|
|
329
|
+
throw new Error(y);
|
|
330
330
|
} catch {
|
|
331
331
|
}
|
|
332
332
|
});
|
|
333
333
|
function h() {
|
|
334
334
|
return null;
|
|
335
335
|
}
|
|
336
|
-
return
|
|
336
|
+
return Le = function(i, y) {
|
|
337
337
|
var v = typeof Symbol == "function" && Symbol.iterator, d = "@@iterator";
|
|
338
|
-
function
|
|
339
|
-
var
|
|
340
|
-
if (typeof
|
|
341
|
-
return
|
|
338
|
+
function C(o) {
|
|
339
|
+
var p = o && (v && o[v] || o[d]);
|
|
340
|
+
if (typeof p == "function")
|
|
341
|
+
return p;
|
|
342
342
|
}
|
|
343
|
-
var k = "<<anonymous>>",
|
|
343
|
+
var k = "<<anonymous>>", P = {
|
|
344
344
|
array: q("array"),
|
|
345
345
|
bigint: q("bigint"),
|
|
346
346
|
bool: q("boolean"),
|
|
@@ -355,67 +355,67 @@ function $n() {
|
|
|
355
355
|
elementType: u(),
|
|
356
356
|
instanceOf: ee,
|
|
357
357
|
node: J(),
|
|
358
|
-
objectOf:
|
|
358
|
+
objectOf: le,
|
|
359
359
|
oneOf: ne,
|
|
360
|
-
oneOfType:
|
|
361
|
-
shape:
|
|
360
|
+
oneOfType: ce,
|
|
361
|
+
shape: ae,
|
|
362
362
|
exact: m
|
|
363
363
|
};
|
|
364
|
-
function N(o,
|
|
365
|
-
return o ===
|
|
364
|
+
function N(o, p) {
|
|
365
|
+
return o === p ? o !== 0 || 1 / o === 1 / p : o !== o && p !== p;
|
|
366
366
|
}
|
|
367
|
-
function
|
|
368
|
-
this.message = o, this.data =
|
|
367
|
+
function S(o, p) {
|
|
368
|
+
this.message = o, this.data = p && typeof p == "object" ? p : {}, this.stack = "";
|
|
369
369
|
}
|
|
370
|
-
|
|
370
|
+
S.prototype = Error.prototype;
|
|
371
371
|
function F(o) {
|
|
372
372
|
if (process.env.NODE_ENV !== "production")
|
|
373
|
-
var
|
|
373
|
+
var p = {}, A = 0;
|
|
374
374
|
function O(R, T, I, B, L, $, Y) {
|
|
375
375
|
if (B = B || k, $ = $ || I, Y !== t) {
|
|
376
|
-
if (
|
|
377
|
-
var
|
|
376
|
+
if (y) {
|
|
377
|
+
var c = new Error(
|
|
378
378
|
"Calling PropTypes validators directly is not supported by the `prop-types` package. Use `PropTypes.checkPropTypes()` to call them. Read more at http://fb.me/use-check-prop-types"
|
|
379
379
|
);
|
|
380
|
-
throw
|
|
380
|
+
throw c.name = "Invariant Violation", c;
|
|
381
381
|
} else if (process.env.NODE_ENV !== "production" && typeof console < "u") {
|
|
382
382
|
var Z = B + ":" + I;
|
|
383
|
-
!
|
|
383
|
+
!p[Z] && // Avoid spamming the console because they are often not actionable except for lib authors
|
|
384
384
|
A < 3 && (a(
|
|
385
385
|
"You are manually calling a React.PropTypes validation function for the `" + $ + "` prop on `" + B + "`. This is deprecated and will throw in the standalone `prop-types` package. You may be seeing this warning due to a third-party PropTypes library. See https://fb.me/react-warning-dont-call-proptypes for details."
|
|
386
|
-
),
|
|
386
|
+
), p[Z] = !0, A++);
|
|
387
387
|
}
|
|
388
388
|
}
|
|
389
|
-
return T[I] == null ? R ? T[I] === null ? new
|
|
389
|
+
return T[I] == null ? R ? T[I] === null ? new S("The " + L + " `" + $ + "` is marked as required " + ("in `" + B + "`, but its value is `null`.")) : new S("The " + L + " `" + $ + "` is marked as required in " + ("`" + B + "`, but its value is `undefined`.")) : null : o(T, I, B, L, $);
|
|
390
390
|
}
|
|
391
391
|
var _ = O.bind(null, !1);
|
|
392
392
|
return _.isRequired = O.bind(null, !0), _;
|
|
393
393
|
}
|
|
394
394
|
function q(o) {
|
|
395
|
-
function
|
|
396
|
-
var B = A[O], L =
|
|
395
|
+
function p(A, O, _, R, T, I) {
|
|
396
|
+
var B = A[O], L = w(B);
|
|
397
397
|
if (L !== o) {
|
|
398
398
|
var $ = j(B);
|
|
399
|
-
return new
|
|
399
|
+
return new S(
|
|
400
400
|
"Invalid " + R + " `" + T + "` of type " + ("`" + $ + "` supplied to `" + _ + "`, expected ") + ("`" + o + "`."),
|
|
401
401
|
{ expectedType: o }
|
|
402
402
|
);
|
|
403
403
|
}
|
|
404
404
|
return null;
|
|
405
405
|
}
|
|
406
|
-
return F(
|
|
406
|
+
return F(p);
|
|
407
407
|
}
|
|
408
408
|
function Q() {
|
|
409
409
|
return F(h);
|
|
410
410
|
}
|
|
411
411
|
function z(o) {
|
|
412
|
-
function
|
|
412
|
+
function p(A, O, _, R, T) {
|
|
413
413
|
if (typeof o != "function")
|
|
414
|
-
return new
|
|
414
|
+
return new S("Property `" + T + "` of component `" + _ + "` has invalid PropType notation inside arrayOf.");
|
|
415
415
|
var I = A[O];
|
|
416
416
|
if (!Array.isArray(I)) {
|
|
417
|
-
var B =
|
|
418
|
-
return new
|
|
417
|
+
var B = w(I);
|
|
418
|
+
return new S("Invalid " + R + " `" + T + "` of type " + ("`" + B + "` supplied to `" + _ + "`, expected an array."));
|
|
419
419
|
}
|
|
420
420
|
for (var L = 0; L < I.length; L++) {
|
|
421
421
|
var $ = o(I, L, _, R, T + "[" + L + "]", t);
|
|
@@ -424,64 +424,64 @@ function $n() {
|
|
|
424
424
|
}
|
|
425
425
|
return null;
|
|
426
426
|
}
|
|
427
|
-
return F(
|
|
427
|
+
return F(p);
|
|
428
428
|
}
|
|
429
429
|
function U() {
|
|
430
|
-
function o(
|
|
431
|
-
var T =
|
|
430
|
+
function o(p, A, O, _, R) {
|
|
431
|
+
var T = p[A];
|
|
432
432
|
if (!i(T)) {
|
|
433
|
-
var I =
|
|
434
|
-
return new
|
|
433
|
+
var I = w(T);
|
|
434
|
+
return new S("Invalid " + _ + " `" + R + "` of type " + ("`" + I + "` supplied to `" + O + "`, expected a single ReactElement."));
|
|
435
435
|
}
|
|
436
436
|
return null;
|
|
437
437
|
}
|
|
438
438
|
return F(o);
|
|
439
439
|
}
|
|
440
440
|
function u() {
|
|
441
|
-
function o(
|
|
442
|
-
var T =
|
|
441
|
+
function o(p, A, O, _, R) {
|
|
442
|
+
var T = p[A];
|
|
443
443
|
if (!e.isValidElementType(T)) {
|
|
444
|
-
var I =
|
|
445
|
-
return new
|
|
444
|
+
var I = w(T);
|
|
445
|
+
return new S("Invalid " + _ + " `" + R + "` of type " + ("`" + I + "` supplied to `" + O + "`, expected a single ReactElement type."));
|
|
446
446
|
}
|
|
447
447
|
return null;
|
|
448
448
|
}
|
|
449
449
|
return F(o);
|
|
450
450
|
}
|
|
451
451
|
function ee(o) {
|
|
452
|
-
function
|
|
452
|
+
function p(A, O, _, R, T) {
|
|
453
453
|
if (!(A[O] instanceof o)) {
|
|
454
454
|
var I = o.name || k, B = G(A[O]);
|
|
455
|
-
return new
|
|
455
|
+
return new S("Invalid " + R + " `" + T + "` of type " + ("`" + B + "` supplied to `" + _ + "`, expected ") + ("instance of `" + I + "`."));
|
|
456
456
|
}
|
|
457
457
|
return null;
|
|
458
458
|
}
|
|
459
|
-
return F(
|
|
459
|
+
return F(p);
|
|
460
460
|
}
|
|
461
461
|
function ne(o) {
|
|
462
462
|
if (!Array.isArray(o))
|
|
463
463
|
return process.env.NODE_ENV !== "production" && (arguments.length > 1 ? a(
|
|
464
464
|
"Invalid arguments supplied to oneOf, expected an array, got " + arguments.length + " arguments. A common mistake is to write oneOf(x, y, z) instead of oneOf([x, y, z])."
|
|
465
465
|
) : a("Invalid argument supplied to oneOf, expected an array.")), h;
|
|
466
|
-
function
|
|
466
|
+
function p(A, O, _, R, T) {
|
|
467
467
|
for (var I = A[O], B = 0; B < o.length; B++)
|
|
468
468
|
if (N(I, o[B]))
|
|
469
469
|
return null;
|
|
470
|
-
var L = JSON.stringify(o, function(Y,
|
|
471
|
-
var Z = j(
|
|
472
|
-
return Z === "symbol" ? String(
|
|
470
|
+
var L = JSON.stringify(o, function(Y, c) {
|
|
471
|
+
var Z = j(c);
|
|
472
|
+
return Z === "symbol" ? String(c) : c;
|
|
473
473
|
});
|
|
474
|
-
return new
|
|
474
|
+
return new S("Invalid " + R + " `" + T + "` of value `" + String(I) + "` " + ("supplied to `" + _ + "`, expected one of " + L + "."));
|
|
475
475
|
}
|
|
476
|
-
return F(
|
|
476
|
+
return F(p);
|
|
477
477
|
}
|
|
478
|
-
function
|
|
479
|
-
function
|
|
478
|
+
function le(o) {
|
|
479
|
+
function p(A, O, _, R, T) {
|
|
480
480
|
if (typeof o != "function")
|
|
481
|
-
return new
|
|
482
|
-
var I = A[O], B =
|
|
481
|
+
return new S("Property `" + T + "` of component `" + _ + "` has invalid PropType notation inside objectOf.");
|
|
482
|
+
var I = A[O], B = w(I);
|
|
483
483
|
if (B !== "object")
|
|
484
|
-
return new
|
|
484
|
+
return new S("Invalid " + R + " `" + T + "` of type " + ("`" + B + "` supplied to `" + _ + "`, expected an object."));
|
|
485
485
|
for (var L in I)
|
|
486
486
|
if (r(I, L)) {
|
|
487
487
|
var $ = o(I, L, _, R, T + "." + L, t);
|
|
@@ -490,82 +490,82 @@ function $n() {
|
|
|
490
490
|
}
|
|
491
491
|
return null;
|
|
492
492
|
}
|
|
493
|
-
return F(
|
|
493
|
+
return F(p);
|
|
494
494
|
}
|
|
495
|
-
function
|
|
495
|
+
function ce(o) {
|
|
496
496
|
if (!Array.isArray(o))
|
|
497
497
|
return process.env.NODE_ENV !== "production" && a("Invalid argument supplied to oneOfType, expected an instance of array."), h;
|
|
498
|
-
for (var
|
|
499
|
-
var A = o[
|
|
498
|
+
for (var p = 0; p < o.length; p++) {
|
|
499
|
+
var A = o[p];
|
|
500
500
|
if (typeof A != "function")
|
|
501
501
|
return a(
|
|
502
|
-
"Invalid argument supplied to oneOfType. Expected an array of check functions, but received " + V(A) + " at index " +
|
|
502
|
+
"Invalid argument supplied to oneOfType. Expected an array of check functions, but received " + V(A) + " at index " + p + "."
|
|
503
503
|
), h;
|
|
504
504
|
}
|
|
505
505
|
function O(_, R, T, I, B) {
|
|
506
506
|
for (var L = [], $ = 0; $ < o.length; $++) {
|
|
507
|
-
var Y = o[$],
|
|
508
|
-
if (
|
|
507
|
+
var Y = o[$], c = Y(_, R, T, I, B, t);
|
|
508
|
+
if (c == null)
|
|
509
509
|
return null;
|
|
510
|
-
|
|
510
|
+
c.data && r(c.data, "expectedType") && L.push(c.data.expectedType);
|
|
511
511
|
}
|
|
512
512
|
var Z = L.length > 0 ? ", expected one of type [" + L.join(", ") + "]" : "";
|
|
513
|
-
return new
|
|
513
|
+
return new S("Invalid " + I + " `" + B + "` supplied to " + ("`" + T + "`" + Z + "."));
|
|
514
514
|
}
|
|
515
515
|
return F(O);
|
|
516
516
|
}
|
|
517
517
|
function J() {
|
|
518
|
-
function o(
|
|
519
|
-
return p
|
|
518
|
+
function o(p, A, O, _, R) {
|
|
519
|
+
return f(p[A]) ? null : new S("Invalid " + _ + " `" + R + "` supplied to " + ("`" + O + "`, expected a ReactNode."));
|
|
520
520
|
}
|
|
521
521
|
return F(o);
|
|
522
522
|
}
|
|
523
|
-
function
|
|
524
|
-
return new
|
|
525
|
-
(o || "React class") + ": " +
|
|
523
|
+
function oe(o, p, A, O, _) {
|
|
524
|
+
return new S(
|
|
525
|
+
(o || "React class") + ": " + p + " type `" + A + "." + O + "` is invalid; it must be a function, usually from the `prop-types` package, but received `" + _ + "`."
|
|
526
526
|
);
|
|
527
527
|
}
|
|
528
|
-
function
|
|
529
|
-
function
|
|
530
|
-
var I = A[O], B =
|
|
528
|
+
function ae(o) {
|
|
529
|
+
function p(A, O, _, R, T) {
|
|
530
|
+
var I = A[O], B = w(I);
|
|
531
531
|
if (B !== "object")
|
|
532
|
-
return new
|
|
532
|
+
return new S("Invalid " + R + " `" + T + "` of type `" + B + "` " + ("supplied to `" + _ + "`, expected `object`."));
|
|
533
533
|
for (var L in o) {
|
|
534
534
|
var $ = o[L];
|
|
535
535
|
if (typeof $ != "function")
|
|
536
|
-
return
|
|
536
|
+
return oe(_, R, T, L, j($));
|
|
537
537
|
var Y = $(I, L, _, R, T + "." + L, t);
|
|
538
538
|
if (Y)
|
|
539
539
|
return Y;
|
|
540
540
|
}
|
|
541
541
|
return null;
|
|
542
542
|
}
|
|
543
|
-
return F(
|
|
543
|
+
return F(p);
|
|
544
544
|
}
|
|
545
545
|
function m(o) {
|
|
546
|
-
function
|
|
547
|
-
var I = A[O], B =
|
|
546
|
+
function p(A, O, _, R, T) {
|
|
547
|
+
var I = A[O], B = w(I);
|
|
548
548
|
if (B !== "object")
|
|
549
|
-
return new
|
|
549
|
+
return new S("Invalid " + R + " `" + T + "` of type `" + B + "` " + ("supplied to `" + _ + "`, expected `object`."));
|
|
550
550
|
var L = n({}, A[O], o);
|
|
551
551
|
for (var $ in L) {
|
|
552
552
|
var Y = o[$];
|
|
553
553
|
if (r(o, $) && typeof Y != "function")
|
|
554
|
-
return
|
|
554
|
+
return oe(_, R, T, $, j(Y));
|
|
555
555
|
if (!Y)
|
|
556
|
-
return new
|
|
556
|
+
return new S(
|
|
557
557
|
"Invalid " + R + " `" + T + "` key `" + $ + "` supplied to `" + _ + "`.\nBad object: " + JSON.stringify(A[O], null, " ") + `
|
|
558
558
|
Valid keys: ` + JSON.stringify(Object.keys(o), null, " ")
|
|
559
559
|
);
|
|
560
|
-
var
|
|
561
|
-
if (
|
|
562
|
-
return
|
|
560
|
+
var c = Y(I, $, _, R, T + "." + $, t);
|
|
561
|
+
if (c)
|
|
562
|
+
return c;
|
|
563
563
|
}
|
|
564
564
|
return null;
|
|
565
565
|
}
|
|
566
|
-
return F(
|
|
566
|
+
return F(p);
|
|
567
567
|
}
|
|
568
|
-
function
|
|
568
|
+
function f(o) {
|
|
569
569
|
switch (typeof o) {
|
|
570
570
|
case "number":
|
|
571
571
|
case "string":
|
|
@@ -575,20 +575,20 @@ Valid keys: ` + JSON.stringify(Object.keys(o), null, " ")
|
|
|
575
575
|
return !o;
|
|
576
576
|
case "object":
|
|
577
577
|
if (Array.isArray(o))
|
|
578
|
-
return o.every(
|
|
578
|
+
return o.every(f);
|
|
579
579
|
if (o === null || i(o))
|
|
580
580
|
return !0;
|
|
581
|
-
var
|
|
582
|
-
if (
|
|
583
|
-
var A =
|
|
584
|
-
if (
|
|
581
|
+
var p = C(o);
|
|
582
|
+
if (p) {
|
|
583
|
+
var A = p.call(o), O;
|
|
584
|
+
if (p !== o.entries) {
|
|
585
585
|
for (; !(O = A.next()).done; )
|
|
586
|
-
if (!
|
|
586
|
+
if (!f(O.value))
|
|
587
587
|
return !1;
|
|
588
588
|
} else
|
|
589
589
|
for (; !(O = A.next()).done; ) {
|
|
590
590
|
var _ = O.value;
|
|
591
|
-
if (_ && !
|
|
591
|
+
if (_ && !f(_[1]))
|
|
592
592
|
return !1;
|
|
593
593
|
}
|
|
594
594
|
} else
|
|
@@ -598,57 +598,57 @@ Valid keys: ` + JSON.stringify(Object.keys(o), null, " ")
|
|
|
598
598
|
return !1;
|
|
599
599
|
}
|
|
600
600
|
}
|
|
601
|
-
function
|
|
602
|
-
return o === "symbol" ? !0 :
|
|
601
|
+
function g(o, p) {
|
|
602
|
+
return o === "symbol" ? !0 : p ? p["@@toStringTag"] === "Symbol" || typeof Symbol == "function" && p instanceof Symbol : !1;
|
|
603
603
|
}
|
|
604
|
-
function
|
|
605
|
-
var
|
|
606
|
-
return Array.isArray(o) ? "array" : o instanceof RegExp ? "object" :
|
|
604
|
+
function w(o) {
|
|
605
|
+
var p = typeof o;
|
|
606
|
+
return Array.isArray(o) ? "array" : o instanceof RegExp ? "object" : g(p, o) ? "symbol" : p;
|
|
607
607
|
}
|
|
608
608
|
function j(o) {
|
|
609
609
|
if (typeof o > "u" || o === null)
|
|
610
610
|
return "" + o;
|
|
611
|
-
var
|
|
612
|
-
if (
|
|
611
|
+
var p = w(o);
|
|
612
|
+
if (p === "object") {
|
|
613
613
|
if (o instanceof Date)
|
|
614
614
|
return "date";
|
|
615
615
|
if (o instanceof RegExp)
|
|
616
616
|
return "regexp";
|
|
617
617
|
}
|
|
618
|
-
return
|
|
618
|
+
return p;
|
|
619
619
|
}
|
|
620
620
|
function V(o) {
|
|
621
|
-
var
|
|
622
|
-
switch (
|
|
621
|
+
var p = j(o);
|
|
622
|
+
switch (p) {
|
|
623
623
|
case "array":
|
|
624
624
|
case "object":
|
|
625
|
-
return "an " +
|
|
625
|
+
return "an " + p;
|
|
626
626
|
case "boolean":
|
|
627
627
|
case "date":
|
|
628
628
|
case "regexp":
|
|
629
|
-
return "a " +
|
|
629
|
+
return "a " + p;
|
|
630
630
|
default:
|
|
631
|
-
return
|
|
631
|
+
return p;
|
|
632
632
|
}
|
|
633
633
|
}
|
|
634
634
|
function G(o) {
|
|
635
635
|
return !o.constructor || !o.constructor.name ? k : o.constructor.name;
|
|
636
636
|
}
|
|
637
|
-
return
|
|
638
|
-
},
|
|
637
|
+
return P.checkPropTypes = l, P.resetWarningCache = l.resetWarningCache, P.PropTypes = P, P;
|
|
638
|
+
}, Le;
|
|
639
639
|
}
|
|
640
|
-
var
|
|
640
|
+
var ke, ut;
|
|
641
641
|
function Bn() {
|
|
642
|
-
if (ut) return
|
|
642
|
+
if (ut) return ke;
|
|
643
643
|
ut = 1;
|
|
644
644
|
var e = Ve();
|
|
645
645
|
function n() {
|
|
646
646
|
}
|
|
647
647
|
function t() {
|
|
648
648
|
}
|
|
649
|
-
return t.resetWarningCache = n,
|
|
650
|
-
function r(h, i,
|
|
651
|
-
if (
|
|
649
|
+
return t.resetWarningCache = n, ke = function() {
|
|
650
|
+
function r(h, i, y, v, d, C) {
|
|
651
|
+
if (C !== e) {
|
|
652
652
|
var k = new Error(
|
|
653
653
|
"Calling PropTypes validators directly is not supported by the `prop-types` package. Use PropTypes.checkPropTypes() to call them. Read more at http://fb.me/use-check-prop-types"
|
|
654
654
|
);
|
|
@@ -656,7 +656,7 @@ function Bn() {
|
|
|
656
656
|
}
|
|
657
657
|
}
|
|
658
658
|
r.isRequired = r;
|
|
659
|
-
function
|
|
659
|
+
function l() {
|
|
660
660
|
return r;
|
|
661
661
|
}
|
|
662
662
|
var a = {
|
|
@@ -669,60 +669,60 @@ function Bn() {
|
|
|
669
669
|
string: r,
|
|
670
670
|
symbol: r,
|
|
671
671
|
any: r,
|
|
672
|
-
arrayOf:
|
|
672
|
+
arrayOf: l,
|
|
673
673
|
element: r,
|
|
674
674
|
elementType: r,
|
|
675
|
-
instanceOf:
|
|
675
|
+
instanceOf: l,
|
|
676
676
|
node: r,
|
|
677
|
-
objectOf:
|
|
678
|
-
oneOf:
|
|
679
|
-
oneOfType:
|
|
680
|
-
shape:
|
|
681
|
-
exact:
|
|
677
|
+
objectOf: l,
|
|
678
|
+
oneOf: l,
|
|
679
|
+
oneOfType: l,
|
|
680
|
+
shape: l,
|
|
681
|
+
exact: l,
|
|
682
682
|
checkPropTypes: t,
|
|
683
683
|
resetWarningCache: n
|
|
684
684
|
};
|
|
685
685
|
return a.PropTypes = a, a;
|
|
686
|
-
},
|
|
686
|
+
}, ke;
|
|
687
687
|
}
|
|
688
688
|
if (process.env.NODE_ENV !== "production") {
|
|
689
689
|
var Ln = _t(), kn = !0;
|
|
690
|
-
ze.exports =
|
|
690
|
+
ze.exports = jn()(Ln.isElement, kn);
|
|
691
691
|
} else
|
|
692
692
|
ze.exports = Bn()();
|
|
693
693
|
var Dn = ze.exports;
|
|
694
|
-
const b = /* @__PURE__ */
|
|
695
|
-
function
|
|
694
|
+
const b = /* @__PURE__ */ In(Dn);
|
|
695
|
+
function Ke(e) {
|
|
696
696
|
return (n) => !!n.type && n.type.tabsRole === e;
|
|
697
697
|
}
|
|
698
|
-
const he =
|
|
698
|
+
const he = Ke("Tab"), Ne = Ke("TabList"), Ie = Ke("TabPanel");
|
|
699
699
|
function Mn(e) {
|
|
700
700
|
return he(e) || Ne(e) || Ie(e);
|
|
701
701
|
}
|
|
702
702
|
function We(e, n) {
|
|
703
|
-
return
|
|
703
|
+
return gt.map(e, (t) => t === null ? null : Mn(t) ? n(t) : t.props && t.props.children && typeof t.props.children == "object" ? _e(t, { ...t.props, children: We(t.props.children, n) }) : t);
|
|
704
704
|
}
|
|
705
705
|
function Ce(e, n) {
|
|
706
|
-
return
|
|
706
|
+
return gt.forEach(e, (t) => {
|
|
707
707
|
t !== null && (he(t) || Ie(t) ? n(t) : t.props && t.props.children && typeof t.props.children == "object" && (Ne(t) && n(t), Ce(t.props.children, n)));
|
|
708
708
|
});
|
|
709
709
|
}
|
|
710
|
-
function
|
|
711
|
-
let r,
|
|
712
|
-
const i = [],
|
|
713
|
-
return Ce(
|
|
714
|
-
Ne(v) && (v.props && v.props.children && typeof v.props.children == "object" && Ce(v.props.children, (d) => i.push(d)), h && (r = new Error("Found multiple 'TabList' components inside 'Tabs'. Only one is allowed.")), h = !0), he(v) ? ((!h || i.indexOf(v) === -1) && (r = new Error("Found a 'Tab' component outside of the 'TabList' component. 'Tab' components have to be inside the 'TabList' component.")),
|
|
715
|
-
}), !r &&
|
|
710
|
+
function xt(e, n, t) {
|
|
711
|
+
let r, l = 0, a = 0, h = !1;
|
|
712
|
+
const i = [], y = e[n];
|
|
713
|
+
return Ce(y, (v) => {
|
|
714
|
+
Ne(v) && (v.props && v.props.children && typeof v.props.children == "object" && Ce(v.props.children, (d) => i.push(d)), h && (r = new Error("Found multiple 'TabList' components inside 'Tabs'. Only one is allowed.")), h = !0), he(v) ? ((!h || i.indexOf(v) === -1) && (r = new Error("Found a 'Tab' component outside of the 'TabList' component. 'Tab' components have to be inside the 'TabList' component.")), l++) : Ie(v) && a++;
|
|
715
|
+
}), !r && l !== a && (r = new Error(`There should be an equal number of 'Tab' and 'TabPanel' in \`${t}\`. Received ${l} 'Tab' and ${a} 'TabPanel'.`)), r;
|
|
716
716
|
}
|
|
717
|
-
function
|
|
718
|
-
const a = e[n], h =
|
|
717
|
+
function Fn(e, n, t, r, l) {
|
|
718
|
+
const a = e[n], h = l || n;
|
|
719
719
|
let i = null;
|
|
720
720
|
return a && typeof a != "function" ? i = new Error(`Invalid ${r} \`${h}\` of type \`${typeof a}\` supplied to \`${t}\`, expected \`function\`.`) : e.selectedIndex != null && a == null && (i = new Error(`The ${r} \`${h}\` is marked as required in \`${t}\`, but its value is \`undefined\` or \`null\`.
|
|
721
721
|
\`onSelect\` is required when \`selectedIndex\` is also set. Not doing so will make the tabs not do anything, as \`selectedIndex\` indicates that you want to handle the selected tab yourself.
|
|
722
722
|
If you only want to set the inital tab replace \`selectedIndex\` with \`defaultIndex\`.`)), i;
|
|
723
723
|
}
|
|
724
|
-
function
|
|
725
|
-
const a = e[n], h =
|
|
724
|
+
function Un(e, n, t, r, l) {
|
|
725
|
+
const a = e[n], h = l || n;
|
|
726
726
|
let i = null;
|
|
727
727
|
if (a != null && typeof a != "number")
|
|
728
728
|
i = new Error(`Invalid ${r} \`${h}\` of type \`${typeof a}\` supplied to \`${t}\`, expected \`number\`.`);
|
|
@@ -731,20 +731,20 @@ function Fn(e, n, t, r, c) {
|
|
|
731
731
|
Either remove \`${h}\` to let \`${t}\` handle the selected tab internally or remove \`defaultIndex\` to handle it yourself.`);
|
|
732
732
|
return i;
|
|
733
733
|
}
|
|
734
|
-
function
|
|
734
|
+
function Et(e) {
|
|
735
735
|
var n, t, r = "";
|
|
736
736
|
if (typeof e == "string" || typeof e == "number") r += e;
|
|
737
737
|
else if (typeof e == "object") if (Array.isArray(e)) {
|
|
738
|
-
var
|
|
739
|
-
for (n = 0; n <
|
|
738
|
+
var l = e.length;
|
|
739
|
+
for (n = 0; n < l; n++) e[n] && (t = Et(e[n])) && (r && (r += " "), r += t);
|
|
740
740
|
} else for (t in e) e[t] && (r && (r += " "), r += t);
|
|
741
741
|
return r;
|
|
742
742
|
}
|
|
743
743
|
function Oe() {
|
|
744
|
-
for (var e, n, t = 0, r = "",
|
|
744
|
+
for (var e, n, t = 0, r = "", l = arguments.length; t < l; t++) (e = arguments[t]) && (n = Et(e)) && (r && (r += " "), r += n);
|
|
745
745
|
return r;
|
|
746
746
|
}
|
|
747
|
-
function
|
|
747
|
+
function St(e) {
|
|
748
748
|
let n = 0;
|
|
749
749
|
return Ce(e, (t) => {
|
|
750
750
|
he(t) && n++;
|
|
@@ -756,11 +756,11 @@ function Ct(e) {
|
|
|
756
756
|
function dt(e) {
|
|
757
757
|
return Ct(e) && e.getAttribute("data-rttab");
|
|
758
758
|
}
|
|
759
|
-
function
|
|
759
|
+
function ie(e) {
|
|
760
760
|
return Ct(e) && e.getAttribute("aria-disabled") === "true";
|
|
761
761
|
}
|
|
762
762
|
let Pe;
|
|
763
|
-
function
|
|
763
|
+
function zn(e) {
|
|
764
764
|
const n = e || (typeof window < "u" ? window : void 0);
|
|
765
765
|
try {
|
|
766
766
|
Pe = !!(typeof n < "u" && n.document && n.document.activeElement);
|
|
@@ -768,74 +768,74 @@ function Un(e) {
|
|
|
768
768
|
Pe = !1;
|
|
769
769
|
}
|
|
770
770
|
}
|
|
771
|
-
const
|
|
771
|
+
const Wn = { className: "react-tabs", focus: !1 }, Yn = process.env.NODE_ENV !== "production" ? { children: xt, direction: b.oneOf(["rtl", "ltr"]), className: b.oneOfType([b.string, b.array, b.object]), disabledTabClassName: b.string, disableUpDownKeys: b.bool, disableLeftRightKeys: b.bool, domRef: b.func, focus: b.bool, forceRenderTabPanel: b.bool, onSelect: b.func.isRequired, selectedIndex: b.number.isRequired, selectedTabClassName: b.string, selectedTabPanelClassName: b.string, environment: b.object } : {}, Pt = (e) => {
|
|
772
772
|
let n = Te([]), t = Te([]);
|
|
773
773
|
const r = Te();
|
|
774
|
-
function
|
|
774
|
+
function l(m, f) {
|
|
775
775
|
if (m < 0 || m >= v()) return;
|
|
776
|
-
const { onSelect:
|
|
777
|
-
|
|
776
|
+
const { onSelect: g, selectedIndex: w } = e;
|
|
777
|
+
g(m, w, f);
|
|
778
778
|
}
|
|
779
779
|
function a(m) {
|
|
780
|
-
const
|
|
781
|
-
for (let
|
|
782
|
-
if (!
|
|
783
|
-
return
|
|
784
|
-
for (let
|
|
785
|
-
if (!
|
|
786
|
-
return
|
|
780
|
+
const f = v();
|
|
781
|
+
for (let g = m + 1; g < f; g++)
|
|
782
|
+
if (!ie(d(g)))
|
|
783
|
+
return g;
|
|
784
|
+
for (let g = 0; g < m; g++)
|
|
785
|
+
if (!ie(d(g)))
|
|
786
|
+
return g;
|
|
787
787
|
return m;
|
|
788
788
|
}
|
|
789
789
|
function h(m) {
|
|
790
|
-
let
|
|
791
|
-
for (;
|
|
792
|
-
if (!
|
|
793
|
-
return
|
|
794
|
-
for (
|
|
795
|
-
if (!
|
|
796
|
-
return
|
|
790
|
+
let f = m;
|
|
791
|
+
for (; f--; )
|
|
792
|
+
if (!ie(d(f)))
|
|
793
|
+
return f;
|
|
794
|
+
for (f = v(); f-- > m; )
|
|
795
|
+
if (!ie(d(f)))
|
|
796
|
+
return f;
|
|
797
797
|
return m;
|
|
798
798
|
}
|
|
799
799
|
function i() {
|
|
800
800
|
const m = v();
|
|
801
|
-
for (let
|
|
802
|
-
if (!
|
|
803
|
-
return
|
|
801
|
+
for (let f = 0; f < m; f++)
|
|
802
|
+
if (!ie(d(f)))
|
|
803
|
+
return f;
|
|
804
804
|
return null;
|
|
805
805
|
}
|
|
806
|
-
function
|
|
806
|
+
function y() {
|
|
807
807
|
let m = v();
|
|
808
808
|
for (; m--; )
|
|
809
|
-
if (!
|
|
809
|
+
if (!ie(d(m)))
|
|
810
810
|
return m;
|
|
811
811
|
return null;
|
|
812
812
|
}
|
|
813
813
|
function v() {
|
|
814
814
|
const { children: m } = e;
|
|
815
|
-
return
|
|
815
|
+
return St(m);
|
|
816
816
|
}
|
|
817
817
|
function d(m) {
|
|
818
818
|
return n.current[`tabs-${m}`];
|
|
819
819
|
}
|
|
820
|
-
function
|
|
820
|
+
function C() {
|
|
821
821
|
let m = 0;
|
|
822
|
-
const { children:
|
|
822
|
+
const { children: f, disabledTabClassName: g, focus: w, forceRenderTabPanel: j, selectedIndex: V, selectedTabClassName: G, selectedTabPanelClassName: o, environment: p } = e;
|
|
823
823
|
t.current = t.current || [];
|
|
824
824
|
let A = t.current.length - v();
|
|
825
|
-
const O =
|
|
825
|
+
const O = nn();
|
|
826
826
|
for (; A++ < 0; )
|
|
827
827
|
t.current.push(`${O}${t.current.length}`);
|
|
828
|
-
return We(
|
|
828
|
+
return We(f, (_) => {
|
|
829
829
|
let R = _;
|
|
830
830
|
if (Ne(_)) {
|
|
831
831
|
let T = 0, I = !1;
|
|
832
|
-
Pe == null &&
|
|
833
|
-
const B =
|
|
832
|
+
Pe == null && zn(p);
|
|
833
|
+
const B = p || (typeof window < "u" ? window : void 0);
|
|
834
834
|
Pe && B && (I = pe.Children.toArray(_.props.children).filter(he).some((L, $) => B.document.activeElement === d($))), R = _e(_, { children: We(_.props.children, (L) => {
|
|
835
|
-
const $ = `tabs-${T}`, Y = V === T,
|
|
835
|
+
const $ = `tabs-${T}`, Y = V === T, c = { tabRef: (Z) => {
|
|
836
836
|
n.current[$] = Z;
|
|
837
|
-
}, id: t.current[T], selected: Y, focus: Y && (
|
|
838
|
-
return G && (
|
|
837
|
+
}, id: t.current[T], selected: Y, focus: Y && (w || I) };
|
|
838
|
+
return G && (c.selectedClassName = G), g && (c.disabledClassName = g), T++, _e(L, c);
|
|
839
839
|
}) });
|
|
840
840
|
} else if (Ie(_)) {
|
|
841
841
|
const T = { id: t.current[m], selected: V === m };
|
|
@@ -845,117 +845,117 @@ const zn = { className: "react-tabs", focus: !1 }, Wn = process.env.NODE_ENV !==
|
|
|
845
845
|
});
|
|
846
846
|
}
|
|
847
847
|
function k(m) {
|
|
848
|
-
const { direction:
|
|
848
|
+
const { direction: f, disableUpDownKeys: g, disableLeftRightKeys: w } = e;
|
|
849
849
|
if (N(m.target)) {
|
|
850
850
|
let { selectedIndex: j } = e, V = !1, G = !1;
|
|
851
|
-
(m.code === "Space" || m.keyCode === 32 || m.code === "Enter" || m.keyCode === 13) && (V = !0, G = !1,
|
|
851
|
+
(m.code === "Space" || m.keyCode === 32 || m.code === "Enter" || m.keyCode === 13) && (V = !0, G = !1, P(m)), !w && (m.keyCode === 37 || m.code === "ArrowLeft") || !g && (m.keyCode === 38 || m.code === "ArrowUp") ? (f === "rtl" ? j = a(j) : j = h(j), V = !0, G = !0) : !w && (m.keyCode === 39 || m.code === "ArrowRight") || !g && (m.keyCode === 40 || m.code === "ArrowDown") ? (f === "rtl" ? j = h(j) : j = a(j), V = !0, G = !0) : m.keyCode === 35 || m.code === "End" ? (j = y(), V = !0, G = !0) : (m.keyCode === 36 || m.code === "Home") && (j = i(), V = !0, G = !0), V && m.preventDefault(), G && l(j, m);
|
|
852
852
|
}
|
|
853
853
|
}
|
|
854
|
-
function
|
|
855
|
-
let
|
|
854
|
+
function P(m) {
|
|
855
|
+
let f = m.target;
|
|
856
856
|
do
|
|
857
|
-
if (N(
|
|
858
|
-
if (
|
|
857
|
+
if (N(f)) {
|
|
858
|
+
if (ie(f))
|
|
859
859
|
return;
|
|
860
|
-
const
|
|
861
|
-
|
|
860
|
+
const g = [].slice.call(f.parentNode.children).filter(dt).indexOf(f);
|
|
861
|
+
l(g, m);
|
|
862
862
|
return;
|
|
863
863
|
}
|
|
864
|
-
while ((
|
|
864
|
+
while ((f = f.parentNode) != null);
|
|
865
865
|
}
|
|
866
866
|
function N(m) {
|
|
867
867
|
if (!dt(m))
|
|
868
868
|
return !1;
|
|
869
|
-
let
|
|
869
|
+
let f = m.parentElement;
|
|
870
870
|
do {
|
|
871
|
-
if (
|
|
872
|
-
if (
|
|
873
|
-
|
|
874
|
-
} while (
|
|
871
|
+
if (f === r.current) return !0;
|
|
872
|
+
if (f.getAttribute("data-rttabs")) break;
|
|
873
|
+
f = f.parentElement;
|
|
874
|
+
} while (f);
|
|
875
875
|
return !1;
|
|
876
876
|
}
|
|
877
|
-
const { children:
|
|
878
|
-
return pe.createElement("div", Object.assign({},
|
|
877
|
+
const { children: S, className: F, disabledTabClassName: q, domRef: Q, focus: z, forceRenderTabPanel: U, onSelect: u, selectedIndex: ee, selectedTabClassName: ne, selectedTabPanelClassName: le, environment: ce, disableUpDownKeys: J, disableLeftRightKeys: oe, ...ae } = { ...Wn, ...e };
|
|
878
|
+
return pe.createElement("div", Object.assign({}, ae, { className: Oe(F), onClick: P, onKeyDown: k, ref: (m) => {
|
|
879
879
|
r.current = m, Q && Q(m);
|
|
880
|
-
}, "data-rttabs": !0 }),
|
|
880
|
+
}, "data-rttabs": !0 }), C());
|
|
881
881
|
};
|
|
882
|
-
Pt.propTypes = process.env.NODE_ENV !== "production" ?
|
|
883
|
-
const
|
|
882
|
+
Pt.propTypes = process.env.NODE_ENV !== "production" ? Yn : {};
|
|
883
|
+
const qn = 0, xe = 1, Vn = process.env.NODE_ENV !== "production" ? { children: xt, className: b.oneOfType([b.string, b.array, b.object]), defaultFocus: b.bool, defaultIndex: b.number, direction: b.oneOf(["rtl", "ltr"]), disabledTabClassName: b.string, disableUpDownKeys: b.bool, disableLeftRightKeys: b.bool, domRef: b.func, environment: b.object, focusTabOnClick: b.bool, forceRenderTabPanel: b.bool, onSelect: Fn, selectedIndex: Un, selectedTabClassName: b.string, selectedTabPanelClassName: b.string } : {}, Kn = { defaultFocus: !1, focusTabOnClick: !0, forceRenderTabPanel: !1, selectedIndex: null, defaultIndex: null, environment: null, disableUpDownKeys: !1, disableLeftRightKeys: !1 }, wt = (e) => e.selectedIndex === null ? xe : qn, Hn = (e, n) => {
|
|
884
884
|
if (process.env.NODE_ENV !== "production" && n != null && n !== wt(e))
|
|
885
885
|
throw new Error("Switching between controlled mode (by using `selectedIndex`) and uncontrolled mode is not supported in `Tabs`.\nFor more information about controlled and uncontrolled mode of react-tabs see https://github.com/reactjs/react-tabs#controlled-vs-uncontrolled-mode.");
|
|
886
|
-
},
|
|
887
|
-
const { children: n, defaultFocus: t, defaultIndex: r, focusTabOnClick:
|
|
886
|
+
}, He = (e) => {
|
|
887
|
+
const { children: n, defaultFocus: t, defaultIndex: r, focusTabOnClick: l, onSelect: a, ...h } = { ...Kn, ...e }, [i, y] = te(t), [v] = te(wt(h)), [d, C] = te(v === xe ? r || 0 : null);
|
|
888
888
|
if (se(() => {
|
|
889
|
-
|
|
890
|
-
}, []), v ===
|
|
891
|
-
const N =
|
|
889
|
+
y(!1);
|
|
890
|
+
}, []), v === xe) {
|
|
891
|
+
const N = St(n);
|
|
892
892
|
se(() => {
|
|
893
893
|
if (d != null) {
|
|
894
|
-
const
|
|
895
|
-
|
|
894
|
+
const S = Math.max(0, N - 1);
|
|
895
|
+
C(Math.min(d, S));
|
|
896
896
|
}
|
|
897
897
|
}, [N]);
|
|
898
898
|
}
|
|
899
899
|
Hn(h, v);
|
|
900
|
-
const k = (N,
|
|
901
|
-
typeof a == "function" && a(N,
|
|
900
|
+
const k = (N, S, F) => {
|
|
901
|
+
typeof a == "function" && a(N, S, F) === !1 || (l && y(!0), v === xe && C(N));
|
|
902
902
|
};
|
|
903
|
-
let
|
|
904
|
-
return
|
|
903
|
+
let P = { ...e, ...h };
|
|
904
|
+
return P.focus = i, P.onSelect = k, d != null && (P.selectedIndex = d), delete P.defaultFocus, delete P.defaultIndex, delete P.focusTabOnClick, pe.createElement(Pt, P, n);
|
|
905
905
|
};
|
|
906
|
-
|
|
907
|
-
|
|
908
|
-
const
|
|
909
|
-
const { children: n, className: t, ...r } = { ...
|
|
906
|
+
He.propTypes = process.env.NODE_ENV !== "production" ? Vn : {};
|
|
907
|
+
He.tabsRole = "Tabs";
|
|
908
|
+
const Gn = { className: "react-tabs__tab-list" }, Xn = process.env.NODE_ENV !== "production" ? { children: b.oneOfType([b.object, b.array]), className: b.oneOfType([b.string, b.array, b.object]) } : {}, Ge = (e) => {
|
|
909
|
+
const { children: n, className: t, ...r } = { ...Gn, ...e };
|
|
910
910
|
return pe.createElement("ul", Object.assign({}, r, { className: Oe(t), role: "tablist" }), n);
|
|
911
911
|
};
|
|
912
912
|
Ge.tabsRole = "TabList";
|
|
913
|
-
Ge.propTypes = process.env.NODE_ENV !== "production" ?
|
|
914
|
-
const
|
|
913
|
+
Ge.propTypes = process.env.NODE_ENV !== "production" ? Xn : {};
|
|
914
|
+
const De = "react-tabs__tab", Jn = { className: De, disabledClassName: `${De}--disabled`, focus: !1, id: null, selected: !1, selectedClassName: `${De}--selected` }, Zn = process.env.NODE_ENV !== "production" ? { children: b.oneOfType([b.array, b.object, b.string]), className: b.oneOfType([b.string, b.array, b.object]), disabled: b.bool, disabledClassName: b.string, focus: b.bool, id: b.string, selected: b.bool, selectedClassName: b.string, tabIndex: b.string, tabRef: b.func } : {}, de = (e) => {
|
|
915
915
|
let n = Te();
|
|
916
|
-
const { children: t, className: r, disabled:
|
|
916
|
+
const { children: t, className: r, disabled: l, disabledClassName: a, focus: h, id: i, selected: y, selectedClassName: v, tabIndex: d, tabRef: C, ...k } = { ...Jn, ...e };
|
|
917
917
|
return se(() => {
|
|
918
|
-
|
|
919
|
-
}, [
|
|
920
|
-
n.current =
|
|
921
|
-
}, role: "tab", id: `tab${i}`, "aria-selected":
|
|
918
|
+
y && h && n.current.focus();
|
|
919
|
+
}, [y, h]), pe.createElement("li", Object.assign({}, k, { className: Oe(r, { [v]: y, [a]: l }), ref: (P) => {
|
|
920
|
+
n.current = P, C && C(P);
|
|
921
|
+
}, role: "tab", id: `tab${i}`, "aria-selected": y ? "true" : "false", "aria-disabled": l ? "true" : "false", "aria-controls": `panel${i}`, tabIndex: d || (y ? "0" : null), "data-rttab": !0 }), t);
|
|
922
922
|
};
|
|
923
|
-
de.propTypes = process.env.NODE_ENV !== "production" ?
|
|
923
|
+
de.propTypes = process.env.NODE_ENV !== "production" ? Zn : {};
|
|
924
924
|
de.tabsRole = "Tab";
|
|
925
|
-
const ft = "react-tabs__tab-panel",
|
|
926
|
-
const { children: n, className: t, forceRender: r, id:
|
|
927
|
-
return pe.createElement("div", Object.assign({}, i, { className: Oe(t, { [h]: a }), role: "tabpanel", id: `panel${
|
|
925
|
+
const ft = "react-tabs__tab-panel", Qn = { className: ft, forceRender: !1, selectedClassName: `${ft}--selected` }, er = process.env.NODE_ENV !== "production" ? { children: b.node, className: b.oneOfType([b.string, b.array, b.object]), forceRender: b.bool, id: b.string, selected: b.bool, selectedClassName: b.string } : {}, fe = (e) => {
|
|
926
|
+
const { children: n, className: t, forceRender: r, id: l, selected: a, selectedClassName: h, ...i } = { ...Qn, ...e };
|
|
927
|
+
return pe.createElement("div", Object.assign({}, i, { className: Oe(t, { [h]: a }), role: "tabpanel", id: `panel${l}`, "aria-labelledby": `tab${l}` }), r || a ? n : null);
|
|
928
928
|
};
|
|
929
929
|
fe.tabsRole = "TabPanel";
|
|
930
|
-
fe.propTypes = process.env.NODE_ENV !== "production" ?
|
|
930
|
+
fe.propTypes = process.env.NODE_ENV !== "production" ? er : {};
|
|
931
931
|
(function() {
|
|
932
932
|
try {
|
|
933
933
|
if (typeof document < "u") {
|
|
934
934
|
var e = document.createElement("style");
|
|
935
|
-
e.appendChild(document.createTextNode('.
|
|
935
|
+
e.appendChild(document.createTextNode('._FileExplorer_lr5mr_1{--header-height: 3.5rem;--sidebar-width: 10rem;--footer-height: 1.75rem;--scale: 1.15rem;display:flex;flex-direction:column;width:100%;height:100%}._Header_lr5mr_13{display:flex;gap:1rem;align-items:center;width:100%;height:var(--header-height);padding:1rem;background-color:var(--background-color-0)}._IconButton_lr5mr_23{--color: var(--foreground-color-0);position:relative;height:1.25rem;width:auto;padding:0;background:none;border:none;outline:none;aspect-ratio:1;cursor:pointer}._IconButton_lr5mr_23:after{content:"";position:absolute;top:0;left:0;width:100%;height:100%;background-color:#fff0;border-radius:var(--border-radius-99);transform:scale(1);transform-origin:center;transition:all var(--transition-duration-1) var(--ease-in-out-default)}._IconButton_lr5mr_23:hover:after,._IconButton_lr5mr_23:focus-visible:after{background-color:#ffffff1a;transform:scale(1.5)}._IconButton_lr5mr_23:disabled{--color: var(--background-color-1)}._IconButton_lr5mr_23 svg{height:100%}._IconButton_lr5mr_23 svg path{fill:var(--color);transition:fill var(--transition-duration-0) var(--ease-in-out-default)}._PathInput_lr5mr_69{flex:1;padding:.25rem .5rem;background-color:var(--background-color-2);border:none;border-radius:var(--border-radius-1);outline:none;font-family:inherit;font-size:inherit}._Body_lr5mr_80{flex:1;display:flex;width:100%;height:calc(100% - var(--header-height));background-color:var(--background-color-2)}._Sidebar_lr5mr_88{display:flex;gap:.25rem;flex-direction:column;min-width:calc(var(--sidebar-width) / 2);width:var(--sidebar-width);height:100%;max-width:50%;padding:.5rem;background-color:var(--background-color-1);resize:horizontal;overflow:hidden}._NavButton_lr5mr_102{display:flex;gap:.5rem;align-items:center;width:100%;padding:.5rem;background:none;border:none;border-radius:var(--border-radius-1);outline:none;cursor:pointer;transition:background-color var(--transition-duration-0) var(--ease-in-out-default)}._NavButton_lr5mr_102:hover,._NavButton_lr5mr_102:focus-visible{background-color:color-mix(in srgb,var(--background-color-0) 75%,transparent)}._NavButton_lr5mr_102 svg{height:1.35rem;aspect-ratio:1}._Main_lr5mr_125{--scale: inherit !important;position:relative;flex:1;display:flex;flex-wrap:wrap;align-content:flex-start;height:100%;padding:.5rem;padding-bottom:calc(.5rem + var(--footer-height));overflow:auto}._Footer_lr5mr_139{position:absolute;display:flex;justify-content:flex-start;align-items:center;bottom:0;left:0;width:100%;height:var(--footer-height);padding:0 .75rem;border-top:.25rem solid var(--background-color-0);background-color:var(--background-color-2)}._Footer_lr5mr_139 p{margin:0;font-size:.875em}._Selector_lr5mr_158{--footer-height: 4rem}._FileProperties_xi8b6_1{display:flex;flex-direction:column;justify-content:flex-start;align-items:flex-start;padding:1rem}._Icon_xi8b6_9{width:3rem;height:3rem}._Icon_xi8b6_9 div{width:inherit;height:inherit;object-fit:contain}._Icon_xi8b6_9 svg{max-width:100%;max-height:100%}._Section_xi8b6_25{--divider-width: .25rem;position:relative;display:flex;gap:.25rem;justify-content:flex-start;align-items:flex-start;flex-direction:column;width:100%;padding:1rem 0;padding-bottom:calc(1rem + var(--divider-width))}._Section_xi8b6_25:first-child{gap:.5rem;align-items:center;flex-direction:row;padding-top:0}._Section_xi8b6_25:first-child ._Line_xi8b6_46{font-size:1.25rem}._Section_xi8b6_25:not(:last-child):after{content:"";position:absolute;bottom:0;left:0;width:100%;height:var(--divider-width);border-radius:var(--border-radius-0);background-color:var(--background-color-0)}._Line_xi8b6_46{margin:0;text-align:left;padding-left:2rem;text-indent:-2rem}._AppIcon_xi8b6_68{display:inline-block;width:2rem;height:2rem;vertical-align:middle;margin-left:.5rem;margin-right:.25rem}._AppIcon_xi8b6_68 div{position:relative;width:inherit;height:inherit;object-fit:contain}._AppIcon_xi8b6_68 svg{position:absolute;top:0;left:0;max-width:100%;max-height:100%}')), document.head.appendChild(e);
|
|
936
936
|
}
|
|
937
937
|
} catch (n) {
|
|
938
938
|
console.error("vite-plugin-css-injected-by-js", n);
|
|
939
939
|
}
|
|
940
940
|
})();
|
|
941
|
-
const
|
|
942
|
-
FileExplorer:
|
|
943
|
-
Header:
|
|
944
|
-
IconButton:
|
|
945
|
-
PathInput:
|
|
946
|
-
Body:
|
|
947
|
-
Sidebar:
|
|
948
|
-
NavButton:
|
|
949
|
-
Main:
|
|
941
|
+
const tr = "_FileExplorer_lr5mr_1", nr = "_Header_lr5mr_13", rr = "_IconButton_lr5mr_23", or = "_PathInput_lr5mr_69", ar = "_Body_lr5mr_80", ir = "_Sidebar_lr5mr_88", sr = "_NavButton_lr5mr_102", lr = "_Main_lr5mr_125", cr = "_Footer_lr5mr_139", ur = "_Selector_lr5mr_158", W = {
|
|
942
|
+
FileExplorer: tr,
|
|
943
|
+
Header: nr,
|
|
944
|
+
IconButton: rr,
|
|
945
|
+
PathInput: or,
|
|
946
|
+
Body: ar,
|
|
947
|
+
Sidebar: ir,
|
|
948
|
+
NavButton: sr,
|
|
949
|
+
Main: lr,
|
|
950
950
|
Footer: cr,
|
|
951
|
-
Selector:
|
|
951
|
+
Selector: ur
|
|
952
952
|
};
|
|
953
|
-
function
|
|
954
|
-
return /* @__PURE__ */
|
|
953
|
+
function ge({ onClick: e, icon: n, name: t }) {
|
|
954
|
+
return /* @__PURE__ */ x(
|
|
955
955
|
"button",
|
|
956
956
|
{
|
|
957
957
|
tabIndex: 0,
|
|
958
|
-
className: `${W.NavButton} ${
|
|
958
|
+
className: `${W.NavButton} ${H.TextSemibold}`,
|
|
959
959
|
onClick: e,
|
|
960
960
|
children: [
|
|
961
961
|
/* @__PURE__ */ s(X, { icon: n }),
|
|
@@ -964,20 +964,20 @@ function ye({ onClick: e, icon: n, name: t }) {
|
|
|
964
964
|
}
|
|
965
965
|
);
|
|
966
966
|
}
|
|
967
|
-
function
|
|
967
|
+
function dr({ directory: e }) {
|
|
968
968
|
const n = (t) => {
|
|
969
969
|
const r = t.target.files;
|
|
970
|
-
r != null && Array.from(r).forEach((
|
|
971
|
-
const { name: a, extension: h } =
|
|
972
|
-
i.onload = (
|
|
973
|
-
const { result: v } =
|
|
970
|
+
r != null && Array.from(r).forEach((l) => {
|
|
971
|
+
const { name: a, extension: h } = Lt.splitId(l.name), i = new FileReader();
|
|
972
|
+
i.onload = (y) => {
|
|
973
|
+
const { result: v } = y.target;
|
|
974
974
|
e.createFile(a, h, (d) => {
|
|
975
975
|
d.setSource(v);
|
|
976
976
|
});
|
|
977
|
-
}, i.readAsDataURL(
|
|
977
|
+
}, i.readAsDataURL(l);
|
|
978
978
|
});
|
|
979
979
|
};
|
|
980
|
-
return /* @__PURE__ */
|
|
980
|
+
return /* @__PURE__ */ x("label", { title: "Import", tabIndex: 0, className: W.IconButton, children: [
|
|
981
981
|
/* @__PURE__ */ s(
|
|
982
982
|
"input",
|
|
983
983
|
{
|
|
@@ -988,134 +988,140 @@ function ur({ directory: e }) {
|
|
|
988
988
|
onChange: n
|
|
989
989
|
}
|
|
990
990
|
),
|
|
991
|
-
/* @__PURE__ */ s(X, { icon:
|
|
991
|
+
/* @__PURE__ */ s(X, { icon: Xt })
|
|
992
992
|
] });
|
|
993
993
|
}
|
|
994
994
|
const pt = {
|
|
995
995
|
NONE: 0,
|
|
996
996
|
SINGLE: 1,
|
|
997
997
|
MULTIPLE: 2
|
|
998
|
-
},
|
|
999
|
-
FileProperties:
|
|
1000
|
-
Icon:
|
|
1001
|
-
Section:
|
|
1002
|
-
Line:
|
|
1003
|
-
AppIcon:
|
|
998
|
+
}, fr = "_FileProperties_xi8b6_1", pr = "_Icon_xi8b6_9", br = "_Section_xi8b6_25", mr = "_Line_xi8b6_46", hr = "_AppIcon_xi8b6_68", K = {
|
|
999
|
+
FileProperties: fr,
|
|
1000
|
+
Icon: pr,
|
|
1001
|
+
Section: br,
|
|
1002
|
+
Line: mr,
|
|
1003
|
+
AppIcon: hr
|
|
1004
1004
|
};
|
|
1005
|
-
function
|
|
1006
|
-
const { appsConfig:
|
|
1007
|
-
return /* @__PURE__ */
|
|
1008
|
-
/* @__PURE__ */
|
|
1009
|
-
/* @__PURE__ */ s(Ue, { className:
|
|
1010
|
-
/* @__PURE__ */ s("p", { className: `${
|
|
1005
|
+
function vr({ modal: e, params: n, file: t, ...r }) {
|
|
1006
|
+
const { appsConfig: l } = me(), a = t.extension != null ? l.getAppByFileExtension(t.extension) : null;
|
|
1007
|
+
return /* @__PURE__ */ x(Bt, { className: K.FileProperties, modal: e, params: n, ...r, children: [
|
|
1008
|
+
/* @__PURE__ */ x("span", { className: K.Section, children: [
|
|
1009
|
+
/* @__PURE__ */ s(Ue, { className: K.Icon, source: t.getIconUrl() }),
|
|
1010
|
+
/* @__PURE__ */ s("p", { className: `${K.Line} ${H.TextBold}`, children: t.id })
|
|
1011
1011
|
] }),
|
|
1012
|
-
/* @__PURE__ */
|
|
1013
|
-
/* @__PURE__ */
|
|
1012
|
+
/* @__PURE__ */ x("span", { className: K.Section, children: [
|
|
1013
|
+
/* @__PURE__ */ x("p", { className: K.Line, children: [
|
|
1014
1014
|
"Type: ",
|
|
1015
1015
|
t.getType()
|
|
1016
1016
|
] }),
|
|
1017
|
-
a != null && /* @__PURE__ */
|
|
1017
|
+
a != null && /* @__PURE__ */ x("span", { className: K.Line, children: [
|
|
1018
1018
|
"Opens with:",
|
|
1019
|
-
/* @__PURE__ */ s(Ue, { className:
|
|
1019
|
+
/* @__PURE__ */ s(Ue, { className: K.AppIcon, source: a.iconUrl ?? "" }),
|
|
1020
1020
|
a.name
|
|
1021
1021
|
] })
|
|
1022
1022
|
] }),
|
|
1023
|
-
/* @__PURE__ */
|
|
1024
|
-
/* @__PURE__ */
|
|
1023
|
+
/* @__PURE__ */ x("span", { className: K.Section, children: [
|
|
1024
|
+
/* @__PURE__ */ x("p", { className: K.Line, children: [
|
|
1025
1025
|
"Location: ",
|
|
1026
1026
|
t.path
|
|
1027
1027
|
] }),
|
|
1028
|
-
/* @__PURE__ */
|
|
1028
|
+
/* @__PURE__ */ x("p", { className: K.Line, children: [
|
|
1029
1029
|
"Size: ",
|
|
1030
1030
|
ue.getByteSize(t.source ?? t.content),
|
|
1031
1031
|
" bytes"
|
|
1032
1032
|
] }),
|
|
1033
|
-
/* @__PURE__ */
|
|
1033
|
+
/* @__PURE__ */ x("p", { className: K.Line, children: [
|
|
1034
1034
|
"Size on drive: ",
|
|
1035
1035
|
ue.getByteSize(t.toString()),
|
|
1036
1036
|
" bytes"
|
|
1037
1037
|
] })
|
|
1038
1038
|
] }),
|
|
1039
|
-
/* @__PURE__ */ s("span", { className:
|
|
1039
|
+
/* @__PURE__ */ s("span", { className: K.Section, children: /* @__PURE__ */ x("p", { className: K.Line, children: [
|
|
1040
1040
|
"Attributes: ",
|
|
1041
1041
|
t.isProtected ? "Protected" : "N/A"
|
|
1042
1042
|
] }) })
|
|
1043
1043
|
] });
|
|
1044
1044
|
}
|
|
1045
|
-
function
|
|
1046
|
-
const h = r != null && t != null && t !== pt.NONE, i = we(),
|
|
1047
|
-
Actions: (
|
|
1048
|
-
|
|
1049
|
-
|
|
1050
|
-
|
|
1051
|
-
|
|
1052
|
-
|
|
1053
|
-
|
|
1054
|
-
|
|
1055
|
-
|
|
1056
|
-
|
|
1057
|
-
|
|
1058
|
-
|
|
1059
|
-
|
|
1060
|
-
|
|
1061
|
-
|
|
1062
|
-
|
|
1063
|
-
|
|
1064
|
-
|
|
1065
|
-
|
|
1066
|
-
|
|
1067
|
-
|
|
1068
|
-
|
|
1069
|
-
|
|
1070
|
-
|
|
1045
|
+
function yr({ app: e, path: n, selectorMode: t, Footer: r, onSelectionChange: l, onSelectionFinish: a }) {
|
|
1046
|
+
const h = r != null && t != null && t !== pt.NONE, i = we(), y = Ye(), { windowsConfig: v } = me(), [d, C] = te(i == null ? void 0 : i.navigate(n ?? "~")), [k, P] = te((d == null ? void 0 : d.path) ?? ""), [N] = te(!0), { history: S, stateIndex: F, pushState: q, undo: Q, redo: z, undoAvailable: U, redoAvailable: u } = Ot(d.path), { alert: ee } = At(), { openWindowedModal: ne } = ht(), { onContextMenu: le } = Me({
|
|
1047
|
+
Actions: (f) => {
|
|
1048
|
+
var g;
|
|
1049
|
+
return /* @__PURE__ */ x(Fe, { ...f, children: [
|
|
1050
|
+
/* @__PURE__ */ s(re, { label: h ? "Select" : "Open", onTrigger: (w, j) => {
|
|
1051
|
+
if (h) {
|
|
1052
|
+
l == null || l({ files: [j.id], directory: d }), a == null || a();
|
|
1053
|
+
return;
|
|
1054
|
+
}
|
|
1055
|
+
y != null && j.open(y);
|
|
1056
|
+
} }),
|
|
1057
|
+
((g = f.triggerParams) == null ? void 0 : g.isDownloadable()) && /* @__PURE__ */ s(re, { label: "Export", icon: Mt, onTrigger: (w, j) => {
|
|
1058
|
+
j.download();
|
|
1059
|
+
} }),
|
|
1060
|
+
/* @__PURE__ */ s(re, { label: "Delete", icon: et, onTrigger: (w, j) => {
|
|
1061
|
+
j.delete();
|
|
1062
|
+
} }),
|
|
1063
|
+
/* @__PURE__ */ s(re, { label: "Properties", icon: yt, onTrigger: (w, j) => {
|
|
1064
|
+
ne({
|
|
1065
|
+
title: `${j.id} ${v.titleSeparator} Properties`,
|
|
1066
|
+
iconUrl: j.getIconUrl(),
|
|
1067
|
+
size: new be(400, 500),
|
|
1068
|
+
Modal: (V) => /* @__PURE__ */ s(vr, { file: j, ...V })
|
|
1069
|
+
});
|
|
1070
|
+
} })
|
|
1071
|
+
] });
|
|
1072
|
+
}
|
|
1073
|
+
}), { onContextMenu: ce } = Me({
|
|
1074
|
+
Actions: (f) => /* @__PURE__ */ x(Fe, { ...f, children: [
|
|
1075
|
+
/* @__PURE__ */ s(re, { label: "Open", onTrigger: (g, w) => {
|
|
1076
|
+
J(w.linkedPath ?? w.name);
|
|
1071
1077
|
} }),
|
|
1072
1078
|
/* @__PURE__ */ s(Rt, {}),
|
|
1073
|
-
/* @__PURE__ */ s(
|
|
1074
|
-
|
|
1079
|
+
/* @__PURE__ */ s(re, { label: "Delete", icon: et, onTrigger: (g, w) => {
|
|
1080
|
+
w.delete();
|
|
1075
1081
|
} })
|
|
1076
1082
|
] })
|
|
1077
|
-
}), J =
|
|
1078
|
-
if (
|
|
1083
|
+
}), J = rn((f, g = !1) => {
|
|
1084
|
+
if (f == null)
|
|
1079
1085
|
return;
|
|
1080
|
-
d == null && (
|
|
1081
|
-
const
|
|
1082
|
-
|
|
1086
|
+
d == null && (g = !0);
|
|
1087
|
+
const w = g ? i == null ? void 0 : i.navigate(f) : d.navigate(f);
|
|
1088
|
+
w != null && (C(w), P(w.root ? "/" : w.path), q(w.path));
|
|
1083
1089
|
}, [d, q, i]);
|
|
1084
1090
|
se(() => {
|
|
1085
|
-
if (
|
|
1091
|
+
if (S.length === 0)
|
|
1086
1092
|
return;
|
|
1087
|
-
const
|
|
1088
|
-
|
|
1089
|
-
}, [
|
|
1090
|
-
const
|
|
1093
|
+
const f = S[F], g = i == null ? void 0 : i.navigate(f);
|
|
1094
|
+
g != null && (C(g), P(g.root ? "/" : g.path));
|
|
1095
|
+
}, [S, F, i]), se(() => {
|
|
1096
|
+
const f = (g) => {
|
|
1091
1097
|
ee({
|
|
1092
|
-
title:
|
|
1098
|
+
title: g.message,
|
|
1093
1099
|
text: "You have exceeded the virtual drive capacity. Files and folders will not be saved until more storage is freed.",
|
|
1094
1100
|
iconUrl: e == null ? void 0 : e.iconUrl,
|
|
1095
1101
|
size: new be(300, 200),
|
|
1096
1102
|
single: !0
|
|
1097
1103
|
});
|
|
1098
1104
|
};
|
|
1099
|
-
return i == null || i.on(Je.EVENT_NAMES.error,
|
|
1100
|
-
i == null || i.off(Je.EVENT_NAMES.error,
|
|
1105
|
+
return i == null || i.on(Je.EVENT_NAMES.error, f), () => {
|
|
1106
|
+
i == null || i.off(Je.EVENT_NAMES.error, f);
|
|
1101
1107
|
};
|
|
1102
1108
|
}, []);
|
|
1103
|
-
const
|
|
1104
|
-
|
|
1105
|
-
},
|
|
1106
|
-
let
|
|
1107
|
-
if (
|
|
1108
|
-
|
|
1109
|
-
const
|
|
1110
|
-
if (
|
|
1109
|
+
const oe = (f) => {
|
|
1110
|
+
P(f.target.value);
|
|
1111
|
+
}, ae = (f) => {
|
|
1112
|
+
let g = f.target.value;
|
|
1113
|
+
if (f.key === "Enter") {
|
|
1114
|
+
g === "" && (g = "~");
|
|
1115
|
+
const w = i == null ? void 0 : i.navigate(g);
|
|
1116
|
+
if (w == null) {
|
|
1111
1117
|
ne({
|
|
1112
1118
|
title: "Error",
|
|
1113
1119
|
iconUrl: e == null ? void 0 : e.iconUrl,
|
|
1114
1120
|
size: new be(300, 150),
|
|
1115
|
-
Modal: (j) => /* @__PURE__ */
|
|
1116
|
-
/* @__PURE__ */
|
|
1121
|
+
Modal: (j) => /* @__PURE__ */ x(Ze, { ...j, children: [
|
|
1122
|
+
/* @__PURE__ */ x("p", { children: [
|
|
1117
1123
|
'Invalid path: "',
|
|
1118
|
-
|
|
1124
|
+
g,
|
|
1119
1125
|
'"'
|
|
1120
1126
|
] }),
|
|
1121
1127
|
/* @__PURE__ */ s("button", { "data-type": Qe.DIALOG_CONTENT_TYPES.closeButton, children: "Ok" })
|
|
@@ -1123,11 +1129,11 @@ function vr({ app: e, path: n, selectorMode: t, Footer: r, onSelectionChange: c,
|
|
|
1123
1129
|
});
|
|
1124
1130
|
return;
|
|
1125
1131
|
}
|
|
1126
|
-
|
|
1132
|
+
C(w), P(w.root ? "/" : w.path);
|
|
1127
1133
|
}
|
|
1128
1134
|
}, m = d.getItemCount(N);
|
|
1129
|
-
return /* @__PURE__ */
|
|
1130
|
-
/* @__PURE__ */
|
|
1135
|
+
return /* @__PURE__ */ x("div", { className: h ? `${W.FileExplorer} ${W.Selector}` : W.FileExplorer, children: [
|
|
1136
|
+
/* @__PURE__ */ x("div", { className: W.Header, children: [
|
|
1131
1137
|
/* @__PURE__ */ s(
|
|
1132
1138
|
"button",
|
|
1133
1139
|
{
|
|
@@ -1138,7 +1144,7 @@ function vr({ app: e, path: n, selectorMode: t, Footer: r, onSelectionChange: c,
|
|
|
1138
1144
|
Q();
|
|
1139
1145
|
},
|
|
1140
1146
|
disabled: !U,
|
|
1141
|
-
children: /* @__PURE__ */ s(X, { icon:
|
|
1147
|
+
children: /* @__PURE__ */ s(X, { icon: Ft })
|
|
1142
1148
|
}
|
|
1143
1149
|
),
|
|
1144
1150
|
/* @__PURE__ */ s(
|
|
@@ -1151,7 +1157,7 @@ function vr({ app: e, path: n, selectorMode: t, Footer: r, onSelectionChange: c,
|
|
|
1151
1157
|
z();
|
|
1152
1158
|
},
|
|
1153
1159
|
disabled: !u,
|
|
1154
|
-
children: /* @__PURE__ */ s(X, { icon:
|
|
1160
|
+
children: /* @__PURE__ */ s(X, { icon: Ut })
|
|
1155
1161
|
}
|
|
1156
1162
|
),
|
|
1157
1163
|
/* @__PURE__ */ s(
|
|
@@ -1164,7 +1170,7 @@ function vr({ app: e, path: n, selectorMode: t, Footer: r, onSelectionChange: c,
|
|
|
1164
1170
|
J("..");
|
|
1165
1171
|
},
|
|
1166
1172
|
disabled: d.isRoot != null && d.isRoot,
|
|
1167
|
-
children: /* @__PURE__ */ s(X, { icon:
|
|
1173
|
+
children: /* @__PURE__ */ s(X, { icon: zt })
|
|
1168
1174
|
}
|
|
1169
1175
|
),
|
|
1170
1176
|
/* @__PURE__ */ s(
|
|
@@ -1178,14 +1184,14 @@ function vr({ app: e, path: n, selectorMode: t, Footer: r, onSelectionChange: c,
|
|
|
1178
1184
|
title: "Error",
|
|
1179
1185
|
iconUrl: e == null ? void 0 : e.iconUrl,
|
|
1180
1186
|
size: new be(300, 150),
|
|
1181
|
-
Modal: (
|
|
1187
|
+
Modal: (f) => /* @__PURE__ */ x(Ze, { ...f, children: [
|
|
1182
1188
|
/* @__PURE__ */ s("p", { children: "This folder is protected." }),
|
|
1183
1189
|
/* @__PURE__ */ s("button", { "data-type": Qe.DIALOG_CONTENT_TYPES.closeButton, children: "Ok" })
|
|
1184
1190
|
] })
|
|
1185
1191
|
});
|
|
1186
1192
|
},
|
|
1187
1193
|
disabled: !d.canBeEdited,
|
|
1188
|
-
children: /* @__PURE__ */ s(X, { icon:
|
|
1194
|
+
children: /* @__PURE__ */ s(X, { icon: Wt })
|
|
1189
1195
|
}
|
|
1190
1196
|
),
|
|
1191
1197
|
/* @__PURE__ */ s(
|
|
@@ -1196,29 +1202,29 @@ function vr({ app: e, path: n, selectorMode: t, Footer: r, onSelectionChange: c,
|
|
|
1196
1202
|
"aria-label": "Path",
|
|
1197
1203
|
className: W.PathInput,
|
|
1198
1204
|
tabIndex: 0,
|
|
1199
|
-
onChange:
|
|
1200
|
-
onKeyDown:
|
|
1205
|
+
onChange: oe,
|
|
1206
|
+
onKeyDown: ae,
|
|
1201
1207
|
placeholder: "Enter a path..."
|
|
1202
1208
|
}
|
|
1203
1209
|
),
|
|
1204
|
-
/* @__PURE__ */ s(
|
|
1205
|
-
/* @__PURE__ */ s("button", { title: "Search", tabIndex: 0, className: W.IconButton, children: /* @__PURE__ */ s(X, { icon:
|
|
1206
|
-
/* @__PURE__ */ s("button", { title: "Settings", tabIndex: 0, className: W.IconButton, children: /* @__PURE__ */ s(X, { icon:
|
|
1210
|
+
/* @__PURE__ */ s(dr, { directory: d }),
|
|
1211
|
+
/* @__PURE__ */ s("button", { title: "Search", tabIndex: 0, className: W.IconButton, children: /* @__PURE__ */ s(X, { icon: Yt }) }),
|
|
1212
|
+
/* @__PURE__ */ s("button", { title: "Settings", tabIndex: 0, className: W.IconButton, children: /* @__PURE__ */ s(X, { icon: qt }) })
|
|
1207
1213
|
] }),
|
|
1208
|
-
/* @__PURE__ */
|
|
1209
|
-
/* @__PURE__ */
|
|
1210
|
-
/* @__PURE__ */ s(
|
|
1214
|
+
/* @__PURE__ */ x("div", { className: W.Body, children: [
|
|
1215
|
+
/* @__PURE__ */ x("div", { className: W.Sidebar, children: [
|
|
1216
|
+
/* @__PURE__ */ s(ge, { name: "Home", onClick: () => {
|
|
1211
1217
|
J("~");
|
|
1212
|
-
}, icon: qt }),
|
|
1213
|
-
/* @__PURE__ */ s(ye, { name: "Desktop", onClick: () => {
|
|
1214
|
-
J("~/Desktop");
|
|
1215
1218
|
}, icon: Vt }),
|
|
1216
|
-
/* @__PURE__ */ s(
|
|
1219
|
+
/* @__PURE__ */ s(ge, { name: "Desktop", onClick: () => {
|
|
1220
|
+
J("~/Desktop");
|
|
1221
|
+
}, icon: Kt }),
|
|
1222
|
+
/* @__PURE__ */ s(ge, { name: "Images", onClick: () => {
|
|
1217
1223
|
J("~/Pictures");
|
|
1218
1224
|
}, icon: Ht }),
|
|
1219
|
-
/* @__PURE__ */ s(
|
|
1225
|
+
/* @__PURE__ */ s(ge, { name: "Documents", onClick: () => {
|
|
1220
1226
|
J("~/Documents");
|
|
1221
|
-
}, icon:
|
|
1227
|
+
}, icon: Gt })
|
|
1222
1228
|
] }),
|
|
1223
1229
|
/* @__PURE__ */ s(
|
|
1224
1230
|
$t,
|
|
@@ -1227,57 +1233,57 @@ function vr({ app: e, path: n, selectorMode: t, Footer: r, onSelectionChange: c,
|
|
|
1227
1233
|
id: "main",
|
|
1228
1234
|
className: W.Main,
|
|
1229
1235
|
showHidden: N,
|
|
1230
|
-
onOpenFile: (
|
|
1231
|
-
if (
|
|
1236
|
+
onOpenFile: (f, g) => {
|
|
1237
|
+
if (f.preventDefault(), h)
|
|
1232
1238
|
return void (a == null ? void 0 : a());
|
|
1233
|
-
const
|
|
1234
|
-
(
|
|
1239
|
+
const w = {};
|
|
1240
|
+
(g.extension === "md" || g.extension != null && jt.includes(g.extension)) && (w.mode = "view"), y == null || y.openFile(g, w);
|
|
1235
1241
|
},
|
|
1236
|
-
onOpenFolder: (
|
|
1237
|
-
J(
|
|
1242
|
+
onOpenFolder: (f, g) => {
|
|
1243
|
+
J(g.linkedPath ?? g.name);
|
|
1238
1244
|
},
|
|
1239
|
-
onContextMenuFile:
|
|
1240
|
-
onContextMenuFolder:
|
|
1245
|
+
onContextMenuFile: le,
|
|
1246
|
+
onContextMenuFolder: ce,
|
|
1241
1247
|
allowMultiSelect: t !== pt.SINGLE,
|
|
1242
|
-
onSelectionChange:
|
|
1248
|
+
onSelectionChange: l
|
|
1243
1249
|
}
|
|
1244
1250
|
)
|
|
1245
1251
|
] }),
|
|
1246
|
-
h ? /* @__PURE__ */ s("div", { className: W.Footer, children: /* @__PURE__ */ s(r, {}) }) : /* @__PURE__ */ s("span", { className: W.Footer, children: /* @__PURE__ */ s("p", { className:
|
|
1252
|
+
h ? /* @__PURE__ */ s("div", { className: W.Footer, children: /* @__PURE__ */ s(r, {}) }) : /* @__PURE__ */ s("span", { className: W.Footer, children: /* @__PURE__ */ s("p", { className: H.TextLight, children: m === 1 ? m + " item" : m + " items" }) })
|
|
1247
1253
|
] });
|
|
1248
1254
|
}
|
|
1249
1255
|
var Nt = /* @__PURE__ */ ((e) => (e[e.None = 0] = "None", e[e.Single = 1] = "Single", e[e.Multi = 2] = "Multi", e))(Nt || {});
|
|
1250
|
-
const It = new bt("File Explorer", "file-explorer",
|
|
1251
|
-
It.setMetadata({ name: "@prozilla-os/file-explorer", version: "1.1.
|
|
1256
|
+
const It = new bt("File Explorer", "file-explorer", yr).setIconUrl("https://os.prozilla.dev/assets/apps/icons/file-explorer.svg").setRole(mt.APP_ROLES.fileExplorer).setCategory("Utilities & tools");
|
|
1257
|
+
It.setMetadata({ name: "@prozilla-os/file-explorer", version: "1.1.16", author: "Prozilla" });
|
|
1252
1258
|
const gr = "~/Pictures/Wallpapers";
|
|
1253
|
-
function
|
|
1254
|
-
var k,
|
|
1255
|
-
const { modalsConfig: e } = me(), n = we(), t = qe(), [r,
|
|
1259
|
+
function _r() {
|
|
1260
|
+
var k, P;
|
|
1261
|
+
const { modalsConfig: e } = me(), n = we(), t = qe(), [r, l] = te(tt.Dark), [a, h] = te(null), i = t == null ? void 0 : t.getSettings(Ee.VIRTUAL_PATHS.desktop), y = t == null ? void 0 : t.getSettings(Ee.VIRTUAL_PATHS.theme), { openWindowedModal: v } = ht();
|
|
1256
1262
|
se(() => {
|
|
1257
|
-
i == null || i.get("wallpaper", h),
|
|
1258
|
-
|
|
1263
|
+
i == null || i.get("wallpaper", h), y == null || y.get("theme", (N) => {
|
|
1264
|
+
l(parseInt(N));
|
|
1259
1265
|
});
|
|
1260
|
-
}, [i,
|
|
1266
|
+
}, [i, y]);
|
|
1261
1267
|
const d = (N) => {
|
|
1262
|
-
const
|
|
1263
|
-
i == null || i.set("wallpaper",
|
|
1264
|
-
},
|
|
1265
|
-
const
|
|
1266
|
-
|
|
1268
|
+
const S = N.target.value;
|
|
1269
|
+
i == null || i.set("wallpaper", S);
|
|
1270
|
+
}, C = (N) => {
|
|
1271
|
+
const S = N.target.value;
|
|
1272
|
+
y == null || y.set("theme", S);
|
|
1267
1273
|
};
|
|
1268
|
-
return /* @__PURE__ */
|
|
1269
|
-
/* @__PURE__ */
|
|
1270
|
-
/* @__PURE__ */ s("p", { className:
|
|
1271
|
-
/* @__PURE__ */ s("div", { className:
|
|
1272
|
-
([N,
|
|
1274
|
+
return /* @__PURE__ */ x(vt, { children: [
|
|
1275
|
+
/* @__PURE__ */ x("div", { className: E.Option, children: [
|
|
1276
|
+
/* @__PURE__ */ s("p", { className: E.Label, children: "Theme" }),
|
|
1277
|
+
/* @__PURE__ */ s("div", { className: E.Input, children: /* @__PURE__ */ s("select", { className: E.Dropdown, "aria-label": "theme", value: r, onChange: C, children: Object.entries(tt).map(
|
|
1278
|
+
([N, S]) => /* @__PURE__ */ s("option", { value: N, children: S }, N)
|
|
1273
1279
|
) }) })
|
|
1274
1280
|
] }),
|
|
1275
|
-
/* @__PURE__ */
|
|
1276
|
-
/* @__PURE__ */ s("p", { className:
|
|
1281
|
+
/* @__PURE__ */ x("div", { className: E.Option, children: [
|
|
1282
|
+
/* @__PURE__ */ s("p", { className: E.Label, children: "Wallpaper" }),
|
|
1277
1283
|
/* @__PURE__ */ s(
|
|
1278
|
-
|
|
1284
|
+
Se,
|
|
1279
1285
|
{
|
|
1280
|
-
className: `${
|
|
1286
|
+
className: `${E.Button} ${H.TextBold}`,
|
|
1281
1287
|
onClick: () => {
|
|
1282
1288
|
v({
|
|
1283
1289
|
size: e.defaultFileSelectorSize,
|
|
@@ -1285,9 +1291,9 @@ function yr() {
|
|
|
1285
1291
|
It.WindowContent,
|
|
1286
1292
|
{
|
|
1287
1293
|
type: Nt.Single,
|
|
1288
|
-
allowedFormats:
|
|
1289
|
-
onFinish: (
|
|
1290
|
-
|
|
1294
|
+
allowedFormats: kt,
|
|
1295
|
+
onFinish: (S) => {
|
|
1296
|
+
S.source != null && (i == null || i.set("wallpaper", S.source));
|
|
1291
1297
|
},
|
|
1292
1298
|
...N
|
|
1293
1299
|
}
|
|
@@ -1297,41 +1303,41 @@ function yr() {
|
|
|
1297
1303
|
children: "Browse"
|
|
1298
1304
|
}
|
|
1299
1305
|
),
|
|
1300
|
-
/* @__PURE__ */ s("div", { className: `${
|
|
1301
|
-
({ id: N, source:
|
|
1306
|
+
/* @__PURE__ */ s("div", { className: `${E.Input} ${E.ImageSelectContainer}`, children: (P = (k = n == null ? void 0 : n.navigate(gr)) == null ? void 0 : k.getFiles()) == null ? void 0 : P.map(
|
|
1307
|
+
({ id: N, source: S }) => /* @__PURE__ */ x("label", { className: E.ImageSelect, children: [
|
|
1302
1308
|
/* @__PURE__ */ s(
|
|
1303
1309
|
"input",
|
|
1304
1310
|
{
|
|
1305
1311
|
type: "radio",
|
|
1306
|
-
value:
|
|
1312
|
+
value: S ?? "",
|
|
1307
1313
|
"aria-label": "Wallpaper image",
|
|
1308
|
-
checked:
|
|
1314
|
+
checked: S === a,
|
|
1309
1315
|
onChange: d,
|
|
1310
1316
|
tabIndex: 0
|
|
1311
1317
|
}
|
|
1312
1318
|
),
|
|
1313
|
-
/* @__PURE__ */ s("img", { src:
|
|
1319
|
+
/* @__PURE__ */ s("img", { src: S ?? "", alt: N, draggable: "false" })
|
|
1314
1320
|
] }, N)
|
|
1315
1321
|
) })
|
|
1316
1322
|
] })
|
|
1317
1323
|
] });
|
|
1318
1324
|
}
|
|
1319
|
-
function
|
|
1325
|
+
function Tr() {
|
|
1320
1326
|
const { systemName: e } = me(), n = Ye(), t = we();
|
|
1321
|
-
return /* @__PURE__ */
|
|
1322
|
-
/* @__PURE__ */
|
|
1327
|
+
return /* @__PURE__ */ x("div", { className: E.Option, children: [
|
|
1328
|
+
/* @__PURE__ */ x("p", { className: E.Label, children: [
|
|
1323
1329
|
"About ",
|
|
1324
1330
|
e
|
|
1325
1331
|
] }),
|
|
1326
|
-
/* @__PURE__ */
|
|
1332
|
+
/* @__PURE__ */ x("p", { className: H.TextLight, children: [
|
|
1327
1333
|
e,
|
|
1328
1334
|
" is a web-based operating system inspired by Ubuntu Linux and Windows made with React.js by Prozilla."
|
|
1329
1335
|
] }),
|
|
1330
|
-
/* @__PURE__ */
|
|
1336
|
+
/* @__PURE__ */ x("div", { className: E.ButtonGroup, children: [
|
|
1331
1337
|
/* @__PURE__ */ s(
|
|
1332
|
-
|
|
1338
|
+
Se,
|
|
1333
1339
|
{
|
|
1334
|
-
className: `${
|
|
1340
|
+
className: `${E.Button} ${H.TextBold}`,
|
|
1335
1341
|
onClick: (r) => {
|
|
1336
1342
|
r.preventDefault(), n == null || n.open("text-editor", {
|
|
1337
1343
|
mode: "view",
|
|
@@ -1343,9 +1349,9 @@ function _r() {
|
|
|
1343
1349
|
}
|
|
1344
1350
|
),
|
|
1345
1351
|
/* @__PURE__ */ s(
|
|
1346
|
-
|
|
1352
|
+
Se,
|
|
1347
1353
|
{
|
|
1348
|
-
className: `${
|
|
1354
|
+
className: `${E.Button} ${H.TextBold}`,
|
|
1349
1355
|
href: "https://github.com/prozilla-os/ProzillaOS",
|
|
1350
1356
|
children: "View source"
|
|
1351
1357
|
}
|
|
@@ -1353,33 +1359,33 @@ function _r() {
|
|
|
1353
1359
|
] })
|
|
1354
1360
|
] });
|
|
1355
1361
|
}
|
|
1356
|
-
function
|
|
1357
|
-
const e = we(), n = ue.MAX_BYTES, t = ue.getByteSize((e == null ? void 0 : e.toString()) ?? ""), r = ue.byteToKilobyte(n),
|
|
1358
|
-
return /* @__PURE__ */
|
|
1359
|
-
/* @__PURE__ */
|
|
1360
|
-
/* @__PURE__ */
|
|
1362
|
+
function xr() {
|
|
1363
|
+
const e = we(), n = ue.MAX_BYTES, t = ue.getByteSize((e == null ? void 0 : e.toString()) ?? ""), r = ue.byteToKilobyte(n), l = ue.byteToKilobyte(t), a = r - l;
|
|
1364
|
+
return /* @__PURE__ */ x(vt, { children: [
|
|
1365
|
+
/* @__PURE__ */ x("div", { className: `${E.Option} ${E.ProgressBarContainer}`, children: [
|
|
1366
|
+
/* @__PURE__ */ x("p", { className: E.Label, children: [
|
|
1361
1367
|
"Virtual Drive (",
|
|
1362
1368
|
Ae(r, 1),
|
|
1363
1369
|
" KB)"
|
|
1364
1370
|
] }),
|
|
1365
|
-
/* @__PURE__ */ s(
|
|
1366
|
-
/* @__PURE__ */
|
|
1367
|
-
/* @__PURE__ */
|
|
1368
|
-
Ae(
|
|
1371
|
+
/* @__PURE__ */ s(Dt, { fillPercentage: l / r * 100, className: E.ProgressBar }),
|
|
1372
|
+
/* @__PURE__ */ x("span", { className: E.ProgressBarLabels, children: [
|
|
1373
|
+
/* @__PURE__ */ x("p", { className: H.TextLight, children: [
|
|
1374
|
+
Ae(l, 1),
|
|
1369
1375
|
" KB used"
|
|
1370
1376
|
] }),
|
|
1371
|
-
/* @__PURE__ */
|
|
1377
|
+
/* @__PURE__ */ x("p", { className: H.TextLight, children: [
|
|
1372
1378
|
Ae(a, 1),
|
|
1373
1379
|
" KB free"
|
|
1374
1380
|
] })
|
|
1375
1381
|
] })
|
|
1376
1382
|
] }),
|
|
1377
|
-
/* @__PURE__ */
|
|
1378
|
-
/* @__PURE__ */ s("p", { className:
|
|
1383
|
+
/* @__PURE__ */ x("div", { className: E.Option, children: [
|
|
1384
|
+
/* @__PURE__ */ s("p", { className: E.Label, children: "Manage data" }),
|
|
1379
1385
|
/* @__PURE__ */ s(
|
|
1380
|
-
|
|
1386
|
+
Se,
|
|
1381
1387
|
{
|
|
1382
|
-
className: `${
|
|
1388
|
+
className: `${E.Button} ${E.ButtonDanger} ${H.TextBold}`,
|
|
1383
1389
|
onClick: () => {
|
|
1384
1390
|
e == null || e.reset();
|
|
1385
1391
|
},
|
|
@@ -1390,79 +1396,79 @@ function Tr() {
|
|
|
1390
1396
|
] });
|
|
1391
1397
|
}
|
|
1392
1398
|
function Er({ app: e, pins: n, setPins: t }) {
|
|
1393
|
-
const r = n.includes(e.id),
|
|
1394
|
-
Actions: (i) => /* @__PURE__ */
|
|
1395
|
-
/* @__PURE__ */ s(
|
|
1396
|
-
/* @__PURE__ */ s(
|
|
1397
|
-
const
|
|
1398
|
-
r ?
|
|
1399
|
-
const v =
|
|
1400
|
-
v == null || v.set("pins",
|
|
1399
|
+
const r = n.includes(e.id), l = qe(), a = Ye(), { onContextMenu: h } = Me({
|
|
1400
|
+
Actions: (i) => /* @__PURE__ */ x(Fe, { ...i, children: [
|
|
1401
|
+
/* @__PURE__ */ s(re, { label: "Launch", icon: e.iconUrl, onTrigger: () => a == null ? void 0 : a.open(e.id) }),
|
|
1402
|
+
/* @__PURE__ */ s(re, { label: r ? "Unpin from taskbar" : "Pin to taskbar", icon: Jt, onTrigger: () => {
|
|
1403
|
+
const y = [...n];
|
|
1404
|
+
r ? on(e.id, n) : y.push(e.id);
|
|
1405
|
+
const v = l == null ? void 0 : l.getSettings(Ee.VIRTUAL_PATHS.taskbar);
|
|
1406
|
+
v == null || v.set("pins", y.join(","));
|
|
1401
1407
|
} })
|
|
1402
1408
|
] })
|
|
1403
1409
|
});
|
|
1404
|
-
return /* @__PURE__ */
|
|
1405
|
-
/* @__PURE__ */
|
|
1406
|
-
/* @__PURE__ */ s(Ue, { className:
|
|
1410
|
+
return /* @__PURE__ */ x("div", { className: `${E.Option} ${E.OptionHorizontal}`, children: [
|
|
1411
|
+
/* @__PURE__ */ x("span", { className: E.Label, children: [
|
|
1412
|
+
/* @__PURE__ */ s(Ue, { className: E.Icon, source: e.iconUrl }),
|
|
1407
1413
|
e.name
|
|
1408
1414
|
] }),
|
|
1409
|
-
/* @__PURE__ */ s("button", { className:
|
|
1415
|
+
/* @__PURE__ */ s("button", { className: E.IconButton, onClick: h, children: /* @__PURE__ */ s(X, { icon: Zt }) })
|
|
1410
1416
|
] });
|
|
1411
1417
|
}
|
|
1412
1418
|
function Sr() {
|
|
1413
1419
|
const { appsConfig: e } = me(), n = qe(), [t, r] = te([]);
|
|
1414
1420
|
return se(() => {
|
|
1415
|
-
const
|
|
1416
|
-
|
|
1421
|
+
const l = n == null ? void 0 : n.getSettings(Ee.VIRTUAL_PATHS.taskbar);
|
|
1422
|
+
l == null || l.get("pins", (a) => {
|
|
1417
1423
|
r(a.split(","));
|
|
1418
1424
|
});
|
|
1419
|
-
}, [n]), /* @__PURE__ */
|
|
1420
|
-
/* @__PURE__ */ s("p", { className:
|
|
1425
|
+
}, [n]), /* @__PURE__ */ x("div", { className: `${E.Option} ${E.OptionList}`, children: [
|
|
1426
|
+
/* @__PURE__ */ s("p", { className: E.Label, children: "Apps" }),
|
|
1421
1427
|
e.apps.sort(
|
|
1422
|
-
(
|
|
1428
|
+
(l, a) => l.name.toLowerCase().localeCompare(a.name.toLowerCase())
|
|
1423
1429
|
).map(
|
|
1424
|
-
(
|
|
1430
|
+
(l) => /* @__PURE__ */ s(Er, { app: l, pins: t, setPins: r }, l.id)
|
|
1425
1431
|
)
|
|
1426
1432
|
] });
|
|
1427
1433
|
}
|
|
1428
|
-
function
|
|
1429
|
-
return /* @__PURE__ */ s("div", { className:
|
|
1430
|
-
|
|
1434
|
+
function Cr({ tab: e }) {
|
|
1435
|
+
return /* @__PURE__ */ s("div", { className: E.SettingsContainer, children: /* @__PURE__ */ x(
|
|
1436
|
+
He,
|
|
1431
1437
|
{
|
|
1432
1438
|
defaultIndex: e ?? 0,
|
|
1433
|
-
className:
|
|
1434
|
-
selectedTabClassName:
|
|
1435
|
-
selectedTabPanelClassName:
|
|
1439
|
+
className: E.Settings,
|
|
1440
|
+
selectedTabClassName: E.ActiveTab,
|
|
1441
|
+
selectedTabPanelClassName: E.ActivePanel,
|
|
1436
1442
|
children: [
|
|
1437
|
-
/* @__PURE__ */
|
|
1438
|
-
/* @__PURE__ */
|
|
1439
|
-
/* @__PURE__ */ s(X, { icon: Zt }),
|
|
1440
|
-
/* @__PURE__ */ s("p", { className: K.TextSemibold, children: "Apps" })
|
|
1441
|
-
] }),
|
|
1442
|
-
/* @__PURE__ */ E(de, { className: x.TabButton, tabIndex: "0", children: [
|
|
1443
|
+
/* @__PURE__ */ x(Ge, { className: E.Tabs, children: [
|
|
1444
|
+
/* @__PURE__ */ x(de, { className: E.TabButton, tabIndex: "0", children: [
|
|
1443
1445
|
/* @__PURE__ */ s(X, { icon: Qt }),
|
|
1444
|
-
/* @__PURE__ */ s("p", { className:
|
|
1446
|
+
/* @__PURE__ */ s("p", { className: H.TextSemibold, children: "Apps" })
|
|
1445
1447
|
] }),
|
|
1446
|
-
/* @__PURE__ */
|
|
1448
|
+
/* @__PURE__ */ x(de, { className: E.TabButton, tabIndex: "0", children: [
|
|
1447
1449
|
/* @__PURE__ */ s(X, { icon: en }),
|
|
1448
|
-
/* @__PURE__ */ s("p", { className:
|
|
1450
|
+
/* @__PURE__ */ s("p", { className: H.TextSemibold, children: "Appearance" })
|
|
1451
|
+
] }),
|
|
1452
|
+
/* @__PURE__ */ x(de, { className: E.TabButton, tabIndex: "0", children: [
|
|
1453
|
+
/* @__PURE__ */ s(X, { icon: tn }),
|
|
1454
|
+
/* @__PURE__ */ s("p", { className: H.TextSemibold, children: "Storage" })
|
|
1449
1455
|
] }),
|
|
1450
|
-
/* @__PURE__ */
|
|
1451
|
-
/* @__PURE__ */ s(X, { icon:
|
|
1452
|
-
/* @__PURE__ */ s("p", { className:
|
|
1456
|
+
/* @__PURE__ */ x(de, { className: E.TabButton, tabIndex: "0", children: [
|
|
1457
|
+
/* @__PURE__ */ s(X, { icon: yt }),
|
|
1458
|
+
/* @__PURE__ */ s("p", { className: H.TextSemibold, children: "About" })
|
|
1453
1459
|
] })
|
|
1454
1460
|
] }),
|
|
1455
|
-
/* @__PURE__ */ s(fe, { className:
|
|
1456
|
-
/* @__PURE__ */ s(fe, { className:
|
|
1457
|
-
/* @__PURE__ */ s(fe, { className:
|
|
1458
|
-
/* @__PURE__ */ s(fe, { className:
|
|
1461
|
+
/* @__PURE__ */ s(fe, { className: E.TabPanel, children: /* @__PURE__ */ s(Sr, {}) }),
|
|
1462
|
+
/* @__PURE__ */ s(fe, { className: E.TabPanel, children: /* @__PURE__ */ s(_r, {}) }),
|
|
1463
|
+
/* @__PURE__ */ s(fe, { className: E.TabPanel, children: /* @__PURE__ */ s(xr, {}) }),
|
|
1464
|
+
/* @__PURE__ */ s(fe, { className: E.TabPanel, children: /* @__PURE__ */ s(Tr, {}) })
|
|
1459
1465
|
]
|
|
1460
1466
|
}
|
|
1461
1467
|
) });
|
|
1462
1468
|
}
|
|
1463
|
-
const
|
|
1464
|
-
|
|
1469
|
+
const Pr = new bt("Settings", "settings", Cr).setIconUrl("https://os.prozilla.dev/assets/apps/icons/settings.svg").setRole(mt.APP_ROLES.settings).setCategory("Personalization");
|
|
1470
|
+
Pr.setMetadata({ name: "@prozilla-os/settings", version: "1.1.16", author: "Prozilla" });
|
|
1465
1471
|
export {
|
|
1466
|
-
|
|
1472
|
+
Pr as settings
|
|
1467
1473
|
};
|
|
1468
1474
|
//# sourceMappingURL=main.js.map
|