react-easy-wall 1.0.13 → 1.0.16
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/dist/cjs/_virtual/_commonjs-dynamic-modules.js +8 -0
- package/dist/cjs/_virtual/_commonjs-dynamic-modules.js.map +1 -0
- package/dist/cjs/_virtual/moment.js +12 -0
- package/dist/cjs/_virtual/moment.js.map +1 -0
- package/dist/cjs/_virtual/moment2.js +6 -0
- package/dist/cjs/_virtual/moment2.js.map +1 -0
- package/dist/cjs/components/panel/Panel.js +2 -2
- package/dist/cjs/components/panel/Panel.js.map +1 -1
- package/dist/cjs/components/panel/PanelButton.js +1 -1
- package/dist/cjs/components/panel/PanelButton.js.map +1 -1
- package/dist/cjs/components/panel/PanelHeader.js +1 -1
- package/dist/cjs/components/panel/PanelHeader.js.map +1 -1
- package/dist/cjs/components/panel/PanelItem.js.map +1 -1
- package/dist/cjs/components/panel/panel.actions.js +8 -0
- package/dist/cjs/components/panel/panel.actions.js.map +1 -1
- package/dist/cjs/index.js +1 -0
- package/dist/cjs/index.js.map +1 -1
- package/dist/cjs/node_modules/moment/moment.js +5697 -0
- package/dist/cjs/node_modules/moment/moment.js.map +1 -0
- package/dist/cjs/node_modules/universal-cookie/esm/index.js +411 -0
- package/dist/cjs/node_modules/universal-cookie/esm/index.js.map +1 -0
- package/dist/cjs/shared/cookies/cookies.utils.js +14 -0
- package/dist/cjs/shared/cookies/cookies.utils.js.map +1 -0
- package/dist/cjs/shared/cookies/index.js +8 -0
- package/dist/cjs/shared/cookies/index.js.map +1 -0
- package/dist/esm/_virtual/_commonjs-dynamic-modules.js +6 -0
- package/dist/esm/_virtual/_commonjs-dynamic-modules.js.map +1 -0
- package/dist/esm/_virtual/moment.js +8 -0
- package/dist/esm/_virtual/moment.js.map +1 -0
- package/dist/esm/_virtual/moment2.js +4 -0
- package/dist/esm/_virtual/moment2.js.map +1 -0
- package/dist/esm/components/panel/Panel.js +3 -3
- package/dist/esm/components/panel/Panel.js.map +1 -1
- package/dist/esm/components/panel/PanelButton.js +1 -1
- package/dist/esm/components/panel/PanelButton.js.map +1 -1
- package/dist/esm/components/panel/PanelHeader.js +1 -1
- package/dist/esm/components/panel/PanelHeader.js.map +1 -1
- package/dist/esm/components/panel/PanelItem.js.map +1 -1
- package/dist/esm/components/panel/panel.actions.js +8 -1
- package/dist/esm/components/panel/panel.actions.js.map +1 -1
- package/dist/esm/index.js +1 -1
- package/dist/esm/node_modules/moment/moment.js +5695 -0
- package/dist/esm/node_modules/moment/moment.js.map +1 -0
- package/dist/esm/node_modules/universal-cookie/esm/index.js +407 -0
- package/dist/esm/node_modules/universal-cookie/esm/index.js.map +1 -0
- package/dist/esm/shared/cookies/cookies.utils.js +12 -0
- package/dist/esm/shared/cookies/cookies.utils.js.map +1 -0
- package/dist/esm/shared/cookies/index.js +6 -0
- package/dist/esm/shared/cookies/index.js.map +1 -0
- package/dist/esm/types/components/panel/Panel.d.ts +1 -0
- package/dist/esm/types/components/panel/PanelFooter.d.ts +11 -0
- package/dist/esm/types/components/panel/PanelHeader.d.ts +1 -1
- package/dist/esm/types/components/panel/PanelItem.d.ts +1 -1
- package/dist/esm/types/components/panel/panel.actions.d.ts +2 -0
- package/dist/esm/types/config/config.types.d.ts +1 -0
- package/dist/esm/types/shared/cookies/cookies.utils.d.ts +6 -0
- package/dist/esm/types/shared/cookies/index.d.ts +2 -0
- package/dist/index.d.ts +9 -6
- package/package.json +4 -2
|
@@ -0,0 +1,407 @@
|
|
|
1
|
+
var dist = {};
|
|
2
|
+
|
|
3
|
+
var hasRequiredDist;
|
|
4
|
+
|
|
5
|
+
function requireDist () {
|
|
6
|
+
if (hasRequiredDist) return dist;
|
|
7
|
+
hasRequiredDist = 1;
|
|
8
|
+
Object.defineProperty(dist, "__esModule", { value: true });
|
|
9
|
+
dist.parse = parse;
|
|
10
|
+
dist.serialize = serialize;
|
|
11
|
+
/**
|
|
12
|
+
* RegExp to match cookie-name in RFC 6265 sec 4.1.1
|
|
13
|
+
* This refers out to the obsoleted definition of token in RFC 2616 sec 2.2
|
|
14
|
+
* which has been replaced by the token definition in RFC 7230 appendix B.
|
|
15
|
+
*
|
|
16
|
+
* cookie-name = token
|
|
17
|
+
* token = 1*tchar
|
|
18
|
+
* tchar = "!" / "#" / "$" / "%" / "&" / "'" /
|
|
19
|
+
* "*" / "+" / "-" / "." / "^" / "_" /
|
|
20
|
+
* "`" / "|" / "~" / DIGIT / ALPHA
|
|
21
|
+
*
|
|
22
|
+
* Note: Allowing more characters - https://github.com/jshttp/cookie/issues/191
|
|
23
|
+
* Allow same range as cookie value, except `=`, which delimits end of name.
|
|
24
|
+
*/
|
|
25
|
+
const cookieNameRegExp = /^[\u0021-\u003A\u003C\u003E-\u007E]+$/;
|
|
26
|
+
/**
|
|
27
|
+
* RegExp to match cookie-value in RFC 6265 sec 4.1.1
|
|
28
|
+
*
|
|
29
|
+
* cookie-value = *cookie-octet / ( DQUOTE *cookie-octet DQUOTE )
|
|
30
|
+
* cookie-octet = %x21 / %x23-2B / %x2D-3A / %x3C-5B / %x5D-7E
|
|
31
|
+
* ; US-ASCII characters excluding CTLs,
|
|
32
|
+
* ; whitespace DQUOTE, comma, semicolon,
|
|
33
|
+
* ; and backslash
|
|
34
|
+
*
|
|
35
|
+
* Allowing more characters: https://github.com/jshttp/cookie/issues/191
|
|
36
|
+
* Comma, backslash, and DQUOTE are not part of the parsing algorithm.
|
|
37
|
+
*/
|
|
38
|
+
const cookieValueRegExp = /^[\u0021-\u003A\u003C-\u007E]*$/;
|
|
39
|
+
/**
|
|
40
|
+
* RegExp to match domain-value in RFC 6265 sec 4.1.1
|
|
41
|
+
*
|
|
42
|
+
* domain-value = <subdomain>
|
|
43
|
+
* ; defined in [RFC1034], Section 3.5, as
|
|
44
|
+
* ; enhanced by [RFC1123], Section 2.1
|
|
45
|
+
* <subdomain> = <label> | <subdomain> "." <label>
|
|
46
|
+
* <label> = <let-dig> [ [ <ldh-str> ] <let-dig> ]
|
|
47
|
+
* Labels must be 63 characters or less.
|
|
48
|
+
* 'let-dig' not 'letter' in the first char, per RFC1123
|
|
49
|
+
* <ldh-str> = <let-dig-hyp> | <let-dig-hyp> <ldh-str>
|
|
50
|
+
* <let-dig-hyp> = <let-dig> | "-"
|
|
51
|
+
* <let-dig> = <letter> | <digit>
|
|
52
|
+
* <letter> = any one of the 52 alphabetic characters A through Z in
|
|
53
|
+
* upper case and a through z in lower case
|
|
54
|
+
* <digit> = any one of the ten digits 0 through 9
|
|
55
|
+
*
|
|
56
|
+
* Keep support for leading dot: https://github.com/jshttp/cookie/issues/173
|
|
57
|
+
*
|
|
58
|
+
* > (Note that a leading %x2E ("."), if present, is ignored even though that
|
|
59
|
+
* character is not permitted, but a trailing %x2E ("."), if present, will
|
|
60
|
+
* cause the user agent to ignore the attribute.)
|
|
61
|
+
*/
|
|
62
|
+
const domainValueRegExp = /^([.]?[a-z0-9]([a-z0-9-]{0,61}[a-z0-9])?)([.][a-z0-9]([a-z0-9-]{0,61}[a-z0-9])?)*$/i;
|
|
63
|
+
/**
|
|
64
|
+
* RegExp to match path-value in RFC 6265 sec 4.1.1
|
|
65
|
+
*
|
|
66
|
+
* path-value = <any CHAR except CTLs or ";">
|
|
67
|
+
* CHAR = %x01-7F
|
|
68
|
+
* ; defined in RFC 5234 appendix B.1
|
|
69
|
+
*/
|
|
70
|
+
const pathValueRegExp = /^[\u0020-\u003A\u003D-\u007E]*$/;
|
|
71
|
+
const __toString = Object.prototype.toString;
|
|
72
|
+
const NullObject = /* @__PURE__ */ (() => {
|
|
73
|
+
const C = function () { };
|
|
74
|
+
C.prototype = Object.create(null);
|
|
75
|
+
return C;
|
|
76
|
+
})();
|
|
77
|
+
/**
|
|
78
|
+
* Parse a cookie header.
|
|
79
|
+
*
|
|
80
|
+
* Parse the given cookie header string into an object
|
|
81
|
+
* The object has the various cookies as keys(names) => values
|
|
82
|
+
*/
|
|
83
|
+
function parse(str, options) {
|
|
84
|
+
const obj = new NullObject();
|
|
85
|
+
const len = str.length;
|
|
86
|
+
// RFC 6265 sec 4.1.1, RFC 2616 2.2 defines a cookie name consists of one char minimum, plus '='.
|
|
87
|
+
if (len < 2)
|
|
88
|
+
return obj;
|
|
89
|
+
const dec = options?.decode || decode;
|
|
90
|
+
let index = 0;
|
|
91
|
+
do {
|
|
92
|
+
const eqIdx = str.indexOf("=", index);
|
|
93
|
+
if (eqIdx === -1)
|
|
94
|
+
break; // No more cookie pairs.
|
|
95
|
+
const colonIdx = str.indexOf(";", index);
|
|
96
|
+
const endIdx = colonIdx === -1 ? len : colonIdx;
|
|
97
|
+
if (eqIdx > endIdx) {
|
|
98
|
+
// backtrack on prior semicolon
|
|
99
|
+
index = str.lastIndexOf(";", eqIdx - 1) + 1;
|
|
100
|
+
continue;
|
|
101
|
+
}
|
|
102
|
+
const keyStartIdx = startIndex(str, index, eqIdx);
|
|
103
|
+
const keyEndIdx = endIndex(str, eqIdx, keyStartIdx);
|
|
104
|
+
const key = str.slice(keyStartIdx, keyEndIdx);
|
|
105
|
+
// only assign once
|
|
106
|
+
if (obj[key] === undefined) {
|
|
107
|
+
let valStartIdx = startIndex(str, eqIdx + 1, endIdx);
|
|
108
|
+
let valEndIdx = endIndex(str, endIdx, valStartIdx);
|
|
109
|
+
const value = dec(str.slice(valStartIdx, valEndIdx));
|
|
110
|
+
obj[key] = value;
|
|
111
|
+
}
|
|
112
|
+
index = endIdx + 1;
|
|
113
|
+
} while (index < len);
|
|
114
|
+
return obj;
|
|
115
|
+
}
|
|
116
|
+
function startIndex(str, index, max) {
|
|
117
|
+
do {
|
|
118
|
+
const code = str.charCodeAt(index);
|
|
119
|
+
if (code !== 0x20 /* */ && code !== 0x09 /* \t */)
|
|
120
|
+
return index;
|
|
121
|
+
} while (++index < max);
|
|
122
|
+
return max;
|
|
123
|
+
}
|
|
124
|
+
function endIndex(str, index, min) {
|
|
125
|
+
while (index > min) {
|
|
126
|
+
const code = str.charCodeAt(--index);
|
|
127
|
+
if (code !== 0x20 /* */ && code !== 0x09 /* \t */)
|
|
128
|
+
return index + 1;
|
|
129
|
+
}
|
|
130
|
+
return min;
|
|
131
|
+
}
|
|
132
|
+
/**
|
|
133
|
+
* Serialize data into a cookie header.
|
|
134
|
+
*
|
|
135
|
+
* Serialize a name value pair into a cookie string suitable for
|
|
136
|
+
* http headers. An optional options object specifies cookie parameters.
|
|
137
|
+
*
|
|
138
|
+
* serialize('foo', 'bar', { httpOnly: true })
|
|
139
|
+
* => "foo=bar; httpOnly"
|
|
140
|
+
*/
|
|
141
|
+
function serialize(name, val, options) {
|
|
142
|
+
const enc = options?.encode || encodeURIComponent;
|
|
143
|
+
if (!cookieNameRegExp.test(name)) {
|
|
144
|
+
throw new TypeError(`argument name is invalid: ${name}`);
|
|
145
|
+
}
|
|
146
|
+
const value = enc(val);
|
|
147
|
+
if (!cookieValueRegExp.test(value)) {
|
|
148
|
+
throw new TypeError(`argument val is invalid: ${val}`);
|
|
149
|
+
}
|
|
150
|
+
let str = name + "=" + value;
|
|
151
|
+
if (!options)
|
|
152
|
+
return str;
|
|
153
|
+
if (options.maxAge !== undefined) {
|
|
154
|
+
if (!Number.isInteger(options.maxAge)) {
|
|
155
|
+
throw new TypeError(`option maxAge is invalid: ${options.maxAge}`);
|
|
156
|
+
}
|
|
157
|
+
str += "; Max-Age=" + options.maxAge;
|
|
158
|
+
}
|
|
159
|
+
if (options.domain) {
|
|
160
|
+
if (!domainValueRegExp.test(options.domain)) {
|
|
161
|
+
throw new TypeError(`option domain is invalid: ${options.domain}`);
|
|
162
|
+
}
|
|
163
|
+
str += "; Domain=" + options.domain;
|
|
164
|
+
}
|
|
165
|
+
if (options.path) {
|
|
166
|
+
if (!pathValueRegExp.test(options.path)) {
|
|
167
|
+
throw new TypeError(`option path is invalid: ${options.path}`);
|
|
168
|
+
}
|
|
169
|
+
str += "; Path=" + options.path;
|
|
170
|
+
}
|
|
171
|
+
if (options.expires) {
|
|
172
|
+
if (!isDate(options.expires) ||
|
|
173
|
+
!Number.isFinite(options.expires.valueOf())) {
|
|
174
|
+
throw new TypeError(`option expires is invalid: ${options.expires}`);
|
|
175
|
+
}
|
|
176
|
+
str += "; Expires=" + options.expires.toUTCString();
|
|
177
|
+
}
|
|
178
|
+
if (options.httpOnly) {
|
|
179
|
+
str += "; HttpOnly";
|
|
180
|
+
}
|
|
181
|
+
if (options.secure) {
|
|
182
|
+
str += "; Secure";
|
|
183
|
+
}
|
|
184
|
+
if (options.partitioned) {
|
|
185
|
+
str += "; Partitioned";
|
|
186
|
+
}
|
|
187
|
+
if (options.priority) {
|
|
188
|
+
const priority = typeof options.priority === "string"
|
|
189
|
+
? options.priority.toLowerCase()
|
|
190
|
+
: undefined;
|
|
191
|
+
switch (priority) {
|
|
192
|
+
case "low":
|
|
193
|
+
str += "; Priority=Low";
|
|
194
|
+
break;
|
|
195
|
+
case "medium":
|
|
196
|
+
str += "; Priority=Medium";
|
|
197
|
+
break;
|
|
198
|
+
case "high":
|
|
199
|
+
str += "; Priority=High";
|
|
200
|
+
break;
|
|
201
|
+
default:
|
|
202
|
+
throw new TypeError(`option priority is invalid: ${options.priority}`);
|
|
203
|
+
}
|
|
204
|
+
}
|
|
205
|
+
if (options.sameSite) {
|
|
206
|
+
const sameSite = typeof options.sameSite === "string"
|
|
207
|
+
? options.sameSite.toLowerCase()
|
|
208
|
+
: options.sameSite;
|
|
209
|
+
switch (sameSite) {
|
|
210
|
+
case true:
|
|
211
|
+
case "strict":
|
|
212
|
+
str += "; SameSite=Strict";
|
|
213
|
+
break;
|
|
214
|
+
case "lax":
|
|
215
|
+
str += "; SameSite=Lax";
|
|
216
|
+
break;
|
|
217
|
+
case "none":
|
|
218
|
+
str += "; SameSite=None";
|
|
219
|
+
break;
|
|
220
|
+
default:
|
|
221
|
+
throw new TypeError(`option sameSite is invalid: ${options.sameSite}`);
|
|
222
|
+
}
|
|
223
|
+
}
|
|
224
|
+
return str;
|
|
225
|
+
}
|
|
226
|
+
/**
|
|
227
|
+
* URL-decode string value. Optimized to skip native call when no %.
|
|
228
|
+
*/
|
|
229
|
+
function decode(str) {
|
|
230
|
+
if (str.indexOf("%") === -1)
|
|
231
|
+
return str;
|
|
232
|
+
try {
|
|
233
|
+
return decodeURIComponent(str);
|
|
234
|
+
}
|
|
235
|
+
catch (e) {
|
|
236
|
+
return str;
|
|
237
|
+
}
|
|
238
|
+
}
|
|
239
|
+
/**
|
|
240
|
+
* Determine if value is a Date.
|
|
241
|
+
*/
|
|
242
|
+
function isDate(val) {
|
|
243
|
+
return __toString.call(val) === "[object Date]";
|
|
244
|
+
}
|
|
245
|
+
|
|
246
|
+
return dist;
|
|
247
|
+
}
|
|
248
|
+
|
|
249
|
+
var distExports = requireDist();
|
|
250
|
+
|
|
251
|
+
function hasDocumentCookie() {
|
|
252
|
+
const testingValue = typeof global === 'undefined'
|
|
253
|
+
? undefined
|
|
254
|
+
: global.TEST_HAS_DOCUMENT_COOKIE;
|
|
255
|
+
if (typeof testingValue === 'boolean') {
|
|
256
|
+
return testingValue;
|
|
257
|
+
}
|
|
258
|
+
// Can we get/set cookies on document.cookie?
|
|
259
|
+
return typeof document === 'object' && typeof document.cookie === 'string';
|
|
260
|
+
}
|
|
261
|
+
function parseCookies(cookies) {
|
|
262
|
+
if (typeof cookies === 'string') {
|
|
263
|
+
return distExports.parse(cookies);
|
|
264
|
+
}
|
|
265
|
+
else if (typeof cookies === 'object' && cookies !== null) {
|
|
266
|
+
return cookies;
|
|
267
|
+
}
|
|
268
|
+
else {
|
|
269
|
+
return {};
|
|
270
|
+
}
|
|
271
|
+
}
|
|
272
|
+
function readCookie(value, options = {}) {
|
|
273
|
+
const cleanValue = cleanupCookieValue(value);
|
|
274
|
+
if (!options.doNotParse) {
|
|
275
|
+
try {
|
|
276
|
+
return JSON.parse(cleanValue);
|
|
277
|
+
}
|
|
278
|
+
catch (e) {
|
|
279
|
+
// At least we tried
|
|
280
|
+
}
|
|
281
|
+
}
|
|
282
|
+
// Ignore clean value if we failed the deserialization
|
|
283
|
+
// It is not relevant anymore to trim those values
|
|
284
|
+
return value;
|
|
285
|
+
}
|
|
286
|
+
function cleanupCookieValue(value) {
|
|
287
|
+
// express prepend j: before serializing a cookie
|
|
288
|
+
if (value && value[0] === 'j' && value[1] === ':') {
|
|
289
|
+
return value.substr(2);
|
|
290
|
+
}
|
|
291
|
+
return value;
|
|
292
|
+
}
|
|
293
|
+
|
|
294
|
+
class Cookies {
|
|
295
|
+
constructor(cookies, defaultSetOptions = {}) {
|
|
296
|
+
this.changeListeners = [];
|
|
297
|
+
this.HAS_DOCUMENT_COOKIE = false;
|
|
298
|
+
this.update = () => {
|
|
299
|
+
if (!this.HAS_DOCUMENT_COOKIE) {
|
|
300
|
+
return;
|
|
301
|
+
}
|
|
302
|
+
const previousCookies = this.cookies;
|
|
303
|
+
this.cookies = distExports.parse(document.cookie);
|
|
304
|
+
this._checkChanges(previousCookies);
|
|
305
|
+
};
|
|
306
|
+
const domCookies = typeof document === 'undefined' ? '' : document.cookie;
|
|
307
|
+
this.cookies = parseCookies(cookies || domCookies);
|
|
308
|
+
this.defaultSetOptions = defaultSetOptions;
|
|
309
|
+
this.HAS_DOCUMENT_COOKIE = hasDocumentCookie();
|
|
310
|
+
}
|
|
311
|
+
_emitChange(params) {
|
|
312
|
+
for (let i = 0; i < this.changeListeners.length; ++i) {
|
|
313
|
+
this.changeListeners[i](params);
|
|
314
|
+
}
|
|
315
|
+
}
|
|
316
|
+
_checkChanges(previousCookies) {
|
|
317
|
+
const names = new Set(Object.keys(previousCookies).concat(Object.keys(this.cookies)));
|
|
318
|
+
names.forEach((name) => {
|
|
319
|
+
if (previousCookies[name] !== this.cookies[name]) {
|
|
320
|
+
this._emitChange({
|
|
321
|
+
name,
|
|
322
|
+
value: readCookie(this.cookies[name]),
|
|
323
|
+
});
|
|
324
|
+
}
|
|
325
|
+
});
|
|
326
|
+
}
|
|
327
|
+
_startPolling() {
|
|
328
|
+
this.pollingInterval = setInterval(this.update, 300);
|
|
329
|
+
}
|
|
330
|
+
_stopPolling() {
|
|
331
|
+
if (this.pollingInterval) {
|
|
332
|
+
clearInterval(this.pollingInterval);
|
|
333
|
+
}
|
|
334
|
+
}
|
|
335
|
+
get(name, options = {}) {
|
|
336
|
+
if (!options.doNotUpdate) {
|
|
337
|
+
this.update();
|
|
338
|
+
}
|
|
339
|
+
return readCookie(this.cookies[name], options);
|
|
340
|
+
}
|
|
341
|
+
getAll(options = {}) {
|
|
342
|
+
if (!options.doNotUpdate) {
|
|
343
|
+
this.update();
|
|
344
|
+
}
|
|
345
|
+
const result = {};
|
|
346
|
+
for (let name in this.cookies) {
|
|
347
|
+
result[name] = readCookie(this.cookies[name], options);
|
|
348
|
+
}
|
|
349
|
+
return result;
|
|
350
|
+
}
|
|
351
|
+
set(name, value, options) {
|
|
352
|
+
if (options) {
|
|
353
|
+
options = Object.assign(Object.assign({}, this.defaultSetOptions), options);
|
|
354
|
+
}
|
|
355
|
+
else {
|
|
356
|
+
options = this.defaultSetOptions;
|
|
357
|
+
}
|
|
358
|
+
const stringValue = typeof value === 'string' ? value : JSON.stringify(value);
|
|
359
|
+
this.cookies = Object.assign(Object.assign({}, this.cookies), { [name]: stringValue });
|
|
360
|
+
if (this.HAS_DOCUMENT_COOKIE) {
|
|
361
|
+
document.cookie = distExports.serialize(name, stringValue, options);
|
|
362
|
+
}
|
|
363
|
+
this._emitChange({ name, value, options });
|
|
364
|
+
}
|
|
365
|
+
remove(name, options) {
|
|
366
|
+
const finalOptions = (options = Object.assign(Object.assign(Object.assign({}, this.defaultSetOptions), options), { expires: new Date(1970, 1, 1, 0, 0, 1), maxAge: 0 }));
|
|
367
|
+
this.cookies = Object.assign({}, this.cookies);
|
|
368
|
+
delete this.cookies[name];
|
|
369
|
+
if (this.HAS_DOCUMENT_COOKIE) {
|
|
370
|
+
document.cookie = distExports.serialize(name, '', finalOptions);
|
|
371
|
+
}
|
|
372
|
+
this._emitChange({ name, value: undefined, options });
|
|
373
|
+
}
|
|
374
|
+
addChangeListener(callback) {
|
|
375
|
+
this.changeListeners.push(callback);
|
|
376
|
+
if (this.HAS_DOCUMENT_COOKIE && this.changeListeners.length === 1) {
|
|
377
|
+
if (typeof window === 'object' && 'cookieStore' in window) {
|
|
378
|
+
window.cookieStore.addEventListener('change', this.update);
|
|
379
|
+
}
|
|
380
|
+
else {
|
|
381
|
+
this._startPolling();
|
|
382
|
+
}
|
|
383
|
+
}
|
|
384
|
+
}
|
|
385
|
+
removeChangeListener(callback) {
|
|
386
|
+
const idx = this.changeListeners.indexOf(callback);
|
|
387
|
+
if (idx >= 0) {
|
|
388
|
+
this.changeListeners.splice(idx, 1);
|
|
389
|
+
}
|
|
390
|
+
if (this.HAS_DOCUMENT_COOKIE && this.changeListeners.length === 0) {
|
|
391
|
+
if (typeof window === 'object' && 'cookieStore' in window) {
|
|
392
|
+
window.cookieStore.removeEventListener('change', this.update);
|
|
393
|
+
}
|
|
394
|
+
else {
|
|
395
|
+
this._stopPolling();
|
|
396
|
+
}
|
|
397
|
+
}
|
|
398
|
+
}
|
|
399
|
+
removeAllChangeListeners() {
|
|
400
|
+
while (this.changeListeners.length > 0) {
|
|
401
|
+
this.removeChangeListener(this.changeListeners[0]);
|
|
402
|
+
}
|
|
403
|
+
}
|
|
404
|
+
}
|
|
405
|
+
|
|
406
|
+
export { Cookies as default };
|
|
407
|
+
//# sourceMappingURL=index.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"index.js","sources":["../../../../../node_modules/universal-cookie/esm/index.mjs"],"sourcesContent":["var dist = {};\n\nvar hasRequiredDist;\n\nfunction requireDist () {\n\tif (hasRequiredDist) return dist;\n\thasRequiredDist = 1;\n\tObject.defineProperty(dist, \"__esModule\", { value: true });\n\tdist.parse = parse;\n\tdist.serialize = serialize;\n\t/**\n\t * RegExp to match cookie-name in RFC 6265 sec 4.1.1\n\t * This refers out to the obsoleted definition of token in RFC 2616 sec 2.2\n\t * which has been replaced by the token definition in RFC 7230 appendix B.\n\t *\n\t * cookie-name = token\n\t * token = 1*tchar\n\t * tchar = \"!\" / \"#\" / \"$\" / \"%\" / \"&\" / \"'\" /\n\t * \"*\" / \"+\" / \"-\" / \".\" / \"^\" / \"_\" /\n\t * \"`\" / \"|\" / \"~\" / DIGIT / ALPHA\n\t *\n\t * Note: Allowing more characters - https://github.com/jshttp/cookie/issues/191\n\t * Allow same range as cookie value, except `=`, which delimits end of name.\n\t */\n\tconst cookieNameRegExp = /^[\\u0021-\\u003A\\u003C\\u003E-\\u007E]+$/;\n\t/**\n\t * RegExp to match cookie-value in RFC 6265 sec 4.1.1\n\t *\n\t * cookie-value = *cookie-octet / ( DQUOTE *cookie-octet DQUOTE )\n\t * cookie-octet = %x21 / %x23-2B / %x2D-3A / %x3C-5B / %x5D-7E\n\t * ; US-ASCII characters excluding CTLs,\n\t * ; whitespace DQUOTE, comma, semicolon,\n\t * ; and backslash\n\t *\n\t * Allowing more characters: https://github.com/jshttp/cookie/issues/191\n\t * Comma, backslash, and DQUOTE are not part of the parsing algorithm.\n\t */\n\tconst cookieValueRegExp = /^[\\u0021-\\u003A\\u003C-\\u007E]*$/;\n\t/**\n\t * RegExp to match domain-value in RFC 6265 sec 4.1.1\n\t *\n\t * domain-value = <subdomain>\n\t * ; defined in [RFC1034], Section 3.5, as\n\t * ; enhanced by [RFC1123], Section 2.1\n\t * <subdomain> = <label> | <subdomain> \".\" <label>\n\t * <label> = <let-dig> [ [ <ldh-str> ] <let-dig> ]\n\t * Labels must be 63 characters or less.\n\t * 'let-dig' not 'letter' in the first char, per RFC1123\n\t * <ldh-str> = <let-dig-hyp> | <let-dig-hyp> <ldh-str>\n\t * <let-dig-hyp> = <let-dig> | \"-\"\n\t * <let-dig> = <letter> | <digit>\n\t * <letter> = any one of the 52 alphabetic characters A through Z in\n\t * upper case and a through z in lower case\n\t * <digit> = any one of the ten digits 0 through 9\n\t *\n\t * Keep support for leading dot: https://github.com/jshttp/cookie/issues/173\n\t *\n\t * > (Note that a leading %x2E (\".\"), if present, is ignored even though that\n\t * character is not permitted, but a trailing %x2E (\".\"), if present, will\n\t * cause the user agent to ignore the attribute.)\n\t */\n\tconst domainValueRegExp = /^([.]?[a-z0-9]([a-z0-9-]{0,61}[a-z0-9])?)([.][a-z0-9]([a-z0-9-]{0,61}[a-z0-9])?)*$/i;\n\t/**\n\t * RegExp to match path-value in RFC 6265 sec 4.1.1\n\t *\n\t * path-value = <any CHAR except CTLs or \";\">\n\t * CHAR = %x01-7F\n\t * ; defined in RFC 5234 appendix B.1\n\t */\n\tconst pathValueRegExp = /^[\\u0020-\\u003A\\u003D-\\u007E]*$/;\n\tconst __toString = Object.prototype.toString;\n\tconst NullObject = /* @__PURE__ */ (() => {\n\t const C = function () { };\n\t C.prototype = Object.create(null);\n\t return C;\n\t})();\n\t/**\n\t * Parse a cookie header.\n\t *\n\t * Parse the given cookie header string into an object\n\t * The object has the various cookies as keys(names) => values\n\t */\n\tfunction parse(str, options) {\n\t const obj = new NullObject();\n\t const len = str.length;\n\t // RFC 6265 sec 4.1.1, RFC 2616 2.2 defines a cookie name consists of one char minimum, plus '='.\n\t if (len < 2)\n\t return obj;\n\t const dec = options?.decode || decode;\n\t let index = 0;\n\t do {\n\t const eqIdx = str.indexOf(\"=\", index);\n\t if (eqIdx === -1)\n\t break; // No more cookie pairs.\n\t const colonIdx = str.indexOf(\";\", index);\n\t const endIdx = colonIdx === -1 ? len : colonIdx;\n\t if (eqIdx > endIdx) {\n\t // backtrack on prior semicolon\n\t index = str.lastIndexOf(\";\", eqIdx - 1) + 1;\n\t continue;\n\t }\n\t const keyStartIdx = startIndex(str, index, eqIdx);\n\t const keyEndIdx = endIndex(str, eqIdx, keyStartIdx);\n\t const key = str.slice(keyStartIdx, keyEndIdx);\n\t // only assign once\n\t if (obj[key] === undefined) {\n\t let valStartIdx = startIndex(str, eqIdx + 1, endIdx);\n\t let valEndIdx = endIndex(str, endIdx, valStartIdx);\n\t const value = dec(str.slice(valStartIdx, valEndIdx));\n\t obj[key] = value;\n\t }\n\t index = endIdx + 1;\n\t } while (index < len);\n\t return obj;\n\t}\n\tfunction startIndex(str, index, max) {\n\t do {\n\t const code = str.charCodeAt(index);\n\t if (code !== 0x20 /* */ && code !== 0x09 /* \\t */)\n\t return index;\n\t } while (++index < max);\n\t return max;\n\t}\n\tfunction endIndex(str, index, min) {\n\t while (index > min) {\n\t const code = str.charCodeAt(--index);\n\t if (code !== 0x20 /* */ && code !== 0x09 /* \\t */)\n\t return index + 1;\n\t }\n\t return min;\n\t}\n\t/**\n\t * Serialize data into a cookie header.\n\t *\n\t * Serialize a name value pair into a cookie string suitable for\n\t * http headers. An optional options object specifies cookie parameters.\n\t *\n\t * serialize('foo', 'bar', { httpOnly: true })\n\t * => \"foo=bar; httpOnly\"\n\t */\n\tfunction serialize(name, val, options) {\n\t const enc = options?.encode || encodeURIComponent;\n\t if (!cookieNameRegExp.test(name)) {\n\t throw new TypeError(`argument name is invalid: ${name}`);\n\t }\n\t const value = enc(val);\n\t if (!cookieValueRegExp.test(value)) {\n\t throw new TypeError(`argument val is invalid: ${val}`);\n\t }\n\t let str = name + \"=\" + value;\n\t if (!options)\n\t return str;\n\t if (options.maxAge !== undefined) {\n\t if (!Number.isInteger(options.maxAge)) {\n\t throw new TypeError(`option maxAge is invalid: ${options.maxAge}`);\n\t }\n\t str += \"; Max-Age=\" + options.maxAge;\n\t }\n\t if (options.domain) {\n\t if (!domainValueRegExp.test(options.domain)) {\n\t throw new TypeError(`option domain is invalid: ${options.domain}`);\n\t }\n\t str += \"; Domain=\" + options.domain;\n\t }\n\t if (options.path) {\n\t if (!pathValueRegExp.test(options.path)) {\n\t throw new TypeError(`option path is invalid: ${options.path}`);\n\t }\n\t str += \"; Path=\" + options.path;\n\t }\n\t if (options.expires) {\n\t if (!isDate(options.expires) ||\n\t !Number.isFinite(options.expires.valueOf())) {\n\t throw new TypeError(`option expires is invalid: ${options.expires}`);\n\t }\n\t str += \"; Expires=\" + options.expires.toUTCString();\n\t }\n\t if (options.httpOnly) {\n\t str += \"; HttpOnly\";\n\t }\n\t if (options.secure) {\n\t str += \"; Secure\";\n\t }\n\t if (options.partitioned) {\n\t str += \"; Partitioned\";\n\t }\n\t if (options.priority) {\n\t const priority = typeof options.priority === \"string\"\n\t ? options.priority.toLowerCase()\n\t : undefined;\n\t switch (priority) {\n\t case \"low\":\n\t str += \"; Priority=Low\";\n\t break;\n\t case \"medium\":\n\t str += \"; Priority=Medium\";\n\t break;\n\t case \"high\":\n\t str += \"; Priority=High\";\n\t break;\n\t default:\n\t throw new TypeError(`option priority is invalid: ${options.priority}`);\n\t }\n\t }\n\t if (options.sameSite) {\n\t const sameSite = typeof options.sameSite === \"string\"\n\t ? options.sameSite.toLowerCase()\n\t : options.sameSite;\n\t switch (sameSite) {\n\t case true:\n\t case \"strict\":\n\t str += \"; SameSite=Strict\";\n\t break;\n\t case \"lax\":\n\t str += \"; SameSite=Lax\";\n\t break;\n\t case \"none\":\n\t str += \"; SameSite=None\";\n\t break;\n\t default:\n\t throw new TypeError(`option sameSite is invalid: ${options.sameSite}`);\n\t }\n\t }\n\t return str;\n\t}\n\t/**\n\t * URL-decode string value. Optimized to skip native call when no %.\n\t */\n\tfunction decode(str) {\n\t if (str.indexOf(\"%\") === -1)\n\t return str;\n\t try {\n\t return decodeURIComponent(str);\n\t }\n\t catch (e) {\n\t return str;\n\t }\n\t}\n\t/**\n\t * Determine if value is a Date.\n\t */\n\tfunction isDate(val) {\n\t return __toString.call(val) === \"[object Date]\";\n\t}\n\t\n\treturn dist;\n}\n\nvar distExports = requireDist();\n\nfunction hasDocumentCookie() {\n const testingValue = typeof global === 'undefined'\n ? undefined\n : global.TEST_HAS_DOCUMENT_COOKIE;\n if (typeof testingValue === 'boolean') {\n return testingValue;\n }\n // Can we get/set cookies on document.cookie?\n return typeof document === 'object' && typeof document.cookie === 'string';\n}\nfunction parseCookies(cookies) {\n if (typeof cookies === 'string') {\n return distExports.parse(cookies);\n }\n else if (typeof cookies === 'object' && cookies !== null) {\n return cookies;\n }\n else {\n return {};\n }\n}\nfunction readCookie(value, options = {}) {\n const cleanValue = cleanupCookieValue(value);\n if (!options.doNotParse) {\n try {\n return JSON.parse(cleanValue);\n }\n catch (e) {\n // At least we tried\n }\n }\n // Ignore clean value if we failed the deserialization\n // It is not relevant anymore to trim those values\n return value;\n}\nfunction cleanupCookieValue(value) {\n // express prepend j: before serializing a cookie\n if (value && value[0] === 'j' && value[1] === ':') {\n return value.substr(2);\n }\n return value;\n}\n\nclass Cookies {\n constructor(cookies, defaultSetOptions = {}) {\n this.changeListeners = [];\n this.HAS_DOCUMENT_COOKIE = false;\n this.update = () => {\n if (!this.HAS_DOCUMENT_COOKIE) {\n return;\n }\n const previousCookies = this.cookies;\n this.cookies = distExports.parse(document.cookie);\n this._checkChanges(previousCookies);\n };\n const domCookies = typeof document === 'undefined' ? '' : document.cookie;\n this.cookies = parseCookies(cookies || domCookies);\n this.defaultSetOptions = defaultSetOptions;\n this.HAS_DOCUMENT_COOKIE = hasDocumentCookie();\n }\n _emitChange(params) {\n for (let i = 0; i < this.changeListeners.length; ++i) {\n this.changeListeners[i](params);\n }\n }\n _checkChanges(previousCookies) {\n const names = new Set(Object.keys(previousCookies).concat(Object.keys(this.cookies)));\n names.forEach((name) => {\n if (previousCookies[name] !== this.cookies[name]) {\n this._emitChange({\n name,\n value: readCookie(this.cookies[name]),\n });\n }\n });\n }\n _startPolling() {\n this.pollingInterval = setInterval(this.update, 300);\n }\n _stopPolling() {\n if (this.pollingInterval) {\n clearInterval(this.pollingInterval);\n }\n }\n get(name, options = {}) {\n if (!options.doNotUpdate) {\n this.update();\n }\n return readCookie(this.cookies[name], options);\n }\n getAll(options = {}) {\n if (!options.doNotUpdate) {\n this.update();\n }\n const result = {};\n for (let name in this.cookies) {\n result[name] = readCookie(this.cookies[name], options);\n }\n return result;\n }\n set(name, value, options) {\n if (options) {\n options = Object.assign(Object.assign({}, this.defaultSetOptions), options);\n }\n else {\n options = this.defaultSetOptions;\n }\n const stringValue = typeof value === 'string' ? value : JSON.stringify(value);\n this.cookies = Object.assign(Object.assign({}, this.cookies), { [name]: stringValue });\n if (this.HAS_DOCUMENT_COOKIE) {\n document.cookie = distExports.serialize(name, stringValue, options);\n }\n this._emitChange({ name, value, options });\n }\n remove(name, options) {\n const finalOptions = (options = Object.assign(Object.assign(Object.assign({}, this.defaultSetOptions), options), { expires: new Date(1970, 1, 1, 0, 0, 1), maxAge: 0 }));\n this.cookies = Object.assign({}, this.cookies);\n delete this.cookies[name];\n if (this.HAS_DOCUMENT_COOKIE) {\n document.cookie = distExports.serialize(name, '', finalOptions);\n }\n this._emitChange({ name, value: undefined, options });\n }\n addChangeListener(callback) {\n this.changeListeners.push(callback);\n if (this.HAS_DOCUMENT_COOKIE && this.changeListeners.length === 1) {\n if (typeof window === 'object' && 'cookieStore' in window) {\n window.cookieStore.addEventListener('change', this.update);\n }\n else {\n this._startPolling();\n }\n }\n }\n removeChangeListener(callback) {\n const idx = this.changeListeners.indexOf(callback);\n if (idx >= 0) {\n this.changeListeners.splice(idx, 1);\n }\n if (this.HAS_DOCUMENT_COOKIE && this.changeListeners.length === 0) {\n if (typeof window === 'object' && 'cookieStore' in window) {\n window.cookieStore.removeEventListener('change', this.update);\n }\n else {\n this._stopPolling();\n }\n }\n }\n removeAllChangeListeners() {\n while (this.changeListeners.length > 0) {\n this.removeChangeListener(this.changeListeners[0]);\n }\n }\n}\n\nexport { Cookies as default };\n"],"names":[],"mappings":"AAAA,IAAI,IAAI,GAAG,EAAE;;AAEb,IAAI,eAAe;;AAEnB,SAAS,WAAW,IAAI;AACxB,CAAC,IAAI,eAAe,EAAE,OAAO,IAAI;AACjC,CAAC,eAAe,GAAG,CAAC;AACpB,CAAC,MAAM,CAAC,cAAc,CAAC,IAAI,EAAE,YAAY,EAAE,EAAE,KAAK,EAAE,IAAI,EAAE,CAAC;AAC3D,CAAC,IAAI,CAAC,KAAK,GAAG,KAAK;AACnB,CAAC,IAAI,CAAC,SAAS,GAAG,S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
|
|
4
|
+
return {
|
|
5
|
+
expires: moment().add(1, 'year').toDate(),
|
|
6
|
+
path: '/',
|
|
7
|
+
domain: config?.cookieDomain,
|
|
8
|
+
};
|
|
9
|
+
};
|
|
10
|
+
|
|
11
|
+
export { getCookieOptions };
|
|
12
|
+
//# sourceMappingURL=cookies.utils.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"cookies.utils.js","sources":["../../../../src/shared/cookies/cookies.utils.ts"],"sourcesContent":["import { Config } from '../../config/config.types';\nimport moment from 'moment';\n\nexport const getCookieOptions = (config: Config | undefined) => {\n return {\n expires: moment().add(1, 'year').toDate(),\n path: '/',\n domain: config?.cookieDomain,\n };\n};\n"],"names":[],"mappings":";;AAGO,MAAM,gBAAgB,GAAG,CAAC,MAA0B,KAAI;IAC7D,OAAO;AACL,QAAA,OAAO,EAAE,MAAM,EAAE,CAAC,GAAG,CAAC,CAAC,EAAE,MAAM,CAAC,CAAC,MAAM,EAAE;AACzC,QAAA,IAAI,EAAE,GAAG;QACT,MAAM,EAAE,MAAM,EAAE,YAAY;KAC7B;AACH;;;;"}
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"index.js","sources":["../../../../src/shared/cookies/index.ts"],"sourcesContent":["import Cookies from 'universal-cookie';\nexport const universalCookies = new Cookies();\n\n\n"],"names":[],"mappings":";;AACO,MAAM,gBAAgB,GAAG,IAAI,OAAO;;;;"}
|
|
@@ -0,0 +1,11 @@
|
|
|
1
|
+
import { DividerProps, ListItemProps, ListItemTextProps, ListProps } from '@mui/material';
|
|
2
|
+
import React from 'react';
|
|
3
|
+
export interface PanelFooterProps {
|
|
4
|
+
dividerProps?: DividerProps;
|
|
5
|
+
listProps?: ListProps;
|
|
6
|
+
listItemProps?: ListItemProps & {
|
|
7
|
+
href?: string;
|
|
8
|
+
};
|
|
9
|
+
listItemTextProps?: ListItemTextProps;
|
|
10
|
+
}
|
|
11
|
+
export declare const PanelFooter: React.FC<PanelFooterProps>;
|
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
import React from 'react';
|
|
2
2
|
import { BoxProps } from '@mui/material';
|
|
3
3
|
export interface PanelHeaderProps {
|
|
4
|
-
containerProps
|
|
4
|
+
containerProps?: BoxProps;
|
|
5
5
|
imageProps?: React.DetailedHTMLProps<React.ImgHTMLAttributes<HTMLImageElement>, HTMLImageElement>;
|
|
6
6
|
}
|
|
7
7
|
export declare const PanelHeader: React.FC<PanelHeaderProps>;
|
|
@@ -1,3 +1,5 @@
|
|
|
1
1
|
import { PanelStoreAction } from './panel.types';
|
|
2
|
+
import { Config } from '../../config/config.types';
|
|
2
3
|
export declare const panelStoreAction: (data: PanelStoreAction) => void;
|
|
3
4
|
export declare const handlePanelClick: (isOpen: boolean) => void;
|
|
5
|
+
export declare const handleLogout: (config: Config | undefined) => void;
|
package/dist/index.d.ts
CHANGED
|
@@ -4,6 +4,7 @@ import * as _cobuildlab_react_simple_state from '@cobuildlab/react-simple-state'
|
|
|
4
4
|
|
|
5
5
|
interface PanelProps extends DrawerProps {
|
|
6
6
|
children?: React.ReactNode;
|
|
7
|
+
footer?: React.ReactNode;
|
|
7
8
|
size?: number;
|
|
8
9
|
}
|
|
9
10
|
declare const Panel: React.FC<PanelProps>;
|
|
@@ -24,14 +25,14 @@ interface PanelButtonProps extends ButtonProps {
|
|
|
24
25
|
declare const PanelButton: FC<PanelButtonProps>;
|
|
25
26
|
|
|
26
27
|
interface PanelHeaderProps {
|
|
27
|
-
containerProps
|
|
28
|
+
containerProps?: BoxProps;
|
|
28
29
|
imageProps?: React.DetailedHTMLProps<React.ImgHTMLAttributes<HTMLImageElement>, HTMLImageElement>;
|
|
29
30
|
}
|
|
30
31
|
declare const PanelHeader: React.FC<PanelHeaderProps>;
|
|
31
32
|
|
|
32
33
|
interface PanelItemProps {
|
|
33
34
|
listItemProps?: ListItemProps & {
|
|
34
|
-
href
|
|
35
|
+
href?: string;
|
|
35
36
|
};
|
|
36
37
|
listItemTextProps?: ListItemTextProps;
|
|
37
38
|
}
|
|
@@ -61,20 +62,22 @@ declare const panelStore: _cobuildlab_react_simple_state.Store<{
|
|
|
61
62
|
isOpen: boolean;
|
|
62
63
|
}>;
|
|
63
64
|
|
|
64
|
-
declare const panelStoreAction: (data: PanelStoreAction) => void;
|
|
65
|
-
declare const handlePanelClick: (isOpen: boolean) => void;
|
|
66
|
-
|
|
67
65
|
interface Config {
|
|
68
66
|
uri?: string;
|
|
69
67
|
urlPortal?: string;
|
|
70
68
|
cookieTokenName?: string;
|
|
69
|
+
cookieDomain?: string;
|
|
71
70
|
}
|
|
72
71
|
|
|
72
|
+
declare const panelStoreAction: (data: PanelStoreAction) => void;
|
|
73
|
+
declare const handlePanelClick: (isOpen: boolean) => void;
|
|
74
|
+
declare const handleLogout: (config: Config | undefined) => void;
|
|
75
|
+
|
|
73
76
|
type SessionProviderProps = {
|
|
74
77
|
children: React.ReactNode;
|
|
75
78
|
config: Config;
|
|
76
79
|
};
|
|
77
80
|
declare const SessionProvider: React.FC<SessionProviderProps>;
|
|
78
81
|
|
|
79
|
-
export { Panel, PanelAvatar, PanelButton, PanelDivider, PanelHeader, PanelItem, PanelListItems, SessionProvider, handlePanelClick, panelStore, panelStoreAction };
|
|
82
|
+
export { Panel, PanelAvatar, PanelButton, PanelDivider, PanelHeader, PanelItem, PanelListItems, SessionProvider, handleLogout, handlePanelClick, panelStore, panelStoreAction };
|
|
80
83
|
export type { PanelAvatarProps, PanelButtonProps, PanelDividerProps, PanelHeaderProps, PanelItemProps, PanelListRoute, PanelProps, PanelStoreAction };
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "react-easy-wall",
|
|
3
|
-
"version": "1.0.
|
|
3
|
+
"version": "1.0.16",
|
|
4
4
|
"main": "./dist/cjs/index.js",
|
|
5
5
|
"module": "./dist/esm/index.js",
|
|
6
6
|
"types": "./dist/index.d.ts",
|
|
@@ -70,6 +70,8 @@
|
|
|
70
70
|
"@mui/material": "^7.3.8",
|
|
71
71
|
"@mui/material-nextjs": "^7.3.8",
|
|
72
72
|
"graphql": "^16.13.0",
|
|
73
|
-
"
|
|
73
|
+
"moment": "^2.30.1",
|
|
74
|
+
"rollup-plugin-preserve-directives": "^0.4.0",
|
|
75
|
+
"universal-cookie": "^8.0.1"
|
|
74
76
|
}
|
|
75
77
|
}
|