@unicom-cloud/utils 0.1.28 → 0.1.30
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/case-name/index.js +1 -1
- package/caseName.js +1 -1
- package/class-name/index.js +1 -1
- package/className.js +1 -1
- package/clipboard-copy/index.js +1 -1
- package/clipboardCopy.js +1 -1
- package/constant/address.js +1 -1
- package/constant/chineseCharacters.js +1 -1
- package/constant/constellations.js +1 -1
- package/constant/domain.js +1 -1
- package/constant/emoji.js +1 -1
- package/constant/identity.js +1 -1
- package/constant/index.js +7 -5
- package/constant/keyboardCode.js +1 -1
- package/constant/licensePlate.js +1 -1
- package/constant/name.js +1 -1
- package/constant/platform.js +1 -1
- package/constant/protocol.js +1 -1
- package/constant/string.js +5 -0
- package/constant/ui.js +1 -1
- package/constant.js +15 -13
- package/content-disposition/index.js +1 -1
- package/contentDisposition.js +1 -1
- package/cookie/LICENSE +21 -0
- package/cookie/index.js +3 -32
- package/{js-cookie → cookie}/src/api.js +1 -1
- package/{js-cookie → cookie}/src/assign.js +1 -1
- package/{js-cookie → cookie}/src/converter.js +1 -1
- package/cookie.js +3 -6
- package/date/convertTime.js +1 -1
- package/date/convertToDuration.js +1 -1
- package/date/index.js +1 -1
- package/date.js +1 -1
- package/decimal/decimal.js +1 -1
- package/decimal/index.js +1 -1
- package/decimal.js +1 -1
- package/dom-helpers/activeElement.js +1 -1
- package/dom-helpers/addClass.js +1 -1
- package/dom-helpers/addEventListener.js +1 -1
- package/dom-helpers/animate.js +1 -1
- package/dom-helpers/animationFrame.js +1 -1
- package/dom-helpers/attribute.js +1 -1
- package/dom-helpers/camelize.js +1 -1
- package/dom-helpers/camelizeStyle.js +1 -1
- package/dom-helpers/canUseDOM.js +1 -1
- package/dom-helpers/childElements.js +1 -1
- package/dom-helpers/childNodes.js +1 -1
- package/dom-helpers/clear.js +1 -1
- package/dom-helpers/closest.js +1 -1
- package/dom-helpers/collectElements.js +1 -1
- package/dom-helpers/collectSiblings.js +1 -1
- package/dom-helpers/contains.js +1 -1
- package/dom-helpers/css.js +1 -1
- package/dom-helpers/filterEventHandler.js +1 -1
- package/dom-helpers/getComputedStyle.js +1 -1
- package/dom-helpers/getScrollAccessor.js +1 -1
- package/dom-helpers/hasClass.js +1 -1
- package/dom-helpers/height.js +1 -1
- package/dom-helpers/hyphenate.js +1 -1
- package/dom-helpers/hyphenateStyle.js +1 -1
- package/dom-helpers/index.js +1 -1
- package/dom-helpers/insertAfter.js +1 -1
- package/dom-helpers/isDocument.js +1 -1
- package/dom-helpers/isInput.js +1 -1
- package/dom-helpers/isTransform.js +1 -1
- package/dom-helpers/isVisible.js +1 -1
- package/dom-helpers/isWindow.js +1 -1
- package/dom-helpers/listen.js +1 -1
- package/dom-helpers/matches.js +1 -1
- package/dom-helpers/nextUntil.js +1 -1
- package/dom-helpers/offset.js +1 -1
- package/dom-helpers/offsetParent.js +1 -1
- package/dom-helpers/ownerDocument.js +1 -1
- package/dom-helpers/ownerWindow.js +1 -1
- package/dom-helpers/parents.js +1 -1
- package/dom-helpers/position.js +1 -1
- package/dom-helpers/prepend.js +1 -1
- package/dom-helpers/querySelectorAll.js +1 -1
- package/dom-helpers/reflow.js +1 -1
- package/dom-helpers/remove.js +1 -1
- package/dom-helpers/removeClass.js +1 -1
- package/dom-helpers/removeEventListener.js +1 -1
- package/dom-helpers/scrollLeft.js +1 -1
- package/dom-helpers/scrollParent.js +1 -1
- package/dom-helpers/scrollTo.js +1 -1
- package/dom-helpers/scrollTop.js +1 -1
- package/dom-helpers/scrollbarSize.js +1 -1
- package/dom-helpers/siblings.js +1 -1
- package/dom-helpers/text.js +1 -1
- package/dom-helpers/toggleClass.js +1 -1
- package/dom-helpers/transitionEnd.js +1 -1
- package/dom-helpers/triggerEvent.js +1 -1
- package/dom-helpers/types.js +1 -1
- package/dom-helpers/width.js +1 -1
- package/domHelpers.js +1 -1
- package/emitter/index.js +1 -1
- package/emitter/src/index.js +1 -1
- package/emitter.js +1 -1
- package/file/fileToURL.js +1 -1
- package/file/index.js +1 -1
- package/file/saveAs.js +40 -28
- package/file.js +1 -1
- package/idb/index.js +1 -1
- package/idb.js +1 -1
- package/index.js +1 -1
- package/invariant/index.js +1 -1
- package/invariant.js +1 -1
- package/is/index.js +135 -128
- package/is.js +25 -24
- package/lunar/index.js +1 -1
- package/lunar/lib/Holiday.js +1 -1
- package/lunar/lib/HolidayUtil.js +1 -1
- package/lunar/lib/I18n.js +1 -1
- package/lunar/lib/JieQi.js +1 -1
- package/lunar/lib/Lunar.js +1 -1
- package/lunar/lib/LunarMonth.js +1 -1
- package/lunar/lib/LunarTime.js +1 -1
- package/lunar/lib/LunarUtil.js +1 -1
- package/lunar/lib/LunarYear.js +1 -1
- package/lunar/lib/ShouXingUtil.js +1 -1
- package/lunar/lib/Solar.js +1 -1
- package/lunar/lib/SolarHalfYear.js +1 -1
- package/lunar/lib/SolarMonth.js +1 -1
- package/lunar/lib/SolarSeason.js +1 -1
- package/lunar/lib/SolarUtil.js +1 -1
- package/lunar/lib/SolarWeek.js +1 -1
- package/lunar/lib/SolarYear.js +1 -1
- package/lunar/lib/index.js +1 -1
- package/lunar.js +1 -1
- package/math/index.js +1 -1
- package/math.js +1 -1
- package/md5/index.js +1 -1
- package/md5.js +1 -1
- package/mock/MockWebSocket.js +23 -22
- package/mock/MockXMLHttpRequest.js +1 -1
- package/mock/index.js +1 -1
- package/mock.js +1 -1
- package/normalize-wheel/ExecutionEnvironment.js +1 -1
- package/normalize-wheel/UserAgent_DEPRECATED.js +1 -1
- package/normalize-wheel/index.js +1 -1
- package/normalize-wheel/isEventSupported.js +1 -1
- package/normalizeWheel.js +1 -1
- package/number-to-chinese/index.js +1 -1
- package/numberToChinese.js +1 -1
- package/nzh/cn.js +1 -1
- package/nzh/hk.js +1 -1
- package/nzh/index.js +1 -1
- package/nzh/nzh.js +1 -1
- package/nzh/src/autoGet.js +1 -1
- package/nzh/src/index.js +1 -1
- package/nzh/src/langs/cn_b.js +1 -1
- package/nzh/src/langs/cn_s.js +1 -1
- package/nzh/src/langs/hk_b.js +1 -1
- package/nzh/src/langs/hk_s.js +1 -1
- package/nzh/src/utils.js +1 -1
- package/nzh.js +1 -1
- package/object-keys-sort/index.js +1 -1
- package/object-prototype-to-string-call/index.js +6 -4
- package/objectKeysSort.js +1 -1
- package/objectPrototypeToStringCall.js +4 -3
- package/package.json +1 -1
- package/pinyin/index.js +1 -1
- package/pinyin/simplified.js +1 -1
- package/pinyin/src/core.js +1 -1
- package/pinyin/src/simplified.js +1 -1
- package/pinyin/src/simplified_dict.js +1 -1
- package/pinyin/src/traditional.js +1 -1
- package/pinyin/src/traditional_dict.js +1 -1
- package/pinyin/traditional.js +1 -1
- package/pinyin.js +1 -1
- package/query-string/base.js +1 -1
- package/query-string/index.js +1 -1
- package/query-string/splitOnFirst.js +1 -1
- package/queryString.js +1 -1
- package/random/address.js +1 -1
- package/random/constellation.js +1 -1
- package/random/image.js +1 -1
- package/random/index.js +1 -1
- package/random/licensePlate.js +1 -1
- package/random/name.js +1 -1
- package/random/number.js +1 -1
- package/random/text.js +1 -1
- package/random/time.js +1 -1
- package/random/web.js +1 -1
- package/random.js +1 -1
- package/screenfull/index.js +1 -1
- package/screenfull.js +1 -1
- package/sleep/index.js +1 -1
- package/sleep.js +1 -1
- package/snapdom/index.js +1 -1
- package/snapdom/src/api/preCache.js +1 -1
- package/snapdom/src/api/snapdom.js +1 -1
- package/snapdom/src/core/cache.js +1 -1
- package/snapdom/src/core/capture.js +1 -1
- package/snapdom/src/core/clone.js +1 -1
- package/snapdom/src/core/context.js +1 -1
- package/snapdom/src/core/plugins.js +1 -1
- package/snapdom/src/core/prepare.js +1 -1
- package/snapdom/src/exporters/download.js +1 -1
- package/snapdom/src/exporters/toBlob.js +1 -1
- package/snapdom/src/exporters/toCanvas.js +1 -1
- package/snapdom/src/exporters/toImg.js +1 -1
- package/snapdom/src/modules/CSSVar.js +1 -1
- package/snapdom/src/modules/background.js +1 -1
- package/snapdom/src/modules/changeCSS.js +1 -1
- package/snapdom/src/modules/counter.js +1 -1
- package/snapdom/src/modules/fonts.js +1 -1
- package/snapdom/src/modules/iconFonts.js +1 -1
- package/snapdom/src/modules/images.js +1 -1
- package/snapdom/src/modules/lineClamp.js +1 -1
- package/snapdom/src/modules/pseudo.js +1 -1
- package/snapdom/src/modules/rasterize.js +1 -1
- package/snapdom/src/modules/snapFetch.js +1 -1
- package/snapdom/src/modules/styles.js +1 -1
- package/snapdom/src/modules/svgDefs.js +1 -1
- package/snapdom/src/utils/browser.js +1 -1
- package/snapdom/src/utils/css.js +1 -1
- package/snapdom/src/utils/helpers.js +1 -1
- package/snapdom/src/utils/image.js +1 -1
- package/snapdom.js +1 -1
- package/string/index.js +12 -4
- package/string.js +8 -3
- package/tinycolor/LICENSE +18 -0
- package/tinycolor/index.js +1 -1
- package/tinycolor/src/conversion.js +1 -1
- package/tinycolor/src/css-color-names.js +1 -1
- package/tinycolor/src/format-input.js +1 -1
- package/tinycolor/src/from-ratio.js +1 -1
- package/tinycolor/src/index.js +1 -1
- package/tinycolor/src/random.js +1 -1
- package/tinycolor/src/readability.js +1 -1
- package/tinycolor/src/to-ms-filter.js +1 -1
- package/tinycolor/src/utils.js +1 -1
- package/tinycolor.js +1 -1
- package/tree/index.js +1 -1
- package/tree/search/index.js +1 -1
- package/tree.js +1 -1
- package/tween/index.js +1 -1
- package/tween/src/easing.js +1 -1
- package/tween/src/tween.js +1 -1
- package/tween.js +1 -1
- package/types/constant/index.d.ts +1 -0
- package/types/constant/string.d.ts +1 -0
- package/types/cookie/index.d.ts +1 -4
- package/types/file/saveAs.d.ts +1 -1
- package/types/is/index.d.ts +9 -8
- package/types/object-prototype-to-string-call/index.d.ts +1 -1
- package/types/string/index.d.ts +1 -0
- package/ui-color/compareColorByRange.js +1 -1
- package/ui-color/index.js +1 -1
- package/uiColor.js +1 -1
- package/url-toolkit/LICENSE +190 -0
- package/url-toolkit/index.js +1 -1
- package/url-toolkit/src/url-toolkit.js +2 -2
- package/urlToolkit.js +1 -1
- package/validate/index.js +1 -1
- package/validate/src/index.js +1 -1
- package/validate/src/locale/en-US.js +1 -1
- package/validate/src/locale/zh-CN.js +1 -1
- package/validate/src/message.js +1 -1
- package/validate/src/rules/array.js +1 -1
- package/validate/src/rules/base.js +1 -1
- package/validate/src/rules/boolean.js +1 -1
- package/validate/src/rules/custom.js +1 -1
- package/validate/src/rules/number.js +1 -1
- package/validate/src/rules/object.js +1 -1
- package/validate/src/rules/string.js +1 -1
- package/validate/src/rules/type.js +1 -1
- package/validate/src/utils.js +1 -1
- package/validate.js +1 -1
- package/version/index.js +1 -1
- package/version.js +1 -1
- package/xlsx/index.js +1 -1
- package/xlsx/xlsx.js +1764 -1767
- package/xlsx.js +1 -1
- package/cookie/src/index.js +0 -117
- package/js-cookie/index.js +0 -5
- package/jsCookie.js +0 -5
- package/types/cookie/src/index.d.ts +0 -114
- package/types/js-cookie/index.d.ts +0 -1
- /package/{js-cookie → cookie}/index.d.ts +0 -0
- /package/types/{js-cookie → cookie}/src/api.d.mts +0 -0
- /package/types/{js-cookie → cookie}/src/assign.d.mts +0 -0
- /package/types/{js-cookie → cookie}/src/converter.d.mts +0 -0
package/xlsx.js
CHANGED
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
/* 2025-11-
|
|
1
|
+
/* 2025-11-19 09:08:12 */
|
|
2
2
|
import { CFB as r, SSF as t, default as l, parse_xlscfb as s, parse_zip as a, read as F, readFile as w, readFile as S, set_cptable as c, set_fs as d, stream as p, utils as f, version as n, write as X, writeFile as _, writeFileAsync as o, writeFile as y, writeFileXLSX as b, writeXLSX as m } from "./xlsx/xlsx.js";
|
|
3
3
|
export {
|
|
4
4
|
r as CFB,
|
package/cookie/src/index.js
DELETED
|
@@ -1,117 +0,0 @@
|
|
|
1
|
-
/* 2025-11-14 09:11:12 */
|
|
2
|
-
const w = /^[\u0021-\u003A\u003C\u003E-\u007E]+$/, g = /^[\u0021-\u003A\u003C-\u007E]*$/, p = /^([.]?[a-z0-9]([a-z0-9-]{0,61}[a-z0-9])?)([.][a-z0-9]([a-z0-9-]{0,61}[a-z0-9])?)*$/i, S = /^[\u0020-\u003A\u003D-\u007E]*$/, E = Object.prototype.toString, v = /* @__PURE__ */ (() => {
|
|
3
|
-
const t = function() {
|
|
4
|
-
};
|
|
5
|
-
return t.prototype = /* @__PURE__ */ Object.create(null), t;
|
|
6
|
-
})();
|
|
7
|
-
function k(t, i) {
|
|
8
|
-
const e = new v(), a = t.length;
|
|
9
|
-
if (a < 2) return e;
|
|
10
|
-
const c = i?.decode || b;
|
|
11
|
-
let r = 0;
|
|
12
|
-
do {
|
|
13
|
-
const n = t.indexOf("=", r);
|
|
14
|
-
if (n === -1) break;
|
|
15
|
-
const u = t.indexOf(";", r), o = u === -1 ? a : u;
|
|
16
|
-
if (n > o) {
|
|
17
|
-
r = t.lastIndexOf(";", n - 1) + 1;
|
|
18
|
-
continue;
|
|
19
|
-
}
|
|
20
|
-
const d = s(t, r, n), x = m(t, n, d), l = t.slice(d, x);
|
|
21
|
-
if (e[l] === void 0) {
|
|
22
|
-
const f = s(t, n + 1, o), h = m(t, o, f), y = c(t.slice(f, h));
|
|
23
|
-
e[l] = y;
|
|
24
|
-
}
|
|
25
|
-
r = o + 1;
|
|
26
|
-
} while (r < a);
|
|
27
|
-
return e;
|
|
28
|
-
}
|
|
29
|
-
function s(t, i, e) {
|
|
30
|
-
do {
|
|
31
|
-
const a = t.charCodeAt(i);
|
|
32
|
-
if (a !== 32 && a !== 9) return i;
|
|
33
|
-
} while (++i < e);
|
|
34
|
-
return e;
|
|
35
|
-
}
|
|
36
|
-
function m(t, i, e) {
|
|
37
|
-
for (; i > e; ) {
|
|
38
|
-
const a = t.charCodeAt(--i);
|
|
39
|
-
if (a !== 32 && a !== 9) return i + 1;
|
|
40
|
-
}
|
|
41
|
-
return e;
|
|
42
|
-
}
|
|
43
|
-
function $(t, i, e) {
|
|
44
|
-
const a = e?.encode || encodeURIComponent;
|
|
45
|
-
if (!w.test(t))
|
|
46
|
-
throw new TypeError(`argument name is invalid: ${t}`);
|
|
47
|
-
const c = a(i);
|
|
48
|
-
if (!g.test(c))
|
|
49
|
-
throw new TypeError(`argument val is invalid: ${i}`);
|
|
50
|
-
let r = t + "=" + c;
|
|
51
|
-
if (!e) return r;
|
|
52
|
-
if (e.maxAge !== void 0) {
|
|
53
|
-
if (!Number.isInteger(e.maxAge))
|
|
54
|
-
throw new TypeError(`option maxAge is invalid: ${e.maxAge}`);
|
|
55
|
-
r += "; Max-Age=" + e.maxAge;
|
|
56
|
-
}
|
|
57
|
-
if (e.domain) {
|
|
58
|
-
if (!p.test(e.domain))
|
|
59
|
-
throw new TypeError(`option domain is invalid: ${e.domain}`);
|
|
60
|
-
r += "; Domain=" + e.domain;
|
|
61
|
-
}
|
|
62
|
-
if (e.path) {
|
|
63
|
-
if (!S.test(e.path))
|
|
64
|
-
throw new TypeError(`option path is invalid: ${e.path}`);
|
|
65
|
-
r += "; Path=" + e.path;
|
|
66
|
-
}
|
|
67
|
-
if (e.expires) {
|
|
68
|
-
if (!I(e.expires) || !Number.isFinite(e.expires.valueOf()))
|
|
69
|
-
throw new TypeError(`option expires is invalid: ${e.expires}`);
|
|
70
|
-
r += "; Expires=" + e.expires.toUTCString();
|
|
71
|
-
}
|
|
72
|
-
if (e.httpOnly && (r += "; HttpOnly"), e.secure && (r += "; Secure"), e.partitioned && (r += "; Partitioned"), e.priority)
|
|
73
|
-
switch (typeof e.priority == "string" ? e.priority.toLowerCase() : void 0) {
|
|
74
|
-
case "low":
|
|
75
|
-
r += "; Priority=Low";
|
|
76
|
-
break;
|
|
77
|
-
case "medium":
|
|
78
|
-
r += "; Priority=Medium";
|
|
79
|
-
break;
|
|
80
|
-
case "high":
|
|
81
|
-
r += "; Priority=High";
|
|
82
|
-
break;
|
|
83
|
-
default:
|
|
84
|
-
throw new TypeError(`option priority is invalid: ${e.priority}`);
|
|
85
|
-
}
|
|
86
|
-
if (e.sameSite)
|
|
87
|
-
switch (typeof e.sameSite == "string" ? e.sameSite.toLowerCase() : e.sameSite) {
|
|
88
|
-
case !0:
|
|
89
|
-
case "strict":
|
|
90
|
-
r += "; SameSite=Strict";
|
|
91
|
-
break;
|
|
92
|
-
case "lax":
|
|
93
|
-
r += "; SameSite=Lax";
|
|
94
|
-
break;
|
|
95
|
-
case "none":
|
|
96
|
-
r += "; SameSite=None";
|
|
97
|
-
break;
|
|
98
|
-
default:
|
|
99
|
-
throw new TypeError(`option sameSite is invalid: ${e.sameSite}`);
|
|
100
|
-
}
|
|
101
|
-
return r;
|
|
102
|
-
}
|
|
103
|
-
function b(t) {
|
|
104
|
-
if (t.indexOf("%") === -1) return t;
|
|
105
|
-
try {
|
|
106
|
-
return decodeURIComponent(t);
|
|
107
|
-
} catch {
|
|
108
|
-
return t;
|
|
109
|
-
}
|
|
110
|
-
}
|
|
111
|
-
function I(t) {
|
|
112
|
-
return E.call(t) === "[object Date]";
|
|
113
|
-
}
|
|
114
|
-
export {
|
|
115
|
-
k as parse,
|
|
116
|
-
$ as serialize
|
|
117
|
-
};
|
package/js-cookie/index.js
DELETED
package/jsCookie.js
DELETED
|
@@ -1,114 +0,0 @@
|
|
|
1
|
-
/**
|
|
2
|
-
* Parse options.
|
|
3
|
-
*/
|
|
4
|
-
export interface ParseOptions {
|
|
5
|
-
/**
|
|
6
|
-
* Specifies a function that will be used to decode a [cookie-value](https://datatracker.ietf.org/doc/html/rfc6265#section-4.1.1).
|
|
7
|
-
* Since the value of a cookie has a limited character set (and must be a simple string), this function can be used to decode
|
|
8
|
-
* a previously-encoded cookie value into a JavaScript string.
|
|
9
|
-
*
|
|
10
|
-
* The default function is the global `decodeURIComponent`, wrapped in a `try..catch`. If an error
|
|
11
|
-
* is thrown it will return the cookie's original value. If you provide your own encode/decode
|
|
12
|
-
* scheme you must ensure errors are appropriately handled.
|
|
13
|
-
*
|
|
14
|
-
* @default decode
|
|
15
|
-
*/
|
|
16
|
-
decode?: (str: string) => string | undefined;
|
|
17
|
-
}
|
|
18
|
-
/**
|
|
19
|
-
* Parse a cookie header.
|
|
20
|
-
*
|
|
21
|
-
* Parse the given cookie header string into an object
|
|
22
|
-
* The object has the various cookies as keys(names) => values
|
|
23
|
-
*/
|
|
24
|
-
export declare function parse(str: string, options?: ParseOptions): Record<string, string | undefined>;
|
|
25
|
-
/**
|
|
26
|
-
* Serialize options.
|
|
27
|
-
*/
|
|
28
|
-
export interface SerializeOptions {
|
|
29
|
-
/**
|
|
30
|
-
* Specifies a function that will be used to encode a [cookie-value](https://datatracker.ietf.org/doc/html/rfc6265#section-4.1.1).
|
|
31
|
-
* Since value of a cookie has a limited character set (and must be a simple string), this function can be used to encode
|
|
32
|
-
* a value into a string suited for a cookie's value, and should mirror `decode` when parsing.
|
|
33
|
-
*
|
|
34
|
-
* @default encodeURIComponent
|
|
35
|
-
*/
|
|
36
|
-
encode?: (str: string) => string;
|
|
37
|
-
/**
|
|
38
|
-
* Specifies the `number` (in seconds) to be the value for the [`Max-Age` `Set-Cookie` attribute](https://tools.ietf.org/html/rfc6265#section-5.2.2).
|
|
39
|
-
*
|
|
40
|
-
* The [cookie storage model specification](https://tools.ietf.org/html/rfc6265#section-5.3) states that if both `expires` and
|
|
41
|
-
* `maxAge` are set, then `maxAge` takes precedence, but it is possible not all clients by obey this,
|
|
42
|
-
* so if both are set, they should point to the same date and time.
|
|
43
|
-
*/
|
|
44
|
-
maxAge?: number;
|
|
45
|
-
/**
|
|
46
|
-
* Specifies the `Date` object to be the value for the [`Expires` `Set-Cookie` attribute](https://tools.ietf.org/html/rfc6265#section-5.2.1).
|
|
47
|
-
* When no expiration is set clients consider this a "non-persistent cookie" and delete it the current session is over.
|
|
48
|
-
*
|
|
49
|
-
* The [cookie storage model specification](https://tools.ietf.org/html/rfc6265#section-5.3) states that if both `expires` and
|
|
50
|
-
* `maxAge` are set, then `maxAge` takes precedence, but it is possible not all clients by obey this,
|
|
51
|
-
* so if both are set, they should point to the same date and time.
|
|
52
|
-
*/
|
|
53
|
-
expires?: Date;
|
|
54
|
-
/**
|
|
55
|
-
* Specifies the value for the [`Domain` `Set-Cookie` attribute](https://tools.ietf.org/html/rfc6265#section-5.2.3).
|
|
56
|
-
* When no domain is set clients consider the cookie to apply to the current domain only.
|
|
57
|
-
*/
|
|
58
|
-
domain?: string;
|
|
59
|
-
/**
|
|
60
|
-
* Specifies the value for the [`Path` `Set-Cookie` attribute](https://tools.ietf.org/html/rfc6265#section-5.2.4).
|
|
61
|
-
* When no path is set, the path is considered the ["default path"](https://tools.ietf.org/html/rfc6265#section-5.1.4).
|
|
62
|
-
*/
|
|
63
|
-
path?: string;
|
|
64
|
-
/**
|
|
65
|
-
* Enables the [`HttpOnly` `Set-Cookie` attribute](https://tools.ietf.org/html/rfc6265#section-5.2.6).
|
|
66
|
-
* When enabled, clients will not allow client-side JavaScript to see the cookie in `document.cookie`.
|
|
67
|
-
*/
|
|
68
|
-
httpOnly?: boolean;
|
|
69
|
-
/**
|
|
70
|
-
* Enables the [`Secure` `Set-Cookie` attribute](https://tools.ietf.org/html/rfc6265#section-5.2.5).
|
|
71
|
-
* When enabled, clients will only send the cookie back if the browser has a HTTPS connection.
|
|
72
|
-
*/
|
|
73
|
-
secure?: boolean;
|
|
74
|
-
/**
|
|
75
|
-
* Enables the [`Partitioned` `Set-Cookie` attribute](https://tools.ietf.org/html/draft-cutler-httpbis-partitioned-cookies/).
|
|
76
|
-
* When enabled, clients will only send the cookie back when the current domain _and_ top-level domain matches.
|
|
77
|
-
*
|
|
78
|
-
* This is an attribute that has not yet been fully standardized, and may change in the future.
|
|
79
|
-
* This also means clients may ignore this attribute until they understand it. More information
|
|
80
|
-
* about can be found in [the proposal](https://github.com/privacycg/CHIPS).
|
|
81
|
-
*/
|
|
82
|
-
partitioned?: boolean;
|
|
83
|
-
/**
|
|
84
|
-
* Specifies the value for the [`Priority` `Set-Cookie` attribute](https://tools.ietf.org/html/draft-west-cookie-priority-00#section-4.1).
|
|
85
|
-
*
|
|
86
|
-
* - `'low'` will set the `Priority` attribute to `Low`.
|
|
87
|
-
* - `'medium'` will set the `Priority` attribute to `Medium`, the default priority when not set.
|
|
88
|
-
* - `'high'` will set the `Priority` attribute to `High`.
|
|
89
|
-
*
|
|
90
|
-
* More information about priority levels can be found in [the specification](https://tools.ietf.org/html/draft-west-cookie-priority-00#section-4.1).
|
|
91
|
-
*/
|
|
92
|
-
priority?: 'low' | 'medium' | 'high';
|
|
93
|
-
/**
|
|
94
|
-
* Specifies the value for the [`SameSite` `Set-Cookie` attribute](https://tools.ietf.org/html/draft-ietf-httpbis-rfc6265bis-09#section-5.4.7).
|
|
95
|
-
*
|
|
96
|
-
* - `true` will set the `SameSite` attribute to `Strict` for strict same site enforcement.
|
|
97
|
-
* - `'lax'` will set the `SameSite` attribute to `Lax` for lax same site enforcement.
|
|
98
|
-
* - `'none'` will set the `SameSite` attribute to `None` for an explicit cross-site cookie.
|
|
99
|
-
* - `'strict'` will set the `SameSite` attribute to `Strict` for strict same site enforcement.
|
|
100
|
-
*
|
|
101
|
-
* More information about enforcement levels can be found in [the specification](https://tools.ietf.org/html/draft-ietf-httpbis-rfc6265bis-09#section-5.4.7).
|
|
102
|
-
*/
|
|
103
|
-
sameSite?: boolean | 'lax' | 'strict' | 'none';
|
|
104
|
-
}
|
|
105
|
-
/**
|
|
106
|
-
* Serialize data into a cookie header.
|
|
107
|
-
*
|
|
108
|
-
* Serialize a name value pair into a cookie string suitable for
|
|
109
|
-
* http headers. An optional options object specifies cookie parameters.
|
|
110
|
-
*
|
|
111
|
-
* serialize('foo', 'bar', { httpOnly: true })
|
|
112
|
-
* => "foo=bar; httpOnly"
|
|
113
|
-
*/
|
|
114
|
-
export declare function serialize(name: string, val: string, options?: SerializeOptions): string;
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
export { default } from "./src/api.mjs";
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|