fix(products): fix breadcrumbs and product filtering (backport from main)
Some checks failed
Build & Deploy / 🔍 Prepare (push) Successful in 20s
Build & Deploy / 🧪 QA (push) Failing after 34s
Build & Deploy / 🏗️ Build (push) Has started running
Build & Deploy / 🚀 Deploy (push) Has been cancelled
Build & Deploy / 🧪 Smoke Test (push) Has been cancelled
Build & Deploy / ⚡ Lighthouse (push) Has been cancelled
Build & Deploy / 🔔 Notify (push) Has been cancelled

This commit is contained in:
2026-02-24 16:04:21 +01:00
parent 915eb61613
commit 5397309103
43805 changed files with 4324295 additions and 3 deletions

View File

@@ -0,0 +1 @@
{"version":3,"file":"beaker.js","sources":["../../../src/icons/beaker.ts"],"sourcesContent":["import createLucideIcon from '../createLucideIcon';\n\n/**\n * @component @name Beaker\n * @description Lucide SVG icon component, renders SVG Element with children.\n *\n * @preview ![img](data:image/svg+xml;base64,PHN2ZyAgeG1sbnM9Imh0dHA6Ly93d3cudzMub3JnLzIwMDAvc3ZnIgogIHdpZHRoPSIyNCIKICBoZWlnaHQ9IjI0IgogIHZpZXdCb3g9IjAgMCAyNCAyNCIKICBmaWxsPSJub25lIgogIHN0cm9rZT0iIzAwMCIgc3R5bGU9ImJhY2tncm91bmQtY29sb3I6ICNmZmY7IGJvcmRlci1yYWRpdXM6IDJweCIKICBzdHJva2Utd2lkdGg9IjIiCiAgc3Ryb2tlLWxpbmVjYXA9InJvdW5kIgogIHN0cm9rZS1saW5lam9pbj0icm91bmQiCj4KICA8cGF0aCBkPSJNNC41IDNoMTUiIC8+CiAgPHBhdGggZD0iTTYgM3YxNmEyIDIgMCAwIDAgMiAyaDhhMiAyIDAgMCAwIDItMlYzIiAvPgogIDxwYXRoIGQ9Ik02IDE0aDEyIiAvPgo8L3N2Zz4K) - https://lucide.dev/icons/beaker\n * @see https://lucide.dev/guide/packages/lucide-react - Documentation\n *\n * @param {Object} props - Lucide icons props and any valid SVG attribute\n * @returns {JSX.Element} JSX Element\n *\n */\nconst Beaker = createLucideIcon('Beaker', [\n ['path', { d: 'M4.5 3h15', key: 'c7n0jr' }],\n ['path', { d: 'M6 3v16a2 2 0 0 0 2 2h8a2 2 0 0 0 2-2V3', key: 'm1uhx7' }],\n ['path', { d: 'M6 14h12', key: '4cwo0f' }],\n]);\n\nexport default Beaker;\n"],"names":[],"mappings":";;;;;;;;;AAaM,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAS,iBAAiB,QAAU,CAAA,CAAA,CAAA;AAAA,CAAA,CACxC,CAAC,CAAA,CAAA,CAAA,CAAA,CAAA,CAAQ,CAAA,CAAA,CAAA,CAAE,GAAG,CAAa,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAK,UAAU,CAAA,CAAA;AAAA,CAAA,CAC1C,CAAC,CAAA,CAAA,CAAA,CAAA,CAAA,CAAQ,CAAA,CAAA,CAAA,CAAE,GAAG,CAA2C,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAK,UAAU,CAAA,CAAA;AAAA,CAAA,CACxE,CAAC,CAAA,CAAA,CAAA,CAAA,CAAA,CAAQ,CAAA,CAAA,CAAA,CAAE,GAAG,CAAY,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAK,UAAU,CAAA;AAC3C,CAAC,CAAA,CAAA;;"}

View File

@@ -0,0 +1,31 @@
/**
* @license lucide-react v0.441.0 - ISC
*
* This source code is licensed under the ISC license.
* See the LICENSE file in the root directory of this source tree.
*/
import createLucideIcon from '../createLucideIcon.js';
const Cctv = createLucideIcon("Cctv", [
[
"path",
{
d: "M16.75 12h3.632a1 1 0 0 1 .894 1.447l-2.034 4.069a1 1 0 0 1-1.708.134l-2.124-2.97",
key: "ir91b5"
}
],
[
"path",
{
d: "M17.106 9.053a1 1 0 0 1 .447 1.341l-3.106 6.211a1 1 0 0 1-1.342.447L3.61 12.3a2.92 2.92 0 0 1-1.3-3.91L3.69 5.6a2.92 2.92 0 0 1 3.92-1.3z",
key: "jlp8i1"
}
],
["path", { d: "M2 19h3.76a2 2 0 0 0 1.8-1.1L9 15", key: "19bib8" }],
["path", { d: "M2 21v-4", key: "l40lih" }],
["path", { d: "M7 9h.01", key: "19b3jx" }]
]);
export { Cctv as default };
//# sourceMappingURL=cctv.js.map

View File

@@ -0,0 +1 @@
module.exports={C:{"5":0.03977,"52":0.00568,"59":0.01136,"88":0.00568,"91":0.00568,"103":0.00568,"112":0.00568,"113":0.00568,"115":0.14203,"120":0.00568,"136":0.01136,"137":0.00568,"138":0.00568,"140":0.02272,"141":0.00568,"142":0.00568,"143":0.01704,"144":0.01704,"145":0.38063,"146":0.47152,_:"2 3 4 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 35 36 37 38 39 40 41 42 43 44 45 46 47 48 49 50 51 53 54 55 56 57 58 60 61 62 63 64 65 66 67 68 69 70 71 72 73 74 75 76 77 78 79 80 81 82 83 84 85 86 87 89 90 92 93 94 95 96 97 98 99 100 101 102 104 105 106 107 108 109 110 111 114 116 117 118 119 121 122 123 124 125 126 127 128 129 130 131 132 133 134 135 139 147 148 149 3.5 3.6"},D:{"66":0.03977,"69":0.03977,"79":0.01136,"87":0.00568,"95":0.00568,"97":0.00568,"99":0.01136,"102":0.00568,"103":0.28973,"104":0.27837,"105":0.27837,"106":0.27837,"107":0.27837,"108":0.28405,"109":1.60204,"110":0.27837,"111":0.34654,"112":16.84985,"114":0.00568,"116":0.57946,"117":0.27837,"119":0.02841,"120":0.29541,"121":0.01704,"122":0.0909,"123":0.00568,"124":0.31814,"125":0.94873,"126":4.6357,"127":0.03977,"128":0.02272,"129":0.01704,"130":0.01704,"131":0.61923,"132":0.06817,"133":0.57378,"134":0.02841,"135":0.05113,"136":0.05681,"137":0.03409,"138":0.10226,"139":0.12498,"140":0.08522,"141":0.15907,"142":6.02186,"143":11.8392,_:"4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 35 36 37 38 39 40 41 42 43 44 45 46 47 48 49 50 51 52 53 54 55 56 57 58 59 60 61 62 63 64 65 67 68 70 71 72 73 74 75 76 77 78 80 81 83 84 85 86 88 89 90 91 92 93 94 96 98 100 101 113 115 118 144 145 146"},F:{"93":0.01136,"95":0.02272,"122":0.00568,"123":0.01136,"124":0.85215,"125":0.35222,_:"9 11 12 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 35 36 37 38 39 40 41 42 43 44 45 46 47 48 49 50 51 52 53 54 55 56 57 58 60 62 63 64 65 66 67 68 69 70 71 72 73 74 75 76 77 78 79 80 81 82 83 84 85 86 87 88 89 90 91 92 94 96 97 98 99 100 101 102 103 104 105 106 107 108 109 110 111 112 113 114 115 116 117 118 119 120 121 9.5-9.6 10.0-10.1 10.5 10.6 11.1 11.5 11.6 12.1"},B:{"17":0.00568,"92":0.00568,"109":0.01704,"128":0.00568,"131":0.00568,"135":0.00568,"137":0.00568,"138":0.00568,"139":0.00568,"140":0.00568,"141":0.02841,"142":0.54538,"143":1.50547,_:"12 13 14 15 16 18 79 80 81 83 84 85 86 87 88 89 90 91 93 94 95 96 97 98 99 100 101 102 103 104 105 106 107 108 110 111 112 113 114 115 116 117 118 119 120 121 122 123 124 125 126 127 129 130 132 133 134 136"},E:{_:"0 4 5 6 7 8 9 10 11 12 13 14 15 3.1 3.2 5.1 6.1 7.1 9.1 10.1 12.1 13.1 15.1 15.2-15.3 15.4 15.5 16.0 16.1 16.2 16.5 17.0 17.2 18.0 18.1 26.3","11.1":0.00568,"14.1":0.00568,"15.6":0.01704,"16.3":0.00568,"16.4":0.00568,"16.6":0.03409,"17.1":0.01704,"17.3":0.00568,"17.4":0.00568,"17.5":0.00568,"17.6":0.02272,"18.2":0.00568,"18.3":0.01136,"18.4":0.00568,"18.5-18.6":0.02272,"26.0":0.01136,"26.1":0.09658,"26.2":0.01704},G:{"8":0,"3.2":0,"4.0-4.1":0,"4.2-4.3":0.00065,"5.0-5.1":0,"6.0-6.1":0.0013,"7.0-7.1":0.00098,"8.1-8.4":0,"9.0-9.2":0,"9.3":0.0026,"10.0-10.2":0.00033,"10.3":0.00455,"11.0-11.2":0.05595,"11.3-11.4":0.00163,"12.0-12.1":0.0013,"12.2-12.5":0.01464,"13.0-13.1":0.00033,"13.2":0.00228,"13.3":0.00065,"13.4-13.7":0.00228,"14.0-14.4":0.00455,"14.5-14.8":0.00488,"15.0-15.1":0.0052,"15.2-15.3":0.0039,"15.4":0.00423,"15.5":0.00455,"15.6-15.8":0.07059,"16.0":0.00813,"16.1":0.01561,"16.2":0.00813,"16.3":0.01464,"16.4":0.00358,"16.5":0.00618,"16.6-16.7":0.09173,"17.0":0.0052,"17.1":0.00846,"17.2":0.00618,"17.3":0.00943,"17.4":0.01594,"17.5":0.03123,"17.6-17.7":0.07222,"18.0":0.01626,"18.1":0.03383,"18.2":0.01789,"18.3":0.05823,"18.4":0.02993,"18.5-18.7":2.14891,"26.0":0.04196,"26.1":0.34904,"26.2":0.06636,"26.3":0.00293},P:{"21":0.0103,"22":0.0103,"23":0.0103,"24":0.0206,"25":0.0206,"26":0.07209,"27":0.03089,"28":0.07209,"29":1.55499,_:"4 20 5.0-5.4 6.2-6.4 9.2 10.1 11.1-11.2 12.0 13.0 14.0 15.0 16.0 18.0 19.0","7.2-7.4":0.08238,"8.2":0.0103,"17.0":0.0103},I:{"0":0.01725,"3":0,"4":0,"2.1":0,"2.2":0,"2.3":0,"4.1":0,"4.2-4.3":0,"4.4":0,"4.4.3-4.4.4":0.00001},A:{"11":0.11362,_:"6 7 8 9 10 5.5"},K:{"0":0.0648,_:"10 11 12 11.1 11.5 12.1"},N:{_:"10 11"},S:{_:"2.5 3.0-3.1"},J:{_:"7 10"},Q:{_:"14.9"},O:{"0":0.00432},H:{"0":0},L:{"0":40.62286},R:{_:"0"},M:{"0":0.09504}};

View File

@@ -0,0 +1,18 @@
/**
* @license lucide-react v0.441.0 - ISC
*
* This source code is licensed under the ISC license.
* See the LICENSE file in the root directory of this source tree.
*/
import createLucideIcon from '../createLucideIcon.js';
const Radius = createLucideIcon("Radius", [
["path", { d: "M20.34 17.52a10 10 0 1 0-2.82 2.82", key: "fydyku" }],
["circle", { cx: "19", cy: "19", r: "2", key: "17f5cg" }],
["path", { d: "m13.41 13.41 4.18 4.18", key: "1gqbwc" }],
["circle", { cx: "12", cy: "12", r: "2", key: "1c9p78" }]
]);
export { Radius as default };
//# sourceMappingURL=radius.js.map

View File

@@ -0,0 +1,103 @@
var test = require("tape")
var extend = require("./")
var mutableExtend = require("./mutable")
test("merge", function(assert) {
var a = { a: "foo" }
var b = { b: "bar" }
assert.deepEqual(extend(a, b), { a: "foo", b: "bar" })
assert.end()
})
test("replace", function(assert) {
var a = { a: "foo" }
var b = { a: "bar" }
assert.deepEqual(extend(a, b), { a: "bar" })
assert.end()
})
test("undefined", function(assert) {
var a = { a: undefined }
var b = { b: "foo" }
assert.deepEqual(extend(a, b), { a: undefined, b: "foo" })
assert.deepEqual(extend(b, a), { a: undefined, b: "foo" })
assert.end()
})
test("handle 0", function(assert) {
var a = { a: "default" }
var b = { a: 0 }
assert.deepEqual(extend(a, b), { a: 0 })
assert.deepEqual(extend(b, a), { a: "default" })
assert.end()
})
test("is immutable", function (assert) {
var record = {}
extend(record, { foo: "bar" })
assert.equal(record.foo, undefined)
assert.end()
})
test("null as argument", function (assert) {
var a = { foo: "bar" }
var b = null
var c = void 0
assert.deepEqual(extend(b, a, c), { foo: "bar" })
assert.end()
})
test("mutable", function (assert) {
var a = { foo: "bar" }
mutableExtend(a, { bar: "baz" })
assert.equal(a.bar, "baz")
assert.end()
})
test("null prototype", function(assert) {
var a = { a: "foo" }
var b = Object.create(null)
b.b = "bar";
assert.deepEqual(extend(a, b), { a: "foo", b: "bar" })
assert.end()
})
test("null prototype mutable", function (assert) {
var a = { foo: "bar" }
var b = Object.create(null)
b.bar = "baz";
mutableExtend(a, b)
assert.equal(a.bar, "baz")
assert.end()
})
test("prototype pollution", function (assert) {
var a = {}
var maliciousPayload = '{"__proto__":{"oops":"It works!"}}'
assert.strictEqual(a.oops, undefined)
extend({}, maliciousPayload)
assert.strictEqual(a.oops, undefined)
assert.end()
})
test("prototype pollution mutable", function (assert) {
var a = {}
var maliciousPayload = '{"__proto__":{"oops":"It works!"}}'
assert.strictEqual(a.oops, undefined)
mutableExtend({}, maliciousPayload)
assert.strictEqual(a.oops, undefined)
assert.end()
})

View File

@@ -0,0 +1,41 @@
import { animationControls } from './animation-controls.mjs';
import { useConstant } from '../../utils/use-constant.mjs';
import { useIsomorphicLayoutEffect } from '../../utils/use-isomorphic-effect.mjs';
/**
* Creates `AnimationControls`, which can be used to manually start, stop
* and sequence animations on one or more components.
*
* The returned `AnimationControls` should be passed to the `animate` property
* of the components you want to animate.
*
* These components can then be animated with the `start` method.
*
* ```jsx
* import * as React from 'react'
* import { motion, useAnimation } from 'framer-motion'
*
* export function MyComponent(props) {
* const controls = useAnimation()
*
* controls.start({
* x: 100,
* transition: { duration: 0.5 },
* })
*
* return <motion.div animate={controls} />
* }
* ```
*
* @returns Animation controller with `start` and `stop` methods
*
* @public
*/
function useAnimationControls() {
const controls = useConstant(animationControls);
useIsomorphicLayoutEffect(controls.mount, []);
return controls;
}
const useAnimation = useAnimationControls;
export { useAnimation, useAnimationControls };

View File

@@ -0,0 +1,8 @@
"use strict";
exports.millisecondsToHours = void 0;
var _index = require("../millisecondsToHours.cjs");
var _index2 = require("./_lib/convertToFP.cjs"); // This file is generated automatically by `scripts/build/fp.ts`. Please, don't change it.
const millisecondsToHours = (exports.millisecondsToHours = (0,
_index2.convertToFP)(_index.millisecondsToHours, 1));

View File

@@ -0,0 +1,75 @@
import epoch from '../lib/epoch.js';
import isObject from '../lib/is_object.js';
import secs from '../lib/secs.js';
function validateInput(label, input) {
if (!Number.isFinite(input)) {
throw new TypeError(`Invalid ${label} input`);
}
return input;
}
export class ProduceJWT {
constructor(payload = {}) {
if (!isObject(payload)) {
throw new TypeError('JWT Claims Set MUST be an object');
}
this._payload = payload;
}
setIssuer(issuer) {
this._payload = { ...this._payload, iss: issuer };
return this;
}
setSubject(subject) {
this._payload = { ...this._payload, sub: subject };
return this;
}
setAudience(audience) {
this._payload = { ...this._payload, aud: audience };
return this;
}
setJti(jwtId) {
this._payload = { ...this._payload, jti: jwtId };
return this;
}
setNotBefore(input) {
if (typeof input === 'number') {
this._payload = { ...this._payload, nbf: validateInput('setNotBefore', input) };
}
else if (input instanceof Date) {
this._payload = { ...this._payload, nbf: validateInput('setNotBefore', epoch(input)) };
}
else {
this._payload = { ...this._payload, nbf: epoch(new Date()) + secs(input) };
}
return this;
}
setExpirationTime(input) {
if (typeof input === 'number') {
this._payload = { ...this._payload, exp: validateInput('setExpirationTime', input) };
}
else if (input instanceof Date) {
this._payload = { ...this._payload, exp: validateInput('setExpirationTime', epoch(input)) };
}
else {
this._payload = { ...this._payload, exp: epoch(new Date()) + secs(input) };
}
return this;
}
setIssuedAt(input) {
if (typeof input === 'undefined') {
this._payload = { ...this._payload, iat: epoch(new Date()) };
}
else if (input instanceof Date) {
this._payload = { ...this._payload, iat: validateInput('setIssuedAt', epoch(input)) };
}
else if (typeof input === 'string') {
this._payload = {
...this._payload,
iat: validateInput('setIssuedAt', epoch(new Date()) + secs(input)),
};
}
else {
this._payload = { ...this._payload, iat: validateInput('setIssuedAt', input) };
}
return this;
}
}

View File

@@ -0,0 +1 @@
module.exports={A:{A:{"2":"K D E zC","260":"F A B"},B:{"1":"0 1 2 3 4 5 6 7 8 Q H R S T U V W X Y Z a b c d e f g h i j k l m n o p q r s t u v w x y z JB KB LB MB NB OB PB QB RB SB TB UB VB WB XB YB ZB aB I","260":"C L M G N O P"},C:{"1":"0 1 2 3 4 5 6 7 8 IB dB eB fB gB hB iB jB kB lB mB nB oB pB qB rB sB tB uB vB wB xB yB zB 0B 1B 2B 3B 4B 5B WC 6B XC 7B 8B 9B AC BC CC DC EC FC GC HC IC JC KC LC MC NC Q H R YC S T U V W X Y Z a b c d e f g h i j k l m n o p q r s t u v w x y z JB KB LB MB NB OB PB QB RB SB TB UB VB WB XB YB ZB aB I ZC aC OC 1C 2C 3C","2":"9 0C VC J bB K D E F A B C L M G N O P cB AB BB 4C 5C","132":"CB DB EB FB GB HB"},D:{"1":"0 1 2 3 4 5 6 7 8 yB zB 0B 1B 2B 3B 4B 5B WC 6B XC 7B 8B 9B AC BC CC DC EC FC GC HC IC JC KC LC MC NC Q H R S T U V W X Y Z a b c d e f g h i j k l m n o p q r s t u v w x y z JB KB LB MB NB OB PB QB RB SB TB UB VB WB XB YB ZB aB I ZC aC OC","2":"9 J bB K D E F A B C L M G N O P cB AB BB CB DB EB FB GB HB IB dB eB fB gB hB iB jB kB lB mB nB oB pB qB rB sB tB uB vB wB xB"},E:{"1":"B C L M G cC PC QC BD CD DD dC eC RC ED SC fC gC hC iC jC FD TC kC lC mC nC oC GD UC pC qC rC sC HD tC uC vC wC ID","2":"J bB K D E F A 6C bC 7C 8C 9C AD"},F:{"1":"0 1 2 3 4 5 6 7 8 lB mB nB oB pB qB rB sB tB uB vB wB xB yB zB 0B 1B 2B 3B 4B 5B 6B 7B 8B 9B AC BC CC DC EC FC GC HC IC JC KC LC MC NC Q H R YC S T U V W X Y Z a b c d e f g h i j k l m n o p q r s t u v w x y z QC","2":"9 F B G N O P cB AB BB CB DB EB FB GB HB IB dB eB fB gB hB iB jB kB JD KD LD MD PC xC ND","16":"C"},G:{"1":"WD XD YD ZD aD bD cD dD eD fD gD hD dC eC RC iD SC fC gC hC iC jC jD TC kC lC mC nC oC kD UC pC qC rC sC lD tC uC vC wC","2":"E bC OD yC PD QD RD SD TD UD VD"},H:{"1":"mD"},I:{"1":"I","2":"VC J nD oD pD qD yC rD sD"},J:{"2":"D A"},K:{"1":"H QC","2":"A B PC xC","16":"C"},L:{"1":"I"},M:{"1":"OC"},N:{"260":"A B"},O:{"1":"RC"},P:{"1":"9 AB BB CB DB EB FB GB HB IB tD uD vD wD xD cC yD zD 0D 1D 2D SC TC UC 3D","2":"J"},Q:{"1":"4D"},R:{"1":"5D"},S:{"1":"6D 7D"}},B:5,C:"KeyboardEvent.key",D:true};

View File

@@ -0,0 +1 @@
{"version":3,"file":"prisma.d.ts","sourceRoot":"","sources":["../../../../src/integrations/tracing/prisma.ts"],"names":[],"mappings":"AAEA,OAAO,KAAK,EAAE,eAAe,EAAE,MAAM,gCAAgC,CAAC;AAEtE,OAAO,EAAE,qBAAqB,EAAE,MAAM,yBAAyB,CAAC;AAmDhE,UAAU,aAAa;IACrB;;OAEG;IACH,qBAAqB,CAAC,EAAE,eAAe,CAAC;IACxC;;OAEG;IACH,qBAAqB,CAAC,EAAE,qBAAqB,CAAC,OAAO,qBAAqB,CAAC,CAAC,CAAC,CAAC,CAAC;CAChF;AA2GD,eAAO,MAAM,gBAAgB;;CAE3B,CAAC;AAEH;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;GA+BG;AACH,eAAO,MAAM,iBAAiB,6EAgC5B,CAAC"}

View File

@@ -0,0 +1 @@
module.exports={A:{A:{"2":"K D E F A B zC"},B:{"2":"0 1 2 3 4 5 6 7 8 C L M G N O P Q H R S T U V W X Y Z a b c d e f g h i j k l m n o p q r s t u v w x y z JB KB LB MB NB OB PB QB RB SB TB UB VB WB XB YB ZB aB I"},C:{"2":"0 1 2 3 4 5 6 7 8 9 0C VC J bB K D E F A B C L M G N O P cB AB BB CB DB EB FB GB HB IB dB eB fB gB hB iB jB kB lB mB nB oB pB qB rB sB tB uB vB wB xB yB zB 0B 1B 2B 3B 4B 5B WC 6B XC 7B 8B 9B AC BC CC DC EC FC GC HC IC JC KC LC MC NC Q H R YC S T U V W X Y Z a b c d e f g h i j k l m n o p q r s t u v w x y z JB KB LB MB NB OB PB QB RB SB TB UB VB WB XB YB ZB aB I ZC aC OC 1C 2C 3C 4C 5C"},D:{"2":"0 1 2 3 4 5 6 7 8 9 J bB K D E F A B C L M G N O P cB AB BB CB DB EB FB GB HB IB dB eB fB gB hB iB jB kB lB mB nB oB pB qB rB sB tB uB vB wB xB yB zB 0B 1B 2B 3B 4B 5B WC 6B XC 7B 8B 9B AC BC CC DC EC FC GC HC IC JC KC LC MC NC Q H R S T U V W X Y Z a b c d e f g h i j k l m n o p q r s t u v w x y z JB KB LB MB NB OB PB QB RB SB TB UB VB WB XB YB ZB aB I ZC aC OC"},E:{"1":"M G BD CD DD dC eC RC ED SC fC gC hC iC jC FD TC kC lC mC nC oC GD UC pC qC rC sC HD tC uC vC wC ID","2":"J bB K D E F A B C L 6C bC 7C 8C 9C AD cC PC QC"},F:{"2":"0 1 2 3 4 5 6 7 8 9 F B C G N O P cB AB BB CB DB EB FB GB HB IB dB eB fB gB hB iB jB kB lB mB nB oB pB qB rB sB tB uB vB wB xB yB zB 0B 1B 2B 3B 4B 5B 6B 7B 8B 9B AC BC CC DC EC FC GC HC IC JC KC LC MC NC Q H R YC S T U V W X Y Z a b c d e f g h i j k l m n o p q r s t u v w x y z JD KD LD MD PC xC ND QC"},G:{"1":"eD fD gD hD dC eC RC iD SC fC gC hC iC jC jD TC kC lC mC nC oC kD UC pC qC rC sC lD tC uC vC wC","2":"E bC OD yC PD QD RD SD TD UD VD WD XD YD ZD aD bD cD dD"},H:{"2":"mD"},I:{"2":"VC J I nD oD pD qD yC rD sD"},J:{"2":"D A"},K:{"2":"A B C H PC xC QC"},L:{"2":"I"},M:{"2":"OC"},N:{"2":"A B"},O:{"2":"RC"},P:{"2":"9 J AB BB CB DB EB FB GB HB IB tD uD vD wD xD cC yD zD 0D 1D 2D SC TC UC 3D"},Q:{"2":"4D"},R:{"2":"5D"},S:{"2":"6D 7D"}},B:5,C:"ui-serif, ui-sans-serif, ui-monospace and ui-rounded values for font-family",D:true};

View File

@@ -0,0 +1 @@
{"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../../../src/routes/rest/index.ts"],"names":[],"mappings":"AAAA,OAAO,EAAmB,KAAK,eAAe,EAAE,MAAM,SAAS,CAAA;AA+C/D,eAAO,MAAM,OAAO,WAvCT,OAAO,CAAC,eAAe,CAAC,GAAG,eAAe,eAExC,OAAO,QACV;IACJ,MAAM,EAAE,OAAO,CAAC;QAAE,IAAI,CAAC,EAAE,MAAM,EAAE,CAAA;KAAE,CAAC,CAAA;CACrC,KACA,OAAO,CAAC,QAAQ,CAiCgB,CAAA;AAErC,eAAO,MAAM,GAAG,WAzCL,OAAO,CAAC,eAAe,CAAC,GAAG,eAAe,eAExC,OAAO,QACV;IACJ,MAAM,EAAE,OAAO,CAAC;QAAE,IAAI,CAAC,EAAE,MAAM,EAAE,CAAA;KAAE,CAAC,CAAA;CACrC,KACA,OAAO,CAAC,QAAQ,CAmCY,CAAA;AAEjC,eAAO,MAAM,IAAI,WA3CN,OAAO,CAAC,eAAe,CAAC,GAAG,eAAe,eAExC,OAAO,QACV;IACJ,MAAM,EAAE,OAAO,CAAC;QAAE,IAAI,CAAC,EAAE,MAAM,EAAE,CAAA;KAAE,CAAC,CAAA;CACrC,KACA,OAAO,CAAC,QAAQ,CAqCa,CAAA;AAElC,eAAO,MAAM,MAAM,WA7CR,OAAO,CAAC,eAAe,CAAC,GAAG,eAAe,eAExC,OAAO,QACV;IACJ,MAAM,EAAE,OAAO,CAAC;QAAE,IAAI,CAAC,EAAE,MAAM,EAAE,CAAA;KAAE,CAAC,CAAA;CACrC,KACA,OAAO,CAAC,QAAQ,CAuCe,CAAA;AAEpC,eAAO,MAAM,KAAK,WA/CP,OAAO,CAAC,eAAe,CAAC,GAAG,eAAe,eAExC,OAAO,QACV;IACJ,MAAM,EAAE,OAAO,CAAC;QAAE,IAAI,CAAC,EAAE,MAAM,EAAE,CAAA;KAAE,CAAC,CAAA;CACrC,KACA,OAAO,CAAC,QAAQ,CAyCc,CAAA;AAEnC,eAAO,MAAM,GAAG,WAjDL,OAAO,CAAC,eAAe,CAAC,GAAG,eAAe,eAExC,OAAO,QACV;IACJ,MAAM,EAAE,OAAO,CAAC;QAAE,IAAI,CAAC,EAAE,MAAM,EAAE,CAAA;KAAE,CAAC,CAAA;CACrC,KACA,OAAO,CAAC,QAAQ,CA2CY,CAAA"}

View File

@@ -0,0 +1 @@
{"version":3,"file":"table-columns-split.js","sources":["../../../src/icons/table-columns-split.ts"],"sourcesContent":["import createLucideIcon from '../createLucideIcon';\n\n/**\n * @component @name TableColumnsSplit\n * @description Lucide SVG icon component, renders SVG Element with children.\n *\n * @preview ![img](data:image/svg+xml;base64,PHN2ZyAgeG1sbnM9Imh0dHA6Ly93d3cudzMub3JnLzIwMDAvc3ZnIgogIHdpZHRoPSIyNCIKICBoZWlnaHQ9IjI0IgogIHZpZXdCb3g9IjAgMCAyNCAyNCIKICBmaWxsPSJub25lIgogIHN0cm9rZT0iIzAwMCIgc3R5bGU9ImJhY2tncm91bmQtY29sb3I6ICNmZmY7IGJvcmRlci1yYWRpdXM6IDJweCIKICBzdHJva2Utd2lkdGg9IjIiCiAgc3Ryb2tlLWxpbmVjYXA9InJvdW5kIgogIHN0cm9rZS1saW5lam9pbj0icm91bmQiCj4KICA8cGF0aCBkPSJNMTQgMTR2MiIgLz4KICA8cGF0aCBkPSJNMTQgMjB2MiIgLz4KICA8cGF0aCBkPSJNMTQgMnYyIiAvPgogIDxwYXRoIGQ9Ik0xNCA4djIiIC8+CiAgPHBhdGggZD0iTTIgMTVoOCIgLz4KICA8cGF0aCBkPSJNMiAzaDZhMiAyIDAgMCAxIDIgMnYxNGEyIDIgMCAwIDEtMiAySDIiIC8+CiAgPHBhdGggZD0iTTIgOWg4IiAvPgogIDxwYXRoIGQ9Ik0yMiAxNWgtNCIgLz4KICA8cGF0aCBkPSJNMjIgM2gtMmEyIDIgMCAwIDAtMiAydjE0YTIgMiAwIDAgMCAyIDJoMiIgLz4KICA8cGF0aCBkPSJNMjIgOWgtNCIgLz4KICA8cGF0aCBkPSJNNSAzdjE4IiAvPgo8L3N2Zz4K) - https://lucide.dev/icons/table-columns-split\n * @see https://lucide.dev/guide/packages/lucide-react - Documentation\n *\n * @param {Object} props - Lucide icons props and any valid SVG attribute\n * @returns {JSX.Element} JSX Element\n *\n */\nconst TableColumnsSplit = createLucideIcon('TableColumnsSplit', [\n ['path', { d: 'M14 14v2', key: 'w2a1xv' }],\n ['path', { d: 'M14 20v2', key: '1lq872' }],\n ['path', { d: 'M14 2v2', key: '6buw04' }],\n ['path', { d: 'M14 8v2', key: 'i67w9a' }],\n ['path', { d: 'M2 15h8', key: '82wtch' }],\n ['path', { d: 'M2 3h6a2 2 0 0 1 2 2v14a2 2 0 0 1-2 2H2', key: 'up0l64' }],\n ['path', { d: 'M2 9h8', key: 'yelfik' }],\n ['path', { d: 'M22 15h-4', key: '1es58f' }],\n ['path', { d: 'M22 3h-2a2 2 0 0 0-2 2v14a2 2 0 0 0 2 2h2', key: 'pdjoqf' }],\n ['path', { d: 'M22 9h-4', key: '1luja7' }],\n ['path', { d: 'M5 3v18', key: '14hmio' }],\n]);\n\nexport default TableColumnsSplit;\n"],"names":[],"mappings":";;;;;;;;;AAaM,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAoB,iBAAiB,mBAAqB,CAAA,CAAA,CAAA;AAAA,CAAA,CAC9D,CAAC,CAAA,CAAA,CAAA,CAAA,CAAA,CAAQ,CAAA,CAAA,CAAA,CAAE,GAAG,CAAY,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAK,UAAU,CAAA,CAAA;AAAA,CAAA,CACzC,CAAC,CAAA,CAAA,CAAA,CAAA,CAAA,CAAQ,CAAA,CAAA,CAAA,CAAE,GAAG,CAAY,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAK,UAAU,CAAA,CAAA;AAAA,CAAA,CACzC,CAAC,CAAA,CAAA,CAAA,CAAA,CAAA,CAAQ,CAAA,CAAA,CAAA,CAAE,GAAG,CAAW,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAK,UAAU,CAAA,CAAA;AAAA,CAAA,CACxC,CAAC,CAAA,CAAA,CAAA,CAAA,CAAA,CAAQ,CAAA,CAAA,CAAA,CAAE,GAAG,CAAW,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAK,UAAU,CAAA,CAAA;AAAA,CAAA,CACxC,CAAC,CAAA,CAAA,CAAA,CAAA,CAAA,CAAQ,CAAA,CAAA,CAAA,CAAE,GAAG,CAAW,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAK,UAAU,CAAA,CAAA;AAAA,CAAA,CACxC,CAAC,CAAA,CAAA,CAAA,CAAA,CAAA,CAAQ,CAAA,CAAA,CAAA,CAAE,GAAG,CAA2C,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAK,UAAU,CAAA,CAAA;AAAA,CAAA,CACxE,CAAC,CAAA,CAAA,CAAA,CAAA,CAAA,CAAQ,CAAA,CAAA,CAAA,CAAE,GAAG,CAAU,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAK,UAAU,CAAA,CAAA;AAAA,CAAA,CACvC,CAAC,CAAA,CAAA,CAAA,CAAA,CAAA,CAAQ,CAAA,CAAA,CAAA,CAAE,GAAG,CAAa,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAK,UAAU,CAAA,CAAA;AAAA,CAAA,CAC1C,CAAC,CAAA,CAAA,CAAA,CAAA,CAAA,CAAQ,CAAA,CAAA,CAAA,CAAE,GAAG,CAA6C,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAK,UAAU,CAAA,CAAA;AAAA,CAAA,CAC1E,CAAC,CAAA,CAAA,CAAA,CAAA,CAAA,CAAQ,CAAA,CAAA,CAAA,CAAE,GAAG,CAAY,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAK,UAAU,CAAA,CAAA;AAAA,CAAA,CACzC,CAAC,CAAA,CAAA,CAAA,CAAA,CAAA,CAAQ,CAAA,CAAA,CAAA,CAAE,GAAG,CAAW,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAK,UAAU,CAAA;AAC1C,CAAC,CAAA,CAAA;;"}

View File

@@ -0,0 +1,452 @@
import AtRule from './at-rule.js'
import Comment from './comment.js'
import Declaration from './declaration.js'
import Node, { ChildNode, ChildProps, NodeProps } from './node.js'
import Rule from './rule.js'
declare namespace Container {
export interface ValueOptions {
/**
* String thats used to narrow down values and speed up the regexp search.
*/
fast?: string
/**
* An array of property names.
*/
props?: string[]
}
export interface ContainerProps extends NodeProps {
nodes?: (ChildNode | ChildProps)[]
}
// eslint-disable-next-line @typescript-eslint/no-use-before-define
export { Container_ as default }
}
/**
* The `Root`, `AtRule`, and `Rule` container nodes
* inherit some common methods to help work with their children.
*
* Note that all containers can store any content. If you write a rule inside
* a rule, PostCSS will parse it.
*/
declare abstract class Container_<Child extends Node = ChildNode> extends Node {
/**
* An array containing the containers children.
*
* ```js
* const root = postcss.parse('a { color: black }')
* root.nodes.length //=> 1
* root.nodes[0].selector //=> 'a'
* root.nodes[0].nodes[0].prop //=> 'color'
* ```
*/
nodes: Child[]
/**
* Inserts new nodes to the end of the container.
*
* ```js
* const decl1 = new Declaration({ prop: 'color', value: 'black' })
* const decl2 = new Declaration({ prop: 'background-color', value: 'white' })
* rule.append(decl1, decl2)
*
* root.append({ name: 'charset', params: '"UTF-8"' }) // at-rule
* root.append({ selector: 'a' }) // rule
* rule.append({ prop: 'color', value: 'black' }) // declaration
* rule.append({ text: 'Comment' }) // comment
*
* root.append('a {}')
* root.first.append('color: black; z-index: 1')
* ```
*
* @param nodes New nodes.
* @return This node for methods chain.
*/
append(
...nodes: (ChildProps | ChildProps[] | Node | Node[] | string | string[])[]
): this
assign(overrides: Container.ContainerProps | object): this
clone(overrides?: Partial<Container.ContainerProps>): Container<Child>
cloneAfter(overrides?: Partial<Container.ContainerProps>): Container<Child>
cloneBefore(overrides?: Partial<Container.ContainerProps>): Container<Child>
/**
* Iterates through the containers immediate children,
* calling `callback` for each child.
*
* Returning `false` in the callback will break iteration.
*
* This method only iterates through the containers immediate children.
* If you need to recursively iterate through all the containers descendant
* nodes, use `Container#walk`.
*
* Unlike the for `{}`-cycle or `Array#forEach` this iterator is safe
* if you are mutating the array of child nodes during iteration.
* PostCSS will adjust the current index to match the mutations.
*
* ```js
* const root = postcss.parse('a { color: black; z-index: 1 }')
* const rule = root.first
*
* for (const decl of rule.nodes) {
* decl.cloneBefore({ prop: '-webkit-' + decl.prop })
* // Cycle will be infinite, because cloneBefore moves the current node
* // to the next index
* }
*
* rule.each(decl => {
* decl.cloneBefore({ prop: '-webkit-' + decl.prop })
* // Will be executed only for color and z-index
* })
* ```
*
* @param callback Iterator receives each node and index.
* @return Returns `false` if iteration was broke.
*/
each(
callback: (node: Child, index: number) => false | void
): false | undefined
/**
* Returns `true` if callback returns `true`
* for all of the containers children.
*
* ```js
* const noPrefixes = rule.every(i => i.prop[0] !== '-')
* ```
*
* @param condition Iterator returns true or false.
* @return Is every child pass condition.
*/
every(
condition: (node: Child, index: number, nodes: Child[]) => boolean
): boolean
/**
* Returns a `child`s index within the `Container#nodes` array.
*
* ```js
* rule.index( rule.nodes[2] ) //=> 2
* ```
*
* @param child Child of the current container.
* @return Child index.
*/
index(child: Child | number): number
/**
* Insert new node after old node within the container.
*
* @param oldNode Child or childs index.
* @param newNode New node.
* @return This node for methods chain.
*/
insertAfter(
oldNode: Child | number,
newNode: Child | Child[] | ChildProps | ChildProps[] | string | string[]
): this
/**
* Insert new node before old node within the container.
*
* ```js
* rule.insertBefore(decl, decl.clone({ prop: '-webkit-' + decl.prop }))
* ```
*
* @param oldNode Child or childs index.
* @param newNode New node.
* @return This node for methods chain.
*/
insertBefore(
oldNode: Child | number,
newNode: Child | Child[] | ChildProps | ChildProps[] | string | string[]
): this
/**
* Traverses the containers descendant nodes, calling callback
* for each comment node.
*
* Like `Container#each`, this method is safe
* to use if you are mutating arrays during iteration.
*
* ```js
* root.walkComments(comment => {
* comment.remove()
* })
* ```
*
* @param callback Iterator receives each node and index.
* @return Returns `false` if iteration was broke.
*/
/**
* Inserts new nodes to the start of the container.
*
* ```js
* const decl1 = new Declaration({ prop: 'color', value: 'black' })
* const decl2 = new Declaration({ prop: 'background-color', value: 'white' })
* rule.prepend(decl1, decl2)
*
* root.append({ name: 'charset', params: '"UTF-8"' }) // at-rule
* root.append({ selector: 'a' }) // rule
* rule.append({ prop: 'color', value: 'black' }) // declaration
* rule.append({ text: 'Comment' }) // comment
*
* root.append('a {}')
* root.first.append('color: black; z-index: 1')
* ```
*
* @param nodes New nodes.
* @return This node for methods chain.
*/
prepend(
...nodes: (ChildProps | ChildProps[] | Node | Node[] | string | string[])[]
): this
/**
* Add child to the end of the node.
*
* ```js
* rule.push(new Declaration({ prop: 'color', value: 'black' }))
* ```
*
* @param child New node.
* @return This node for methods chain.
*/
push(child: Child): this
/**
* Removes all children from the container
* and cleans their parent properties.
*
* ```js
* rule.removeAll()
* rule.nodes.length //=> 0
* ```
*
* @return This node for methods chain.
*/
removeAll(): this
/**
* Removes node from the container and cleans the parent properties
* from the node and its children.
*
* ```js
* rule.nodes.length //=> 5
* rule.removeChild(decl)
* rule.nodes.length //=> 4
* decl.parent //=> undefined
* ```
*
* @param child Child or childs index.
* @return This node for methods chain.
*/
removeChild(child: Child | number): this
replaceValues(
pattern: RegExp | string,
replaced: { (substring: string, ...args: any[]): string } | string
): this
/**
* Passes all declaration values within the container that match pattern
* through callback, replacing those values with the returned result
* of callback.
*
* This method is useful if you are using a custom unit or function
* and need to iterate through all values.
*
* ```js
* root.replaceValues(/\d+rem/, { fast: 'rem' }, string => {
* return 15 * parseInt(string) + 'px'
* })
* ```
*
* @param pattern Replace pattern.
* @param {object} opts Options to speed up the search.
* @param callback String to replace pattern or callback
* that returns a new value. The callback
* will receive the same arguments
* as those passed to a function parameter
* of `String#replace`.
* @return This node for methods chain.
*/
replaceValues(
pattern: RegExp | string,
options: Container.ValueOptions,
replaced: { (substring: string, ...args: any[]): string } | string
): this
/**
* Returns `true` if callback returns `true` for (at least) one
* of the containers children.
*
* ```js
* const hasPrefix = rule.some(i => i.prop[0] === '-')
* ```
*
* @param condition Iterator returns true or false.
* @return Is some child pass condition.
*/
some(
condition: (node: Child, index: number, nodes: Child[]) => boolean
): boolean
/**
* Traverses the containers descendant nodes, calling callback
* for each node.
*
* Like container.each(), this method is safe to use
* if you are mutating arrays during iteration.
*
* If you only need to iterate through the containers immediate children,
* use `Container#each`.
*
* ```js
* root.walk(node => {
* // Traverses all descendant nodes.
* })
* ```
*
* @param callback Iterator receives each node and index.
* @return Returns `false` if iteration was broke.
*/
walk(
callback: (node: ChildNode, index: number) => false | void
): false | undefined
/**
* Traverses the containers descendant nodes, calling callback
* for each at-rule node.
*
* If you pass a filter, iteration will only happen over at-rules
* that have matching names.
*
* Like `Container#each`, this method is safe
* to use if you are mutating arrays during iteration.
*
* ```js
* root.walkAtRules(rule => {
* if (isOld(rule.name)) rule.remove()
* })
*
* let first = false
* root.walkAtRules('charset', rule => {
* if (!first) {
* first = true
* } else {
* rule.remove()
* }
* })
* ```
*
* @param name String or regular expression to filter at-rules by name.
* @param callback Iterator receives each node and index.
* @return Returns `false` if iteration was broke.
*/
walkAtRules(
nameFilter: RegExp | string,
callback: (atRule: AtRule, index: number) => false | void
): false | undefined
walkAtRules(
callback: (atRule: AtRule, index: number) => false | void
): false | undefined
walkComments(
callback: (comment: Comment, indexed: number) => false | void
): false | undefined
walkComments(
callback: (comment: Comment, indexed: number) => false | void
): false | undefined
/**
* Traverses the containers descendant nodes, calling callback
* for each declaration node.
*
* If you pass a filter, iteration will only happen over declarations
* with matching properties.
*
* ```js
* root.walkDecls(decl => {
* checkPropertySupport(decl.prop)
* })
*
* root.walkDecls('border-radius', decl => {
* decl.remove()
* })
*
* root.walkDecls(/^background/, decl => {
* decl.value = takeFirstColorFromGradient(decl.value)
* })
* ```
*
* Like `Container#each`, this method is safe
* to use if you are mutating arrays during iteration.
*
* @param prop String or regular expression to filter declarations
* by property name.
* @param callback Iterator receives each node and index.
* @return Returns `false` if iteration was broke.
*/
walkDecls(
propFilter: RegExp | string,
callback: (decl: Declaration, index: number) => false | void
): false | undefined
walkDecls(
callback: (decl: Declaration, index: number) => false | void
): false | undefined
/**
* Traverses the containers descendant nodes, calling callback
* for each rule node.
*
* If you pass a filter, iteration will only happen over rules
* with matching selectors.
*
* Like `Container#each`, this method is safe
* to use if you are mutating arrays during iteration.
*
* ```js
* const selectors = []
* root.walkRules(rule => {
* selectors.push(rule.selector)
* })
* console.log(`Your CSS uses ${ selectors.length } selectors`)
* ```
*
* @param selector String or regular expression to filter rules by selector.
* @param callback Iterator receives each node and index.
* @return Returns `false` if iteration was broke.
*/
walkRules(
selectorFilter: RegExp | string,
callback: (rule: Rule, index: number) => false | void
): false | undefined
walkRules(
callback: (rule: Rule, index: number) => false | void
): false | undefined
/**
* The containers first child.
*
* ```js
* rule.first === rules.nodes[0]
* ```
*/
get first(): Child | undefined
/**
* The containers last child.
*
* ```js
* rule.last === rule.nodes[rule.nodes.length - 1]
* ```
*/
get last(): Child | undefined
}
declare class Container<Child extends Node = ChildNode> extends Container_<Child> {}
export = Container

View File

@@ -0,0 +1 @@
{"version":3,"file":"background-size.js","sourceRoot":"","sources":["../../../../src/css/property-descriptors/background-size.ts"],"names":[],"mappings":";;;AACA,2CAA2E;AAC3E,gEAAgF;AAIhF,IAAY,eAIX;AAJD,WAAY,eAAe;IACvB,gCAAa,CAAA;IACb,sCAAmB,CAAA;IACnB,kCAAe,CAAA;AACnB,CAAC,EAJW,eAAe,GAAf,uBAAe,KAAf,uBAAe,QAI1B;AAKY,QAAA,cAAc,GAA4C;IACnE,IAAI,EAAE,iBAAiB;IACvB,YAAY,EAAE,GAAG;IACjB,MAAM,EAAE,KAAK;IACb,IAAI,cAAoC;IACxC,KAAK,EAAE,UAAC,QAAiB,EAAE,MAAkB;QACzC,OAAO,0BAAiB,CAAC,MAAM,CAAC,CAAC,GAAG,CAAC,UAAC,MAAM,IAAK,OAAA,MAAM,CAAC,MAAM,CAAC,yBAAyB,CAAC,EAAxC,CAAwC,CAAC,CAAC;IAC/F,CAAC;CACJ,CAAC;AAEF,IAAM,yBAAyB,GAAG,UAAC,KAAe;IAC9C,OAAA,qBAAY,CAAC,KAAK,CAAC,IAAI,sCAAkB,CAAC,KAAK,CAAC;AAAhD,CAAgD,CAAC"}

View File

@@ -0,0 +1,57 @@
{
"name": "require-in-the-middle",
"version": "8.0.1",
"description": "Module to hook into the Node.js require function",
"main": "index.js",
"types": "types/index.d.ts",
"dependencies": {
"debug": "^4.3.5",
"module-details-from-path": "^1.0.3"
},
"devDependencies": {
"@babel/core": "^7.9.0",
"@babel/preset-env": "^7.9.5",
"@babel/preset-typescript": "^7.9.0",
"@babel/register": "^7.9.0",
"ipp-printer": "^1.0.0",
"patterns": "^1.0.3",
"roundround": "^0.2.0",
"semver": "^6.3.0",
"standard": "^14.3.1",
"tape": "^4.11.0"
},
"scripts": {
"test": "npm run test:lint && npm run test:tape && npm run test:babel",
"test:lint": "standard",
"test:tape": "tape test/*.js",
"test:babel": "node test/babel/babel-register.js"
},
"repository": {
"type": "git",
"url": "git+https://github.com/nodejs/require-in-the-middle.git"
},
"keywords": [
"require",
"hook",
"shim",
"shimmer",
"shimming",
"patch",
"monkey",
"monkeypatch",
"module",
"load"
],
"files": [
"types"
],
"author": "Thomas Watson Steen <w@tson.dk> (https://twitter.com/wa7son)",
"license": "MIT",
"bugs": {
"url": "https://github.com/nodejs/require-in-the-middle/issues"
},
"homepage": "https://github.com/nodejs/require-in-the-middle#readme",
"engines": {
"node": ">=9.3.0 || >=8.10.0 <9.0.0"
}
}

View File

@@ -0,0 +1 @@
{"version":3,"sources":["../../src/gel-core/policies.ts"],"sourcesContent":["import { entityKind } from '~/entity.ts';\nimport type { SQL } from '~/sql/sql.ts';\nimport type { GelRole } from './roles.ts';\nimport type { GelTable } from './table.ts';\n\nexport type GelPolicyToOption =\n\t| 'public'\n\t| 'current_role'\n\t| 'current_user'\n\t| 'session_user'\n\t| (string & {})\n\t| GelPolicyToOption[]\n\t| GelRole;\n\nexport interface GelPolicyConfig {\n\tas?: 'permissive' | 'restrictive';\n\tfor?: 'all' | 'select' | 'insert' | 'update' | 'delete';\n\tto?: GelPolicyToOption;\n\tusing?: SQL;\n\twithCheck?: SQL;\n}\n\nexport class GelPolicy implements GelPolicyConfig {\n\tstatic readonly [entityKind]: string = 'GelPolicy';\n\n\treadonly as: GelPolicyConfig['as'];\n\treadonly for: GelPolicyConfig['for'];\n\treadonly to: GelPolicyConfig['to'];\n\treadonly using: GelPolicyConfig['using'];\n\treadonly withCheck: GelPolicyConfig['withCheck'];\n\n\t/** @internal */\n\t_linkedTable?: GelTable;\n\n\tconstructor(\n\t\treadonly name: string,\n\t\tconfig?: GelPolicyConfig,\n\t) {\n\t\tif (config) {\n\t\t\tthis.as = config.as;\n\t\t\tthis.for = config.for;\n\t\t\tthis.to = config.to;\n\t\t\tthis.using = config.using;\n\t\t\tthis.withCheck = config.withCheck;\n\t\t}\n\t}\n\n\tlink(table: GelTable): this {\n\t\tthis._linkedTable = table;\n\t\treturn this;\n\t}\n}\n\nexport function gelPolicy(name: string, config?: GelPolicyConfig) {\n\treturn new GelPolicy(name, config);\n}\n"],"mappings":";;;;;;;;;;;;;;;;;;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA,oBAA2B;AAsBpB,MAAM,UAAqC;AAAA,EAYjD,YACU,MACT,QACC;AAFQ;AAGT,QAAI,QAAQ;AACX,WAAK,KAAK,OAAO;AACjB,WAAK,MAAM,OAAO;AAClB,WAAK,KAAK,OAAO;AACjB,WAAK,QAAQ,OAAO;AACpB,WAAK,YAAY,OAAO;AAAA,IACzB;AAAA,EACD;AAAA,EAtBA,QAAiB,wBAAU,IAAY;AAAA,EAE9B;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA;AAAA,EAGT;AAAA,EAeA,KAAK,OAAuB;AAC3B,SAAK,eAAe;AACpB,WAAO;AAAA,EACR;AACD;AAEO,SAAS,UAAU,MAAc,QAA0B;AACjE,SAAO,IAAI,UAAU,MAAM,MAAM;AAClC;","names":[]}

View File

@@ -0,0 +1 @@
{"version":3,"file":"defaultTimezones.d.ts","sourceRoot":"","sources":["../../../../src/fields/baseFields/timezone/defaultTimezones.ts"],"names":[],"mappings":"AAAA,OAAO,KAAK,EAAE,QAAQ,EAAE,MAAM,0BAA0B,CAAA;AAExD;;;;;;;;GAQG;AACH,eAAO,MAAM,gBAAgB,EAAE,QAAQ,EAgDtC,CAAA"}

View File

@@ -0,0 +1,16 @@
/**
* @license lucide-react v0.441.0 - ISC
*
* This source code is licensed under the ISC license.
* See the LICENSE file in the root directory of this source tree.
*/
import createLucideIcon from '../createLucideIcon.js';
const Torus = createLucideIcon("Torus", [
["ellipse", { cx: "12", cy: "11", rx: "3", ry: "2", key: "1b2qxu" }],
["ellipse", { cx: "12", cy: "12.5", rx: "10", ry: "8.5", key: "h8emeu" }]
]);
export { Torus as default };
//# sourceMappingURL=torus.js.map

View File

@@ -0,0 +1 @@
{"version":3,"file":"ticket-check.js","sources":["../../../src/icons/ticket-check.ts"],"sourcesContent":["import createLucideIcon from '../createLucideIcon';\n\n/**\n * @component @name TicketCheck\n * @description Lucide SVG icon component, renders SVG Element with children.\n *\n * @preview ![img](data:image/svg+xml;base64,PHN2ZyAgeG1sbnM9Imh0dHA6Ly93d3cudzMub3JnLzIwMDAvc3ZnIgogIHdpZHRoPSIyNCIKICBoZWlnaHQ9IjI0IgogIHZpZXdCb3g9IjAgMCAyNCAyNCIKICBmaWxsPSJub25lIgogIHN0cm9rZT0iIzAwMCIgc3R5bGU9ImJhY2tncm91bmQtY29sb3I6ICNmZmY7IGJvcmRlci1yYWRpdXM6IDJweCIKICBzdHJva2Utd2lkdGg9IjIiCiAgc3Ryb2tlLWxpbmVjYXA9InJvdW5kIgogIHN0cm9rZS1saW5lam9pbj0icm91bmQiCj4KICA8cGF0aCBkPSJNMiA5YTMgMyAwIDAgMSAwIDZ2MmEyIDIgMCAwIDAgMiAyaDE2YTIgMiAwIDAgMCAyLTJ2LTJhMyAzIDAgMCAxIDAtNlY3YTIgMiAwIDAgMC0yLTJINGEyIDIgMCAwIDAtMiAyWiIgLz4KICA8cGF0aCBkPSJtOSAxMiAyIDIgNC00IiAvPgo8L3N2Zz4K) - https://lucide.dev/icons/ticket-check\n * @see https://lucide.dev/guide/packages/lucide-react - Documentation\n *\n * @param {Object} props - Lucide icons props and any valid SVG attribute\n * @returns {JSX.Element} JSX Element\n *\n */\nconst TicketCheck = createLucideIcon('TicketCheck', [\n [\n 'path',\n {\n d: 'M2 9a3 3 0 0 1 0 6v2a2 2 0 0 0 2 2h16a2 2 0 0 0 2-2v-2a3 3 0 0 1 0-6V7a2 2 0 0 0-2-2H4a2 2 0 0 0-2 2Z',\n key: 'qn84l0',\n },\n ],\n ['path', { d: 'm9 12 2 2 4-4', key: 'dzmm74' }],\n]);\n\nexport default TicketCheck;\n"],"names":[],"mappings":";;;;;;;;;AAaM,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAc,iBAAiB,aAAe,CAAA,CAAA,CAAA;AAAA,CAClD,CAAA,CAAA;AAAA,CAAA,CAAA,CAAA,CACE,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA;AAAA,CACA,CAAA,CAAA,CAAA,CAAA;AAAA,CACE,CAAA,CAAA,CAAA,CAAA,CAAA,CAAG,EAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA;AAAA,CACH,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAK,EAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA;AAAA,CACP,CAAA,CAAA,CAAA,CAAA;AAAA,CACF,CAAA,CAAA,CAAA;AAAA,CAAA,CACA,CAAC,CAAA,CAAA,CAAA,CAAA,CAAA,CAAQ,CAAA,CAAA,CAAA,CAAE,GAAG,CAAiB,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAK,UAAU,CAAA;AAChD,CAAC,CAAA,CAAA;;"}

View File

@@ -0,0 +1,155 @@
"use strict";
Object.defineProperty(exports, "__esModule", { value: true });
exports.filter = filter;
exports.find = find;
exports.findOneChild = findOneChild;
exports.findOne = findOne;
exports.existsOne = existsOne;
exports.findAll = findAll;
var domhandler_1 = require("domhandler");
/**
* Search a node and its children for nodes passing a test function. If `node` is not an array, it will be wrapped in one.
*
* @category Querying
* @param test Function to test nodes on.
* @param node Node to search. Will be included in the result set if it matches.
* @param recurse Also consider child nodes.
* @param limit Maximum number of nodes to return.
* @returns All nodes passing `test`.
*/
function filter(test, node, recurse, limit) {
if (recurse === void 0) { recurse = true; }
if (limit === void 0) { limit = Infinity; }
return find(test, Array.isArray(node) ? node : [node], recurse, limit);
}
/**
* Search an array of nodes and their children for nodes passing a test function.
*
* @category Querying
* @param test Function to test nodes on.
* @param nodes Array of nodes to search.
* @param recurse Also consider child nodes.
* @param limit Maximum number of nodes to return.
* @returns All nodes passing `test`.
*/
function find(test, nodes, recurse, limit) {
var result = [];
/** Stack of the arrays we are looking at. */
var nodeStack = [Array.isArray(nodes) ? nodes : [nodes]];
/** Stack of the indices within the arrays. */
var indexStack = [0];
for (;;) {
// First, check if the current array has any more elements to look at.
if (indexStack[0] >= nodeStack[0].length) {
// If we have no more arrays to look at, we are done.
if (indexStack.length === 1) {
return result;
}
// Otherwise, remove the current array from the stack.
nodeStack.shift();
indexStack.shift();
// Loop back to the start to continue with the next array.
continue;
}
var elem = nodeStack[0][indexStack[0]++];
if (test(elem)) {
result.push(elem);
if (--limit <= 0)
return result;
}
if (recurse && (0, domhandler_1.hasChildren)(elem) && elem.children.length > 0) {
/*
* Add the children to the stack. We are depth-first, so this is
* the next array we look at.
*/
indexStack.unshift(0);
nodeStack.unshift(elem.children);
}
}
}
/**
* Finds the first element inside of an array that matches a test function. This is an alias for `Array.prototype.find`.
*
* @category Querying
* @param test Function to test nodes on.
* @param nodes Array of nodes to search.
* @returns The first node in the array that passes `test`.
* @deprecated Use `Array.prototype.find` directly.
*/
function findOneChild(test, nodes) {
return nodes.find(test);
}
/**
* Finds one element in a tree that passes a test.
*
* @category Querying
* @param test Function to test nodes on.
* @param nodes Node or array of nodes to search.
* @param recurse Also consider child nodes.
* @returns The first node that passes `test`.
*/
function findOne(test, nodes, recurse) {
if (recurse === void 0) { recurse = true; }
var searchedNodes = Array.isArray(nodes) ? nodes : [nodes];
for (var i = 0; i < searchedNodes.length; i++) {
var node = searchedNodes[i];
if ((0, domhandler_1.isTag)(node) && test(node)) {
return node;
}
if (recurse && (0, domhandler_1.hasChildren)(node) && node.children.length > 0) {
var found = findOne(test, node.children, true);
if (found)
return found;
}
}
return null;
}
/**
* Checks if a tree of nodes contains at least one node passing a test.
*
* @category Querying
* @param test Function to test nodes on.
* @param nodes Array of nodes to search.
* @returns Whether a tree of nodes contains at least one node passing the test.
*/
function existsOne(test, nodes) {
return (Array.isArray(nodes) ? nodes : [nodes]).some(function (node) {
return ((0, domhandler_1.isTag)(node) && test(node)) ||
((0, domhandler_1.hasChildren)(node) && existsOne(test, node.children));
});
}
/**
* Search an array of nodes and their children for elements passing a test function.
*
* Same as `find`, but limited to elements and with less options, leading to reduced complexity.
*
* @category Querying
* @param test Function to test nodes on.
* @param nodes Array of nodes to search.
* @returns All nodes passing `test`.
*/
function findAll(test, nodes) {
var result = [];
var nodeStack = [Array.isArray(nodes) ? nodes : [nodes]];
var indexStack = [0];
for (;;) {
if (indexStack[0] >= nodeStack[0].length) {
if (nodeStack.length === 1) {
return result;
}
// Otherwise, remove the current array from the stack.
nodeStack.shift();
indexStack.shift();
// Loop back to the start to continue with the next array.
continue;
}
var elem = nodeStack[0][indexStack[0]++];
if ((0, domhandler_1.isTag)(elem) && test(elem))
result.push(elem);
if ((0, domhandler_1.hasChildren)(elem) && elem.children.length > 0) {
indexStack.unshift(0);
nodeStack.unshift(elem.children);
}
}
}
//# sourceMappingURL=querying.js.map

View File

@@ -0,0 +1 @@
{"version":3,"file":"Provider.js","names":["createContext","use","DocumentDrawerCallbacksContext","DocumentDrawerContextProvider","children","rest","_jsx","value","useDocumentDrawerContext","context","Error"],"sources":["../../../src/elements/DocumentDrawer/Provider.tsx"],"sourcesContent":["import type { ClientCollectionConfig, Data, FormState, TypeWithID } from 'payload'\n\nimport { createContext, use } from 'react'\n\nexport type DocumentDrawerContextProps = {\n readonly clearDoc?: () => void\n readonly drawerSlug: string\n readonly onDelete?: (args: {\n collectionConfig?: ClientCollectionConfig\n id: string\n }) => Promise<void> | void\n /* only available if `redirectAfterDuplicate` is `false` */\n readonly onDuplicate?: (args: {\n collectionConfig?: ClientCollectionConfig\n doc: TypeWithID\n }) => Promise<void> | void\n readonly onRestore?: (args: {\n collectionConfig?: ClientCollectionConfig\n id: string\n }) => Promise<void> | void\n readonly onSave?: (args: {\n collectionConfig?: ClientCollectionConfig\n /**\n * If you want to pass additional data to the onSuccess callback, you can use this context object.\n *\n * @experimental This property is experimental and may change in the future. Use at your own risk.\n */\n context?: Record<string, unknown>\n doc: TypeWithID\n operation: 'create' | 'update'\n result: Data\n }) => Promise<FormState | void> | void\n}\n\nexport type DocumentDrawerContextType = {} & DocumentDrawerContextProps\n\nexport const DocumentDrawerCallbacksContext = createContext({} as DocumentDrawerContextType)\n\nexport const DocumentDrawerContextProvider: React.FC<\n {\n children: React.ReactNode\n } & DocumentDrawerContextProps\n> = ({ children, ...rest }) => {\n return (\n <DocumentDrawerCallbacksContext value={{ ...rest }}>{children}</DocumentDrawerCallbacksContext>\n )\n}\n\nexport const useDocumentDrawerContext = (): DocumentDrawerContextType => {\n const context = use(DocumentDrawerCallbacksContext)\n\n if (!context) {\n throw new Error('useDocumentDrawerContext must be used within a DocumentDrawerProvider')\n }\n\n return context\n}\n"],"mappings":";AAEA,SAASA,aAAa,EAAEC,GAAG,QAAQ;AAkCnC,OAAO,MAAMC,8BAAA,gBAAiCF,aAAA,CAAc,CAAC;AAE7D,OAAO,MAAMG,6BAAA,GAITA,CAAC;EAAEC,QAAQ;EAAE,GAAGC;AAAA,CAAM;EACxB,oBACEC,IAAA,CAACJ,8BAAA;IAA+BK,KAAA,EAAO;MAAE,GAAGF;IAAK;cAAID;;AAEzD;AAEA,OAAO,MAAMI,wBAAA,GAA2BA,CAAA;EACtC,MAAMC,OAAA,GAAUR,GAAA,CAAIC,8BAAA;EAEpB,IAAI,CAACO,OAAA,EAAS;IACZ,MAAM,IAAIC,KAAA,CAAM;EAClB;EAEA,OAAOD,OAAA;AACT","ignoreList":[]}

View File

@@ -0,0 +1,4 @@
export declare const endOfSecond: import("./types.js").FPFn1<
Date,
import("../fp.js").DateArg<Date>
>;

View File

@@ -0,0 +1,26 @@
import React from 'react';
import './index.scss';
import type { SanitizedCollectionConfig } from 'payload';
export type ThumbnailProps = {
className?: string;
collectionSlug?: string;
doc?: Record<string, unknown>;
fileSrc?: string;
height?: number;
imageCacheTag?: string;
size?: 'expand' | 'large' | 'medium' | 'none' | 'small';
uploadConfig?: SanitizedCollectionConfig['upload'];
width?: number;
};
export declare const Thumbnail: React.FC<ThumbnailProps>;
type ThumbnailComponentProps = {
readonly alt?: string;
readonly className?: string;
readonly filename: string;
readonly fileSrc: string;
readonly imageCacheTag?: string;
readonly size?: 'expand' | 'large' | 'medium' | 'none' | 'small';
};
export declare function ThumbnailComponent(props: ThumbnailComponentProps): React.JSX.Element;
export {};
//# sourceMappingURL=index.d.ts.map

View File

@@ -0,0 +1,9 @@
import type { Action, State } from './types.js';
export declare const defaultLoadingOverlayState: {
isLoading: boolean;
loaders: any[];
loadingText: string;
overlayType: any;
};
export declare const reducer: (state: State, action: Action) => State;
//# sourceMappingURL=reducer.d.ts.map

View File

@@ -0,0 +1,25 @@
export const getSafeRedirect = ({ allowAbsoluteUrls = false, fallbackTo = '/', redirectTo })=>{
if (typeof redirectTo !== 'string') {
return fallbackTo;
}
// Normalize and decode the path
let redirectPath;
try {
redirectPath = decodeURIComponent(redirectTo.trim());
} catch {
return fallbackTo // invalid encoding
;
}
const isSafeRedirect = // Must start with a single forward slash (e.g., "/admin")
redirectPath.startsWith('/') && // Prevent protocol-relative URLs (e.g., "//example.com")
!redirectPath.startsWith('//') && // Prevent encoded slashes that could resolve to protocol-relative
!redirectPath.startsWith('/%2F') && // Prevent backslash-based escape attempts (e.g., "/\\/example.com", "/\\\\example.com", "/\\example.com")
!redirectPath.startsWith('/\\/') && !redirectPath.startsWith('/\\\\') && !redirectPath.startsWith('/\\') && // Prevent javascript-based schemes (e.g., "/javascript:alert(1)")
!redirectPath.toLowerCase().startsWith('/javascript:') && // Prevent attempts to redirect to full URLs using "/http:" or "/https:"
!redirectPath.toLowerCase().startsWith('/http');
const isAbsoluteSafeRedirect = allowAbsoluteUrls && // Must be a valid absolute URL with http or https
/^https?:\/\/\S+$/i.test(redirectPath);
return isSafeRedirect || isAbsoluteSafeRedirect ? redirectPath : fallbackTo;
};
//# sourceMappingURL=getSafeRedirect.js.map

View File

@@ -0,0 +1 @@
{"version":3,"file":"third-party-errors-filter.d.ts","sourceRoot":"","sources":["../../../src/integrations/third-party-errors-filter.ts"],"names":[],"mappings":"AAQA,UAAU,OAAO;IACf;;;;;;;OAOG;IACH,UAAU,EAAE,MAAM,EAAE,CAAC;IAErB;;;;;;;;;;OAUG;IACH,SAAS,EACL,2CAA2C,GAC3C,uDAAuD,GACvD,0CAA0C,GAC1C,sDAAsD,CAAC;IAE3D;;;;OAIG;IACH,0BAA0B,CAAC,EAAE,OAAO,CAAC;CACtC;AAED;;GAEG;AACH,eAAO,MAAM,gCAAgC,gDA2D3C,CAAC"}

View File

@@ -0,0 +1 @@
{"version":3,"file":"reactrouterv6.js","sources":["../../src/reactrouterv6.tsx"],"sourcesContent":["import type { browserTracingIntegration } from '@sentry/browser';\nimport type { Integration } from '@sentry/core';\nimport type { ReactRouterOptions } from './reactrouter-compat-utils';\nimport {\n createReactRouterV6CompatibleTracingIntegration,\n createV6CompatibleWithSentryReactRouterRouting,\n createV6CompatibleWrapCreateBrowserRouter,\n createV6CompatibleWrapCreateMemoryRouter,\n createV6CompatibleWrapUseRoutes,\n} from './reactrouter-compat-utils';\nimport type { CreateRouterFunction, Router, RouterState, UseRoutes } from './types';\n\n/**\n * A browser tracing integration that uses React Router v6 to instrument navigations.\n * Expects `useEffect`, `useLocation`, `useNavigationType`, `createRoutesFromChildren` and `matchRoutes` to be passed as options.\n */\nexport function reactRouterV6BrowserTracingIntegration(\n options: Parameters<typeof browserTracingIntegration>[0] & ReactRouterOptions,\n): Integration {\n return createReactRouterV6CompatibleTracingIntegration(options, '6');\n}\n\n/**\n * A wrapper function that adds Sentry routing instrumentation to a React Router v6 useRoutes hook.\n * This is used to automatically capture route changes as transactions when using the useRoutes hook.\n */\nexport function wrapUseRoutesV6(origUseRoutes: UseRoutes): UseRoutes {\n return createV6CompatibleWrapUseRoutes(origUseRoutes, '6');\n}\n\n/**\n * A wrapper function that adds Sentry routing instrumentation to a React Router v6 createBrowserRouter function.\n * This is used to automatically capture route changes as transactions when using the createBrowserRouter API.\n */\nexport function wrapCreateBrowserRouterV6<\n TState extends RouterState = RouterState,\n TRouter extends Router<TState> = Router<TState>,\n>(createRouterFunction: CreateRouterFunction<TState, TRouter>): CreateRouterFunction<TState, TRouter> {\n return createV6CompatibleWrapCreateBrowserRouter(createRouterFunction, '6');\n}\n\n/**\n * A wrapper function that adds Sentry routing instrumentation to a React Router v6 createMemoryRouter function.\n * This is used to automatically capture route changes as transactions when using the createMemoryRouter API.\n * The difference between createBrowserRouter and createMemoryRouter is that with createMemoryRouter,\n * optional `initialEntries` are also taken into account.\n */\nexport function wrapCreateMemoryRouterV6<\n TState extends RouterState = RouterState,\n TRouter extends Router<TState> = Router<TState>,\n>(createMemoryRouterFunction: CreateRouterFunction<TState, TRouter>): CreateRouterFunction<TState, TRouter> {\n return createV6CompatibleWrapCreateMemoryRouter(createMemoryRouterFunction, '6');\n}\n\n/**\n * A higher-order component that adds Sentry routing instrumentation to a React Router v6 Route component.\n * This is used to automatically capture route changes as transactions.\n */\n// eslint-disable-next-line @typescript-eslint/no-explicit-any\nexport function withSentryReactRouterV6Routing<P extends Record<string, any>, R extends React.FC<P>>(routes: R): R {\n return createV6CompatibleWithSentryReactRouterRouting<P, R>(routes, '6');\n}\n"],"names":[],"mappings":";;;;AAYA;AACA;AACA;AACA;AACO,SAAS,sCAAsC;AACtD,EAAE,OAAO;AACT,EAAe;AACf,EAAE,OAAO,+CAA+C,CAAC,OAAO,EAAE,GAAG,CAAC;AACtE;;AAEA;AACA;AACA;AACA;AACO,SAAS,eAAe,CAAC,aAAa,EAAwB;AACrE,EAAE,OAAO,+BAA+B,CAAC,aAAa,EAAE,GAAG,CAAC;AAC5D;;AAEA;AACA;AACA;AACA;AACO,SAAS;;AAGhB,CAAE,oBAAoB,EAAgF;AACtG,EAAE,OAAO,yCAAyC,CAAC,oBAAoB,EAAE,GAAG,CAAC;AAC7E;;AAEA;AACA;AACA;AACA;AACA;AACA;AACO,SAAS;;AAGhB,CAAE,0BAA0B,EAAgF;AAC5G,EAAE,OAAO,wCAAwC,CAAC,0BAA0B,EAAE,GAAG,CAAC;AAClF;;AAEA;AACA;AACA;AACA;AACA;AACO,SAAS,8BAA8B,CAAuD,MAAM,EAAQ;AACnH,EAAE,OAAO,8CAA8C,CAAO,MAAM,EAAE,GAAG,CAAC;AAC1E;;;;"}

View File

@@ -0,0 +1,82 @@
(function (Prism) {
var codeLinePattern = /(^(?:[\t ]*(?:\*\s*)*))[^*\s].*$/m;
var memberReference = /#\s*\w+(?:\s*\([^()]*\))?/.source;
var reference = /(?:\b[a-zA-Z]\w+\s*\.\s*)*\b[A-Z]\w*(?:\s*<mem>)?|<mem>/.source.replace(/<mem>/g, function () { return memberReference; });
Prism.languages.javadoc = Prism.languages.extend('javadoclike', {});
Prism.languages.insertBefore('javadoc', 'keyword', {
'reference': {
pattern: RegExp(/(@(?:exception|link|linkplain|see|throws|value)\s+(?:\*\s*)?)/.source + '(?:' + reference + ')'),
lookbehind: true,
inside: {
'function': {
pattern: /(#\s*)\w+(?=\s*\()/,
lookbehind: true
},
'field': {
pattern: /(#\s*)\w+/,
lookbehind: true
},
'namespace': {
pattern: /\b(?:[a-z]\w*\s*\.\s*)+/,
inside: {
'punctuation': /\./
}
},
'class-name': /\b[A-Z]\w*/,
'keyword': Prism.languages.java.keyword,
'punctuation': /[#()[\],.]/
}
},
'class-name': {
// @param <T> the first generic type parameter
pattern: /(@param\s+)<[A-Z]\w*>/,
lookbehind: true,
inside: {
'punctuation': /[.<>]/
}
},
'code-section': [
{
pattern: /(\{@code\s+(?!\s))(?:[^\s{}]|\s+(?![\s}])|\{(?:[^{}]|\{(?:[^{}]|\{(?:[^{}]|\{[^{}]*\})*\})*\})*\})+(?=\s*\})/,
lookbehind: true,
inside: {
'code': {
// there can't be any HTML inside of {@code} tags
pattern: codeLinePattern,
lookbehind: true,
inside: Prism.languages.java,
alias: 'language-java'
}
}
},
{
pattern: /(<(code|pre|tt)>(?!<code>)\s*)\S(?:\S|\s+\S)*?(?=\s*<\/\2>)/,
lookbehind: true,
inside: {
'line': {
pattern: codeLinePattern,
lookbehind: true,
inside: {
// highlight HTML tags and entities
'tag': Prism.languages.markup.tag,
'entity': Prism.languages.markup.entity,
'code': {
// everything else is Java code
pattern: /.+/,
inside: Prism.languages.java,
alias: 'language-java'
}
}
}
}
}
],
'tag': Prism.languages.markup.tag,
'entity': Prism.languages.markup.entity,
});
Prism.languages.javadoclike.addSupport('java', Prism.languages.javadoc);
}(Prism));

View File

@@ -0,0 +1,12 @@
import type { Collection, CollectionSlug, DataFromCollectionSlug, PayloadRequest } from 'payload';
export type Resolver<TData> = (_: unknown, args: {
data: TData;
draft: boolean;
fallbackLocale?: string;
id: string;
locale?: string;
}, context: {
req: PayloadRequest;
}) => Promise<TData>;
export declare function duplicateResolver<TSlug extends CollectionSlug>(collection: Collection): Resolver<DataFromCollectionSlug<TSlug>>;
//# sourceMappingURL=duplicate.d.ts.map

View File

@@ -0,0 +1,58 @@
{
"name": "pg-types",
"version": "4.1.0",
"description": "Query result type converters for node-postgres",
"main": "index.js",
"scripts": {
"coverage": "nyc --reporter=html npm test && open-cli coverage/index.html",
"coverage-ci": "nyc --reporter=lcov npm test && codecov",
"generate": "docker compose --project-directory generator run --rm generator",
"lint": "standard",
"test": "npm run test-js && npm run test-ts && npm run lint",
"test-js": "tape test/*.js | tap-spec",
"test-ts": "tsd"
},
"repository": {
"type": "git",
"url": "git://github.com/brianc/node-pg-types.git"
},
"keywords": [
"postgres",
"PostgreSQL",
"pg"
],
"author": "Brian M. Carlson",
"license": "MIT",
"bugs": {
"url": "https://github.com/brianc/node-pg-types/issues"
},
"homepage": "https://github.com/brianc/node-pg-types",
"devDependencies": {
"@types/node": "^14.14.33",
"codecov": "^3.8.1",
"nyc": "^15.1.0",
"open-cli": "^6.0.1",
"pg": "^8.11.3",
"standard": "^16.0.3",
"tap-spec": "^5.0.0",
"tape": "^5.2.2",
"tsd": "^0.14.0"
},
"dependencies": {
"pg-int8": "1.0.1",
"pg-numeric": "1.0.2",
"postgres-array": "~3.0.1",
"postgres-bytea": "~3.0.0",
"postgres-date": "~2.1.0",
"postgres-interval": "^3.0.0",
"postgres-range": "^1.1.1"
},
"files": [
"index.js",
"index.d.ts",
"lib"
],
"engines": {
"node": ">=10"
}
}

View File

@@ -0,0 +1,25 @@
'use strict';
var common = require('./common');
var EventEmitter = require('../');
var assert = require('assert');
var ee = new EventEmitter();
var foo = Symbol('foo');
var listener = common.mustCall();
ee.on(foo, listener);
assert.strictEqual(ee.listeners(foo).length, 1);
assert.strictEqual(ee.listeners(foo)[0], listener);
ee.emit(foo);
ee.removeAllListeners();
assert.strictEqual(ee.listeners(foo).length, 0);
ee.on(foo, listener);
assert.strictEqual(ee.listeners(foo).length, 1);
assert.strictEqual(ee.listeners(foo)[0], listener);
ee.removeListener(foo, listener);
assert.strictEqual(ee.listeners(foo).length, 0);

View File

@@ -0,0 +1,28 @@
import { formatDistance } from "./hy/_lib/formatDistance.js";
import { formatLong } from "./hy/_lib/formatLong.js";
import { formatRelative } from "./hy/_lib/formatRelative.js";
import { localize } from "./hy/_lib/localize.js";
import { match } from "./hy/_lib/match.js";
/**
* @category Locales
* @summary Armenian locale
* @language Armenian
* @iso-639-2 arm
* @author Alex Igityan [@alexigityan](https://github.com/alexigityan)
*/
export const hy = {
code: "hy",
formatDistance: formatDistance,
formatLong: formatLong,
formatRelative: formatRelative,
localize: localize,
match: match,
options: {
weekStartsOn: 1 /* Monday */,
firstWeekContainsDate: 1,
},
};
// Fallback for modularized imports:
export default hy;

View File

@@ -0,0 +1,71 @@
"use strict";
var __defProp = Object.defineProperty;
var __getOwnPropDesc = Object.getOwnPropertyDescriptor;
var __getOwnPropNames = Object.getOwnPropertyNames;
var __hasOwnProp = Object.prototype.hasOwnProperty;
var __export = (target, all) => {
for (var name in all)
__defProp(target, name, { get: all[name], enumerable: true });
};
var __copyProps = (to, from, except, desc) => {
if (from && typeof from === "object" || typeof from === "function") {
for (let key of __getOwnPropNames(from))
if (!__hasOwnProp.call(to, key) && key !== except)
__defProp(to, key, { get: () => from[key], enumerable: !(desc = __getOwnPropDesc(from, key)) || desc.enumerable });
}
return to;
};
var __toCommonJS = (mod) => __copyProps(__defProp({}, "__esModule", { value: true }), mod);
var driver_exports = {};
__export(driver_exports, {
DrizzleD1Database: () => DrizzleD1Database,
drizzle: () => drizzle
});
module.exports = __toCommonJS(driver_exports);
var import_entity = require("../entity.cjs");
var import_logger = require("../logger.cjs");
var import_relations = require("../relations.cjs");
var import_db = require("../sqlite-core/db.cjs");
var import_dialect = require("../sqlite-core/dialect.cjs");
var import_session = require("./session.cjs");
class DrizzleD1Database extends import_db.BaseSQLiteDatabase {
static [import_entity.entityKind] = "D1Database";
async batch(batch) {
return this.session.batch(batch);
}
}
function drizzle(client, config = {}) {
const dialect = new import_dialect.SQLiteAsyncDialect({ casing: config.casing });
let logger;
if (config.logger === true) {
logger = new import_logger.DefaultLogger();
} else if (config.logger !== false) {
logger = config.logger;
}
let schema;
if (config.schema) {
const tablesConfig = (0, import_relations.extractTablesRelationalConfig)(
config.schema,
import_relations.createTableRelationsHelpers
);
schema = {
fullSchema: config.schema,
schema: tablesConfig.tables,
tableNamesMap: tablesConfig.tableNamesMap
};
}
const session = new import_session.SQLiteD1Session(client, dialect, schema, { logger, cache: config.cache });
const db = new DrizzleD1Database("async", dialect, session, schema);
db.$client = client;
db.$cache = config.cache;
if (db.$cache) {
db.$cache["invalidate"] = config.cache?.onMutate;
}
return db;
}
// Annotate the CommonJS export names for ESM import in node:
0 && (module.exports = {
DrizzleD1Database,
drizzle
});
//# sourceMappingURL=driver.cjs.map

View File

@@ -0,0 +1,6 @@
import React from 'react';
import './index.scss';
export declare const DragHandleIcon: React.FC<{
className?: string;
}>;
//# sourceMappingURL=index.d.ts.map

View File

@@ -0,0 +1,301 @@
import { WHITE_SPACE_REGEX } from "./regex.generated.js";
export function parseNumberSkeletonFromString(skeleton) {
if (skeleton.length === 0) {
throw new Error("Number skeleton cannot be empty");
}
// Parse the skeleton
const stringTokens = skeleton.split(WHITE_SPACE_REGEX).filter((x) => x.length > 0);
const tokens = [];
for (const stringToken of stringTokens) {
let stemAndOptions = stringToken.split("/");
if (stemAndOptions.length === 0) {
throw new Error("Invalid number skeleton");
}
const [stem, ...options] = stemAndOptions;
for (const option of options) {
if (option.length === 0) {
throw new Error("Invalid number skeleton");
}
}
tokens.push({
stem,
options
});
}
return tokens;
}
function icuUnitToEcma(unit) {
return unit.replace(/^(.*?)-/, "");
}
const FRACTION_PRECISION_REGEX = /^\.(?:(0+)(\*)?|(#+)|(0+)(#+))$/g;
const SIGNIFICANT_PRECISION_REGEX = /^(@+)?(\+|#+)?[rs]?$/g;
const INTEGER_WIDTH_REGEX = /(\*)(0+)|(#+)(0+)|(0+)/g;
const CONCISE_INTEGER_WIDTH_REGEX = /^(0+)$/;
function parseSignificantPrecision(str) {
const result = {};
if (str[str.length - 1] === "r") {
result.roundingPriority = "morePrecision";
} else if (str[str.length - 1] === "s") {
result.roundingPriority = "lessPrecision";
}
str.replace(SIGNIFICANT_PRECISION_REGEX, function(_, g1, g2) {
// @@@ case
if (typeof g2 !== "string") {
result.minimumSignificantDigits = g1.length;
result.maximumSignificantDigits = g1.length;
} else if (g2 === "+") {
result.minimumSignificantDigits = g1.length;
} else if (g1[0] === "#") {
result.maximumSignificantDigits = g1.length;
} else {
result.minimumSignificantDigits = g1.length;
result.maximumSignificantDigits = g1.length + (typeof g2 === "string" ? g2.length : 0);
}
return "";
});
return result;
}
function parseSign(str) {
switch (str) {
case "sign-auto": return { signDisplay: "auto" };
case "sign-accounting":
case "()": return { currencySign: "accounting" };
case "sign-always":
case "+!": return { signDisplay: "always" };
case "sign-accounting-always":
case "()!": return {
signDisplay: "always",
currencySign: "accounting"
};
case "sign-except-zero":
case "+?": return { signDisplay: "exceptZero" };
case "sign-accounting-except-zero":
case "()?": return {
signDisplay: "exceptZero",
currencySign: "accounting"
};
case "sign-never":
case "+_": return { signDisplay: "never" };
}
}
function parseConciseScientificAndEngineeringStem(stem) {
// Engineering
let result;
if (stem[0] === "E" && stem[1] === "E") {
result = { notation: "engineering" };
stem = stem.slice(2);
} else if (stem[0] === "E") {
result = { notation: "scientific" };
stem = stem.slice(1);
}
if (result) {
const signDisplay = stem.slice(0, 2);
if (signDisplay === "+!") {
result.signDisplay = "always";
stem = stem.slice(2);
} else if (signDisplay === "+?") {
result.signDisplay = "exceptZero";
stem = stem.slice(2);
}
if (!CONCISE_INTEGER_WIDTH_REGEX.test(stem)) {
throw new Error("Malformed concise eng/scientific notation");
}
result.minimumIntegerDigits = stem.length;
}
return result;
}
function parseNotationOptions(opt) {
const result = {};
const signOpts = parseSign(opt);
if (signOpts) {
return signOpts;
}
return result;
}
/**
* https://github.com/unicode-org/icu/blob/master/docs/userguide/format_parse/numbers/skeletons.md#skeleton-stems-and-options
*/
export function parseNumberSkeleton(tokens) {
let result = {};
for (const token of tokens) {
switch (token.stem) {
case "percent":
case "%":
result.style = "percent";
continue;
case "%x100":
result.style = "percent";
result.scale = 100;
continue;
case "currency":
result.style = "currency";
result.currency = token.options[0];
continue;
case "group-off":
case ",_":
result.useGrouping = false;
continue;
case "precision-integer":
case ".":
result.maximumFractionDigits = 0;
continue;
case "measure-unit":
case "unit":
result.style = "unit";
result.unit = icuUnitToEcma(token.options[0]);
continue;
case "compact-short":
case "K":
result.notation = "compact";
result.compactDisplay = "short";
continue;
case "compact-long":
case "KK":
result.notation = "compact";
result.compactDisplay = "long";
continue;
case "scientific":
result = {
...result,
notation: "scientific",
...token.options.reduce((all, opt) => ({
...all,
...parseNotationOptions(opt)
}), {})
};
continue;
case "engineering":
result = {
...result,
notation: "engineering",
...token.options.reduce((all, opt) => ({
...all,
...parseNotationOptions(opt)
}), {})
};
continue;
case "notation-simple":
result.notation = "standard";
continue;
case "unit-width-narrow":
result.currencyDisplay = "narrowSymbol";
result.unitDisplay = "narrow";
continue;
case "unit-width-short":
result.currencyDisplay = "code";
result.unitDisplay = "short";
continue;
case "unit-width-full-name":
result.currencyDisplay = "name";
result.unitDisplay = "long";
continue;
case "unit-width-iso-code":
result.currencyDisplay = "symbol";
continue;
case "scale":
result.scale = parseFloat(token.options[0]);
continue;
case "rounding-mode-floor":
result.roundingMode = "floor";
continue;
case "rounding-mode-ceiling":
result.roundingMode = "ceil";
continue;
case "rounding-mode-down":
result.roundingMode = "trunc";
continue;
case "rounding-mode-up":
result.roundingMode = "expand";
continue;
case "rounding-mode-half-even":
result.roundingMode = "halfEven";
continue;
case "rounding-mode-half-down":
result.roundingMode = "halfTrunc";
continue;
case "rounding-mode-half-up":
result.roundingMode = "halfExpand";
continue;
case "integer-width":
if (token.options.length > 1) {
throw new RangeError("integer-width stems only accept a single optional option");
}
token.options[0].replace(INTEGER_WIDTH_REGEX, function(_, g1, g2, g3, g4, g5) {
if (g1) {
result.minimumIntegerDigits = g2.length;
} else if (g3 && g4) {
throw new Error("We currently do not support maximum integer digits");
} else if (g5) {
throw new Error("We currently do not support exact integer digits");
}
return "";
});
continue;
}
// https://unicode-org.github.io/icu/userguide/format_parse/numbers/skeletons.html#integer-width
if (CONCISE_INTEGER_WIDTH_REGEX.test(token.stem)) {
result.minimumIntegerDigits = token.stem.length;
continue;
}
if (FRACTION_PRECISION_REGEX.test(token.stem)) {
// Precision
// https://unicode-org.github.io/icu/userguide/format_parse/numbers/skeletons.html#fraction-precision
// precision-integer case
if (token.options.length > 1) {
throw new RangeError("Fraction-precision stems only accept a single optional option");
}
token.stem.replace(FRACTION_PRECISION_REGEX, function(_, g1, g2, g3, g4, g5) {
// .000* case (before ICU67 it was .000+)
if (g2 === "*") {
result.minimumFractionDigits = g1.length;
} else if (g3 && g3[0] === "#") {
result.maximumFractionDigits = g3.length;
} else if (g4 && g5) {
result.minimumFractionDigits = g4.length;
result.maximumFractionDigits = g4.length + g5.length;
} else {
result.minimumFractionDigits = g1.length;
result.maximumFractionDigits = g1.length;
}
return "";
});
const opt = token.options[0];
// https://unicode-org.github.io/icu/userguide/format_parse/numbers/skeletons.html#trailing-zero-display
if (opt === "w") {
result = {
...result,
trailingZeroDisplay: "stripIfInteger"
};
} else if (opt) {
result = {
...result,
...parseSignificantPrecision(opt)
};
}
continue;
}
// https://unicode-org.github.io/icu/userguide/format_parse/numbers/skeletons.html#significant-digits-precision
if (SIGNIFICANT_PRECISION_REGEX.test(token.stem)) {
result = {
...result,
...parseSignificantPrecision(token.stem)
};
continue;
}
const signOpts = parseSign(token.stem);
if (signOpts) {
result = {
...result,
...signOpts
};
}
const conciseScientificAndEngineeringOpts = parseConciseScientificAndEngineeringStem(token.stem);
if (conciseScientificAndEngineeringOpts) {
result = {
...result,
...conciseScientificAndEngineeringOpts
};
}
}
return result;
}

View File

@@ -0,0 +1 @@
{"version":3,"file":"cooking-pot.js","sources":["../../../src/icons/cooking-pot.ts"],"sourcesContent":["import createLucideIcon from '../createLucideIcon';\n\n/**\n * @component @name CookingPot\n * @description Lucide SVG icon component, renders SVG Element with children.\n *\n * @preview ![img](data:image/svg+xml;base64,PHN2ZyAgeG1sbnM9Imh0dHA6Ly93d3cudzMub3JnLzIwMDAvc3ZnIgogIHdpZHRoPSIyNCIKICBoZWlnaHQ9IjI0IgogIHZpZXdCb3g9IjAgMCAyNCAyNCIKICBmaWxsPSJub25lIgogIHN0cm9rZT0iIzAwMCIgc3R5bGU9ImJhY2tncm91bmQtY29sb3I6ICNmZmY7IGJvcmRlci1yYWRpdXM6IDJweCIKICBzdHJva2Utd2lkdGg9IjIiCiAgc3Ryb2tlLWxpbmVjYXA9InJvdW5kIgogIHN0cm9rZS1saW5lam9pbj0icm91bmQiCj4KICA8cGF0aCBkPSJNMiAxMmgyMCIgLz4KICA8cGF0aCBkPSJNMjAgMTJ2OGEyIDIgMCAwIDEtMiAySDZhMiAyIDAgMCAxLTItMnYtOCIgLz4KICA8cGF0aCBkPSJtNCA4IDE2LTQiIC8+CiAgPHBhdGggZD0ibTguODYgNi43OC0uNDUtMS44MWEyIDIgMCAwIDEgMS40NS0yLjQzbDEuOTQtLjQ4YTIgMiAwIDAgMSAyLjQzIDEuNDZsLjQ1IDEuOCIgLz4KPC9zdmc+Cg==) - https://lucide.dev/icons/cooking-pot\n * @see https://lucide.dev/guide/packages/lucide-react - Documentation\n *\n * @param {Object} props - Lucide icons props and any valid SVG attribute\n * @returns {JSX.Element} JSX Element\n *\n */\nconst CookingPot = createLucideIcon('CookingPot', [\n ['path', { d: 'M2 12h20', key: '9i4pu4' }],\n ['path', { d: 'M20 12v8a2 2 0 0 1-2 2H6a2 2 0 0 1-2-2v-8', key: 'u0tga0' }],\n ['path', { d: 'm4 8 16-4', key: '16g0ng' }],\n [\n 'path',\n {\n d: 'm8.86 6.78-.45-1.81a2 2 0 0 1 1.45-2.43l1.94-.48a2 2 0 0 1 2.43 1.46l.45 1.8',\n key: '12cejc',\n },\n ],\n]);\n\nexport default CookingPot;\n"],"names":[],"mappings":";;;;;;;;;AAaM,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAa,iBAAiB,YAAc,CAAA,CAAA,CAAA;AAAA,CAAA,CAChD,CAAC,CAAA,CAAA,CAAA,CAAA,CAAA,CAAQ,CAAA,CAAA,CAAA,CAAE,GAAG,CAAY,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAK,UAAU,CAAA,CAAA;AAAA,CAAA,CACzC,CAAC,CAAA,CAAA,CAAA,CAAA,CAAA,CAAQ,CAAA,CAAA,CAAA,CAAE,GAAG,CAA6C,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAK,UAAU,CAAA,CAAA;AAAA,CAAA,CAC1E,CAAC,CAAA,CAAA,CAAA,CAAA,CAAA,CAAQ,CAAA,CAAA,CAAA,CAAE,GAAG,CAAa,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAK,UAAU,CAAA,CAAA;AAAA,CAC1C,CAAA,CAAA;AAAA,CAAA,CAAA,CAAA,CACE,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA;AAAA,CACA,CAAA,CAAA,CAAA,CAAA;AAAA,CACE,CAAA,CAAA,CAAA,CAAA,CAAA,CAAG,EAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA;AAAA,CACH,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAK,EAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA;AAAA,CACP,CAAA,CAAA,CAAA,CAAA;AAAA,CACF,CAAA,CAAA;AACF,CAAC,CAAA,CAAA;;"}

View File

@@ -0,0 +1 @@
{"version":3,"names":["_gensync","data","require","_index","_index2","fs","transformFileRunner","gensync","filename","opts","options","Object","assign","config","loadConfig","code","readFile","run","transformFile","args","errback","transformFileSync","sync","transformFileAsync","async"],"sources":["../src/transform-file.ts"],"sourcesContent":["import gensync, { type Handler } from \"gensync\";\n\nimport loadConfig from \"./config/index.ts\";\nimport type { InputOptions, ResolvedConfig } from \"./config/index.ts\";\nimport { run } from \"./transformation/index.ts\";\nimport type { FileResult, FileResultCallback } from \"./transformation/index.ts\";\nimport * as fs from \"./gensync-utils/fs.ts\";\n\ntype transformFileBrowserType = typeof import(\"./transform-file-browser\");\ntype transformFileType = typeof import(\"./transform-file\");\n\n// Kind of gross, but essentially asserting that the exports of this module are the same as the\n// exports of transform-file-browser, since this file may be replaced at bundle time with\n// transform-file-browser.\n// eslint-disable-next-line @typescript-eslint/no-unused-expressions\n({}) as any as transformFileBrowserType as transformFileType;\n\nconst transformFileRunner = gensync(function* (\n filename: string,\n opts?: InputOptions,\n): Handler<FileResult | null> {\n const options = { ...opts, filename };\n\n const config: ResolvedConfig | null = yield* loadConfig(options);\n if (config === null) return null;\n\n const code = yield* fs.readFile(filename, \"utf8\");\n return yield* run(config, code);\n});\n\n// @ts-expect-error TS doesn't detect that this signature is compatible\nexport function transformFile(\n filename: string,\n callback: FileResultCallback,\n): void;\nexport function transformFile(\n filename: string,\n opts: InputOptions | undefined | null,\n callback: FileResultCallback,\n): void;\nexport function transformFile(\n ...args: Parameters<typeof transformFileRunner.errback>\n) {\n transformFileRunner.errback(...args);\n}\n\nexport function transformFileSync(\n ...args: Parameters<typeof transformFileRunner.sync>\n) {\n return transformFileRunner.sync(...args);\n}\nexport function transformFileAsync(\n ...args: Parameters<typeof transformFileRunner.async>\n) {\n return transformFileRunner.async(...args);\n}\n"],"mappings":";;;;;;;;AAAA,SAAAA,SAAA;EAAA,MAAAC,IAAA,GAAAC,OAAA;EAAAF,QAAA,YAAAA,CAAA;IAAA,OAAAC,IAAA;EAAA;EAAA,OAAAA,IAAA;AAAA;AAEA,IAAAE,MAAA,GAAAD,OAAA;AAEA,IAAAE,OAAA,GAAAF,OAAA;AAEA,IAAAG,EAAA,GAAAH,OAAA;AASA,CAAC,CAAC,CAAC;AAEH,MAAMI,mBAAmB,GAAGC,SAAMA,CAAC,CAAC,WAClCC,QAAgB,EAChBC,IAAmB,EACS;EAC5B,MAAMC,OAAO,GAAAC,MAAA,CAAAC,MAAA,KAAQH,IAAI;IAAED;EAAQ,EAAE;EAErC,MAAMK,MAA6B,GAAG,OAAO,IAAAC,cAAU,EAACJ,OAAO,CAAC;EAChE,IAAIG,MAAM,KAAK,IAAI,EAAE,OAAO,IAAI;EAEhC,MAAME,IAAI,GAAG,OAAOV,EAAE,CAACW,QAAQ,CAACR,QAAQ,EAAE,MAAM,CAAC;EACjD,OAAO,OAAO,IAAAS,WAAG,EAACJ,MAAM,EAAEE,IAAI,CAAC;AACjC,CAAC,CAAC;AAYK,SAASG,aAAaA,CAC3B,GAAGC,IAAoD,EACvD;EACAb,mBAAmB,CAACc,OAAO,CAAC,GAAGD,IAAI,CAAC;AACtC;AAEO,SAASE,iBAAiBA,CAC/B,GAAGF,IAAiD,EACpD;EACA,OAAOb,mBAAmB,CAACgB,IAAI,CAAC,GAAGH,IAAI,CAAC;AAC1C;AACO,SAASI,kBAAkBA,CAChC,GAAGJ,IAAkD,EACrD;EACA,OAAOb,mBAAmB,CAACkB,KAAK,CAAC,GAAGL,IAAI,CAAC;AAC3C;AAAC","ignoreList":[]}

View File

@@ -0,0 +1,6 @@
var root = require('./_root');
/** Used to detect overreaching core-js shims. */
var coreJsData = root['__core-js_shared__'];
module.exports = coreJsData;

View File

@@ -0,0 +1,113 @@
import { Scope } from '../scope';
import { Metric } from '../types-hoist/metric';
/**
* Options for capturing a metric.
*/
export interface MetricOptions {
/**
* The unit of the metric value.
*/
unit?: string;
/**
* Arbitrary structured data that stores information about the metric.
*/
attributes?: Metric['attributes'];
/**
* The scope to capture the metric with.
*/
scope?: Scope;
}
/**
* @summary Increment a counter metric.
*
* @param name - The name of the counter metric.
* @param value - The value to increment by (defaults to 1).
* @param options - Options for capturing the metric.
*
* @example
*
* ```
* Sentry.metrics.count('api.requests', 1, {
* attributes: {
* endpoint: '/api/users',
* method: 'GET',
* status: 200
* }
* });
* ```
*
* @example With custom value
*
* ```
* Sentry.metrics.count('items.processed', 5, {
* attributes: {
* processor: 'batch-processor',
* queue: 'high-priority'
* }
* });
* ```
*/
export declare function count(name: string, value?: number, options?: MetricOptions): void;
/**
* @summary Set a gauge metric to a specific value.
*
* @param name - The name of the gauge metric.
* @param value - The current value of the gauge.
* @param options - Options for capturing the metric.
*
* @example
*
* ```
* Sentry.metrics.gauge('memory.usage', 1024, {
* unit: 'megabyte',
* attributes: {
* process: 'web-server',
* region: 'us-east-1'
* }
* });
* ```
*
* @example Without unit
*
* ```
* Sentry.metrics.gauge('active.connections', 42, {
* attributes: {
* server: 'api-1',
* protocol: 'websocket'
* }
* });
* ```
*/
export declare function gauge(name: string, value: number, options?: MetricOptions): void;
/**
* @summary Record a value in a distribution metric.
*
* @param name - The name of the distribution metric.
* @param value - The value to record in the distribution.
* @param options - Options for capturing the metric.
*
* @example
*
* ```
* Sentry.metrics.distribution('task.duration', 500, {
* unit: 'millisecond',
* attributes: {
* task: 'data-processing',
* priority: 'high'
* }
* });
* ```
*
* @example Without unit
*
* ```
* Sentry.metrics.distribution('batch.size', 100, {
* attributes: {
* processor: 'batch-1',
* type: 'async'
* }
* });
* ```
*/
export declare function distribution(name: string, value: number, options?: MetricOptions): void;
//# sourceMappingURL=public-api.d.ts.map

View File

@@ -0,0 +1,4 @@
import type { RelationshipFieldServerProps } from 'payload';
import './index.scss';
export declare const FolderField: (props: RelationshipFieldServerProps) => import("react").JSX.Element;
//# sourceMappingURL=index.server.d.ts.map

View File

@@ -0,0 +1,2 @@
import "./emotion-react-_isolated-hnrs.development.edge-light.cjs.js";
export { _default as default } from "./emotion-react-_isolated-hnrs.development.edge-light.cjs.default.js";

View File

@@ -0,0 +1,18 @@
type SpotlightConnectionOptions = {
/**
* Set this if the Spotlight Sidecar is not running on localhost:8969
* By default, the Url is set to http://localhost:8969/stream
*/
sidecarUrl?: string;
};
export declare const INTEGRATION_NAME = "Spotlight";
/**
* Use this integration to send errors and transactions to Spotlight.
*
* Learn more about spotlight at https://spotlightjs.com
*
* Important: This integration only works with Node 18 or newer.
*/
export declare const spotlightIntegration: (options?: Partial<SpotlightConnectionOptions> | undefined) => import("@sentry/core").Integration;
export {};
//# sourceMappingURL=spotlight.d.ts.map

View File

@@ -0,0 +1,57 @@
/**
* @name parseJSON
* @category Common Helpers
* @summary Parse a JSON date string
*
* @description
* Converts a complete ISO date string in UTC time, the typical format for transmitting
* a date in JSON, to a JavaScript `Date` instance.
*
* This is a minimal implementation for converting dates retrieved from a JSON API to
* a `Date` instance which can be used with other functions in the `date-fns` library.
* The following formats are supported:
*
* - `2000-03-15T05:20:10.123Z`: The output of `.toISOString()` and `JSON.stringify(new Date())`
* - `2000-03-15T05:20:10Z`: Without milliseconds
* - `2000-03-15T05:20:10+00:00`: With a zero offset, the default JSON encoded format in some other languages
* - `2000-03-15T05:20:10+05:45`: With a positive or negative offset, the default JSON encoded format in some other languages
* - `2000-03-15T05:20:10+0000`: With a zero offset without a colon
* - `2000-03-15T05:20:10`: Without a trailing 'Z' symbol
* - `2000-03-15T05:20:10.1234567`: Up to 7 digits in milliseconds field. Only first 3 are taken into account since JS does not allow fractional milliseconds
* - `2000-03-15 05:20:10`: With a space instead of a 'T' separator for APIs returning a SQL date without reformatting
*
* For convenience and ease of use these other input types are also supported
* via [toDate](https://date-fns.org/docs/toDate):
*
* - A `Date` instance will be cloned
* - A `number` will be treated as a timestamp
*
* Any other input type or invalid date strings will return an `Invalid Date`.
*
* @param dateStr - A fully formed ISO8601 date string to convert
*
* @returns The parsed date in the local time zone
*/
export function parseJSON(dateStr) {
const parts = dateStr.match(
/(\d{4})-(\d{2})-(\d{2})[T ](\d{2}):(\d{2}):(\d{2})(?:\.(\d{0,7}))?(?:Z|(.)(\d{2}):?(\d{2})?)?/,
);
if (parts) {
// Group 8 matches the sign
return new Date(
Date.UTC(
+parts[1],
+parts[2] - 1,
+parts[3],
+parts[4] - (+parts[9] || 0) * (parts[8] == "-" ? -1 : 1),
+parts[5] - (+parts[10] || 0) * (parts[8] == "-" ? -1 : 1),
+parts[6],
+((parts[7] || "0") + "00").substring(0, 3),
),
);
}
return new Date(NaN);
}
// Fallback for modularized imports:
export default parseJSON;

View File

@@ -0,0 +1,9 @@
import type { Span } from '../../types-hoist/span';
import type { GoogleGenAIResponse } from './types';
/**
* Instruments an async iterable stream of Google GenAI response chunks, updates the span with
* streaming attributes and (optionally) the aggregated output text, and yields
* each chunk from the input stream unchanged.
*/
export declare function instrumentStream(stream: AsyncIterable<GoogleGenAIResponse>, span: Span, recordOutputs: boolean): AsyncGenerator<GoogleGenAIResponse, void, unknown>;
//# sourceMappingURL=streaming.d.ts.map

View File

@@ -0,0 +1,13 @@
export const indent = (text)=>text.split('\n').map((line)=>` ${line}`).join('\n');
export const getMigrationTemplate = ({ downSQL, imports, packageName, upSQL })=>`import { MigrateUpArgs, MigrateDownArgs, sql } from '${packageName}'
${imports ? `${imports}\n` : ''}
export async function up({ db, payload, req }: MigrateUpArgs): Promise<void> {
${indent(upSQL)}
}
export async function down({ db, payload, req }: MigrateDownArgs): Promise<void> {
${indent(downSQL)}
}
`;
//# sourceMappingURL=getMigrationTemplate.js.map

View File

@@ -0,0 +1,39 @@
/**
* Copyright (c) Meta Platforms, Inc. and affiliates.
*
* This source code is licensed under the MIT license found in the
* LICENSE file in the root directory of this source tree.
*
*/
import type { CommandListenerPriority, LexicalNode } from 'lexical';
import type { JSX } from 'react';
import { MenuOption, MenuRenderFn } from '@lexical/react/LexicalNodeMenuPlugin';
import { LexicalCommand, LexicalEditor } from 'lexical';
export type EmbedMatchResult<TEmbedMatchResult = unknown> = {
url: string;
id: string;
data?: TEmbedMatchResult;
};
export interface EmbedConfig<TEmbedMatchResultData = unknown, TEmbedMatchResult = EmbedMatchResult<TEmbedMatchResultData>> {
type: string;
parseUrl: (text: string) => Promise<TEmbedMatchResult | null> | TEmbedMatchResult | null;
insertNode: (editor: LexicalEditor, result: TEmbedMatchResult) => void;
}
export declare const URL_MATCHER: RegExp;
export declare const INSERT_EMBED_COMMAND: LexicalCommand<EmbedConfig['type']>;
export declare class AutoEmbedOption extends MenuOption {
title: string;
onSelect: (targetNode: LexicalNode | null) => void;
constructor(title: string, options: {
onSelect: (targetNode: LexicalNode | null) => void;
});
}
type LexicalAutoEmbedPluginProps<TEmbedConfig extends EmbedConfig> = {
embedConfigs: Array<TEmbedConfig>;
onOpenEmbedModalForConfig: (embedConfig: TEmbedConfig) => void;
getMenuOptions: (activeEmbedConfig: TEmbedConfig, embedFn: () => void, dismissFn: () => void) => Array<AutoEmbedOption>;
menuRenderFn: MenuRenderFn<AutoEmbedOption>;
menuCommandPriority?: CommandListenerPriority;
};
export declare function LexicalAutoEmbedPlugin<TEmbedConfig extends EmbedConfig>({ embedConfigs, onOpenEmbedModalForConfig, getMenuOptions, menuRenderFn, menuCommandPriority, }: LexicalAutoEmbedPluginProps<TEmbedConfig>): JSX.Element | null;
export {};

View File

@@ -0,0 +1,8 @@
import { QueryComplexity } from './QueryComplexity.js';
export function createComplexityRule(options) {
return (context)=>{
return new QueryComplexity(context, options);
};
}
//# sourceMappingURL=createComplexityRule.js.map

View File

@@ -0,0 +1,120 @@
# readdirp [![Weekly downloads](https://img.shields.io/npm/dw/readdirp.svg)](https://github.com/paulmillr/readdirp)
Recursive version of fs.readdir. Exposes a **stream API** (with small RAM & CPU footprint) and a **promise API**.
```sh
npm install readdirp
jsr add jsr:@paulmillr/readdirp
```
```javascript
// Use streams to achieve small RAM & CPU footprint.
// 1) Streams example with for-await.
import readdirp from 'readdirp';
for await (const entry of readdirp('.')) {
const {path} = entry;
console.log(`${JSON.stringify({path})}`);
}
// 2) Streams example, non for-await.
// Print out all JS files along with their size within the current folder & subfolders.
import readdirp from 'readdirp';
readdirp('.', {alwaysStat: true, fileFilter: (f) => f.basename.endsWith('.js')})
.on('data', (entry) => {
const {path, stats: {size}} = entry;
console.log(`${JSON.stringify({path, size})}`);
})
// Optionally call stream.destroy() in `warn()` in order to abort and cause 'close' to be emitted
.on('warn', error => console.error('non-fatal error', error))
.on('error', error => console.error('fatal error', error))
.on('end', () => console.log('done'));
// 3) Promise example. More RAM and CPU than streams / for-await.
import { readdirpPromise } from 'readdirp';
const files = await readdirpPromise('.');
console.log(files.map(file => file.path));
// Other options.
import readdirp from 'readdirp';
readdirp('test', {
fileFilter: (f) => f.basename.endsWith('.js'),
directoryFilter: (d) => d.basename !== '.git',
// directoryFilter: (di) => di.basename.length === 9
type: 'files_directories',
depth: 1
});
```
## API
`const stream = readdirp(root[, options])` — **Stream API**
- Reads given root recursively and returns a `stream` of [entry infos](#entryinfo)
- Optionally can be used like `for await (const entry of stream)` with node.js 10+ (`asyncIterator`).
- `on('data', (entry) => {})` [entry info](#entryinfo) for every file / dir.
- `on('warn', (error) => {})` non-fatal `Error` that prevents a file / dir from being processed. Example: inaccessible to the user.
- `on('error', (error) => {})` fatal `Error` which also ends the stream. Example: illegal options where passed.
- `on('end')` — we are done. Called when all entries were found and no more will be emitted.
- `on('close')` — stream is destroyed via `stream.destroy()`.
Could be useful if you want to manually abort even on a non fatal error.
At that point the stream is no longer `readable` and no more entries, warning or errors are emitted
- To learn more about streams, consult the very detailed [nodejs streams documentation](https://nodejs.org/api/stream.html)
or the [stream-handbook](https://github.com/substack/stream-handbook)
`const entries = await readdirp.promise(root[, options])` — **Promise API**. Returns a list of [entry infos](#entryinfo).
First argument is awalys `root`, path in which to start reading and recursing into subdirectories.
### options
- `fileFilter`: filter to include or exclude files
- **Function**: a function that takes an entry info as a parameter and returns true to include or false to exclude the entry
- `directoryFilter`: filter to include/exclude directories found and to recurse into. Directories that do not pass a filter will not be recursed into.
- `depth: 5`: depth at which to stop recursing even if more subdirectories are found
- `type: 'files'`: determines if data events on the stream should be emitted for `'files'` (default), `'directories'`, `'files_directories'`, or `'all'`. Setting to `'all'` will also include entries for other types of file descriptors like character devices, unix sockets and named pipes.
- `alwaysStat: false`: always return `stats` property for every file. Default is `false`, readdirp will return `Dirent` entries. Setting it to `true` can double readdir execution time - use it only when you need file `size`, `mtime` etc. Cannot be enabled on node <10.10.0.
- `lstat: false`: include symlink entries in the stream along with files. When `true`, `fs.lstat` would be used instead of `fs.stat`
### `EntryInfo`
Has the following properties:
- `path: 'assets/javascripts/react.js'`: path to the file/directory (relative to given root)
- `fullPath: '/Users/dev/projects/app/assets/javascripts/react.js'`: full path to the file/directory found
- `basename: 'react.js'`: name of the file/directory
- `dirent: fs.Dirent`: built-in [dir entry object](https://nodejs.org/api/fs.html#fs_class_fs_dirent) - only with `alwaysStat: false`
- `stats: fs.Stats`: built in [stat object](https://nodejs.org/api/fs.html#fs_class_fs_stats) - only with `alwaysStat: true`
## Changelog
- 4.0 (Aug 25, 2024) rewritten in typescript, producing hybrid common.js / esm module.
- Remove glob support and all dependencies
- Make sure you're using `let {readdirp} = require('readdirp')` in common.js
- 3.5 (Oct 13, 2020) disallows recursive directory-based symlinks.
Before, it could have entered infinite loop.
- 3.4 (Mar 19, 2020) adds support for directory-based symlinks.
- 3.3 (Dec 6, 2019) stabilizes RAM consumption and enables perf management with `highWaterMark` option. Fixes race conditions related to `for-await` looping.
- 3.2 (Oct 14, 2019) improves performance by 250% and makes streams implementation more idiomatic.
- 3.1 (Jul 7, 2019) brings `bigint` support to `stat` output on Windows. This is backwards-incompatible for some cases. Be careful. It you use it incorrectly, you'll see "TypeError: Cannot mix BigInt and other types, use explicit conversions".
- 3.0 brings huge performance improvements and stream backpressure support.
- Upgrading 2.x to 3.x:
- Signature changed from `readdirp(options)` to `readdirp(root, options)`
- Replaced callback API with promise API.
- Renamed `entryType` option to `type`
- Renamed `entryType: 'both'` to `'files_directories'`
- `EntryInfo`
- Renamed `stat` to `stats`
- Emitted only when `alwaysStat: true`
- `dirent` is emitted instead of `stats` by default with `alwaysStat: false`
- Renamed `name` to `basename`
- Removed `parentDir` and `fullParentDir` properties
- Supported node.js versions:
- 4.x: node 14+
- 3.x: node 8+
- 2.x: node 0.6+
## License
Copyright (c) 2012-2019 Thorsten Lorenz, Paul Miller (<https://paulmillr.com>)
MIT License, see [LICENSE](LICENSE) file.

View File

@@ -0,0 +1,151 @@
'use strict'
const test = require('tape')
const fastURI = require('..')
test('URI Serialize', (t) => {
let components = {
scheme: undefined,
userinfo: undefined,
host: undefined,
port: undefined,
path: undefined,
query: undefined,
fragment: undefined
}
t.equal(fastURI.serialize(components), '', 'Undefined Components')
components = {
scheme: '',
userinfo: '',
host: '',
port: 0,
path: '',
query: '',
fragment: ''
}
t.equal(fastURI.serialize(components), '//@:0?#', 'Empty Components')
components = {
scheme: 'uri',
userinfo: 'foo:bar',
host: 'example.com',
port: 1,
path: 'path',
query: 'query',
fragment: 'fragment'
}
t.equal(fastURI.serialize(components), 'uri://foo:bar@example.com:1/path?query#fragment', 'All Components')
components = {
scheme: 'uri',
host: 'example.com',
port: '9000'
}
t.equal(fastURI.serialize(components), 'uri://example.com:9000', 'String port')
t.equal(fastURI.serialize({ path: '//path' }), '/%2Fpath', 'Double slash path')
t.equal(fastURI.serialize({ path: 'foo:bar' }), 'foo%3Abar', 'Colon path')
t.equal(fastURI.serialize({ path: '?query' }), '%3Fquery', 'Query path')
t.equal(fastURI.serialize({ host: '10.10.10.10' }), '//10.10.10.10', 'IPv4address')
// mixed IPv4address & reg-name, example from terion-name (https://github.com/garycourt/uri-js/issues/4)
t.equal(fastURI.serialize({ host: '10.10.10.10.example.com' }), '//10.10.10.10.example.com', 'Mixed IPv4address & reg-name')
// IPv6address
t.equal(fastURI.serialize({ host: '2001:db8::7' }), '//[2001:db8::7]', 'IPv6 Host')
t.equal(fastURI.serialize({ host: '::ffff:129.144.52.38' }), '//[::ffff:129.144.52.38]', 'IPv6 Mixed Host')
t.equal(fastURI.serialize({ host: '2606:2800:220:1:248:1893:25c8:1946' }), '//[2606:2800:220:1:248:1893:25c8:1946]', 'IPv6 Full Host')
// IPv6address with zone identifier, RFC 6874
t.equal(fastURI.serialize({ host: 'fe80::a%en1' }), '//[fe80::a%25en1]', 'IPv6 Zone Unescaped Host')
t.equal(fastURI.serialize({ host: 'fe80::a%25en1' }), '//[fe80::a%25en1]', 'IPv6 Zone Escaped Host')
t.end()
})
test('WS serialize', (t) => {
t.equal(fastURI.serialize({ scheme: 'ws' }), 'ws:')
t.equal(fastURI.serialize({ scheme: 'ws', host: 'example.com' }), 'ws://example.com')
t.equal(fastURI.serialize({ scheme: 'ws', resourceName: '/' }), 'ws:')
t.equal(fastURI.serialize({ scheme: 'ws', resourceName: '/foo' }), 'ws:/foo')
t.equal(fastURI.serialize({ scheme: 'ws', resourceName: '/foo?bar' }), 'ws:/foo?bar')
t.equal(fastURI.serialize({ scheme: 'ws', secure: false }), 'ws:')
t.equal(fastURI.serialize({ scheme: 'ws', secure: true }), 'wss:')
t.equal(fastURI.serialize({ scheme: 'ws', host: 'example.com', resourceName: '/foo' }), 'ws://example.com/foo')
t.equal(fastURI.serialize({ scheme: 'ws', host: 'example.com', resourceName: '/foo?bar' }), 'ws://example.com/foo?bar')
t.equal(fastURI.serialize({ scheme: 'ws', host: 'example.com', secure: false }), 'ws://example.com')
t.equal(fastURI.serialize({ scheme: 'ws', host: 'example.com', secure: true }), 'wss://example.com')
t.equal(fastURI.serialize({ scheme: 'ws', host: 'example.com', resourceName: '/foo?bar', secure: false }), 'ws://example.com/foo?bar')
t.equal(fastURI.serialize({ scheme: 'ws', host: 'example.com', resourceName: '/foo?bar', secure: true }), 'wss://example.com/foo?bar')
t.end()
})
test('WSS serialize', (t) => {
t.equal(fastURI.serialize({ scheme: 'wss' }), 'wss:')
t.equal(fastURI.serialize({ scheme: 'wss', host: 'example.com' }), 'wss://example.com')
t.equal(fastURI.serialize({ scheme: 'wss', resourceName: '/' }), 'wss:')
t.equal(fastURI.serialize({ scheme: 'wss', resourceName: '/foo' }), 'wss:/foo')
t.equal(fastURI.serialize({ scheme: 'wss', resourceName: '/foo?bar' }), 'wss:/foo?bar')
t.equal(fastURI.serialize({ scheme: 'wss', secure: false }), 'ws:')
t.equal(fastURI.serialize({ scheme: 'wss', secure: true }), 'wss:')
t.equal(fastURI.serialize({ scheme: 'wss', host: 'example.com', resourceName: '/foo' }), 'wss://example.com/foo')
t.equal(fastURI.serialize({ scheme: 'wss', host: 'example.com', resourceName: '/foo?bar' }), 'wss://example.com/foo?bar')
t.equal(fastURI.serialize({ scheme: 'wss', host: 'example.com', secure: false }), 'ws://example.com')
t.equal(fastURI.serialize({ scheme: 'wss', host: 'example.com', secure: true }), 'wss://example.com')
t.equal(fastURI.serialize({ scheme: 'wss', host: 'example.com', resourceName: '/foo?bar', secure: false }), 'ws://example.com/foo?bar')
t.equal(fastURI.serialize({ scheme: 'wss', host: 'example.com', resourceName: '/foo?bar', secure: true }), 'wss://example.com/foo?bar')
t.end()
})
test('URN serialize', (t) => {
// example from RFC 2141
const components = {
scheme: 'urn',
nid: 'foo',
nss: 'a123,456'
}
t.equal(fastURI.serialize(components), 'urn:foo:a123,456')
// example from RFC 4122
let uuidcomponents = {
scheme: 'urn',
nid: 'uuid',
uuid: 'f81d4fae-7dec-11d0-a765-00a0c91e6bf6'
}
t.equal(fastURI.serialize(uuidcomponents), 'urn:uuid:f81d4fae-7dec-11d0-a765-00a0c91e6bf6')
uuidcomponents = {
scheme: 'urn',
nid: 'uuid',
uuid: 'notauuid-7dec-11d0-a765-00a0c91e6bf6'
}
t.equal(fastURI.serialize(uuidcomponents), 'urn:uuid:notauuid-7dec-11d0-a765-00a0c91e6bf6')
uuidcomponents = {
scheme: 'urn',
nid: undefined,
uuid: 'notauuid-7dec-11d0-a765-00a0c91e6bf6'
}
t.throws(() => { fastURI.serialize(uuidcomponents) }, 'URN without nid cannot be serialized')
t.end()
})
test('URN NID Override', (t) => {
let components = fastURI.parse('urn:foo:f81d4fae-7dec-11d0-a765-00a0c91e6bf6', { nid: 'uuid' })
t.equal(components.error, undefined, 'errors')
t.equal(components.scheme, 'urn', 'scheme')
t.equal(components.path, undefined, 'path')
t.equal(components.nid, 'foo', 'nid')
t.equal(components.nss, undefined, 'nss')
t.equal(components.uuid, 'f81d4fae-7dec-11d0-a765-00a0c91e6bf6', 'uuid')
components = {
scheme: 'urn',
nid: 'foo',
uuid: 'f81d4fae-7dec-11d0-a765-00a0c91e6bf6'
}
t.equal(fastURI.serialize(components, { nid: 'uuid' }), 'urn:foo:f81d4fae-7dec-11d0-a765-00a0c91e6bf6')
t.end()
})

View File

@@ -0,0 +1,94 @@
import { IncomingHttpHeaders } from './header'
import Dispatcher from './dispatcher'
import { BodyInit, Headers } from './fetch'
/** The scope associated with a mock dispatch. */
declare class MockScope<TData extends object = object> {
constructor (mockDispatch: MockInterceptor.MockDispatch<TData>)
/** Delay a reply by a set amount of time in ms. */
delay (waitInMs: number): MockScope<TData>
/** Persist the defined mock data for the associated reply. It will return the defined mock data indefinitely. */
persist (): MockScope<TData>
/** Define a reply for a set amount of matching requests. */
times (repeatTimes: number): MockScope<TData>
}
/** The interceptor for a Mock. */
declare class MockInterceptor {
constructor (options: MockInterceptor.Options, mockDispatches: MockInterceptor.MockDispatch[])
/** Mock an undici request with the defined reply. */
reply<TData extends object = object>(replyOptionsCallback: MockInterceptor.MockReplyOptionsCallback<TData>): MockScope<TData>
reply<TData extends object = object>(
statusCode: number,
data?: TData | Buffer | string | MockInterceptor.MockResponseDataHandler<TData>,
responseOptions?: MockInterceptor.MockResponseOptions
): MockScope<TData>
/** Mock an undici request by throwing the defined reply error. */
replyWithError<TError extends Error = Error>(error: TError): MockScope
/** Set default reply headers on the interceptor for subsequent mocked replies. */
defaultReplyHeaders (headers: IncomingHttpHeaders): MockInterceptor
/** Set default reply trailers on the interceptor for subsequent mocked replies. */
defaultReplyTrailers (trailers: Record<string, string>): MockInterceptor
/** Set automatically calculated content-length header on subsequent mocked replies. */
replyContentLength (): MockInterceptor
}
declare namespace MockInterceptor {
/** MockInterceptor options. */
export interface Options {
/** Path to intercept on. */
path: string | RegExp | ((path: string) => boolean);
/** Method to intercept on. Defaults to GET. */
method?: string | RegExp | ((method: string) => boolean);
/** Body to intercept on. */
body?: string | RegExp | ((body: string) => boolean);
/** Headers to intercept on. */
headers?: Record<string, string | RegExp | ((body: string) => boolean)> | ((headers: Record<string, string>) => boolean);
/** Query params to intercept on */
query?: Record<string, any>;
}
export interface MockDispatch<TData extends object = object, TError extends Error = Error> extends Options {
times: number | null;
persist: boolean;
consumed: boolean;
data: MockDispatchData<TData, TError>;
}
export interface MockDispatchData<TData extends object = object, TError extends Error = Error> extends MockResponseOptions {
error: TError | null;
statusCode?: number;
data?: TData | string;
}
export interface MockResponseOptions {
headers?: IncomingHttpHeaders;
trailers?: Record<string, string>;
}
export interface MockResponseCallbackOptions {
path: string;
method: string;
headers?: Headers | Record<string, string>;
origin?: string;
body?: BodyInit | Dispatcher.DispatchOptions['body'] | null;
}
export type MockResponseDataHandler<TData extends object = object> = (
opts: MockResponseCallbackOptions
) => TData | Buffer | string
export type MockReplyOptionsCallback<TData extends object = object> = (
opts: MockResponseCallbackOptions
) => { statusCode: number, data?: TData | Buffer | string, responseOptions?: MockResponseOptions }
}
interface Interceptable extends Dispatcher {
/** Intercepts any matching requests that use the same origin as this mock client. */
intercept(options: MockInterceptor.Options): MockInterceptor;
/** Clean up all the prepared mocks. */
cleanMocks (): void
}
export {
Interceptable,
MockInterceptor,
MockScope
}

View File

@@ -0,0 +1,38 @@
import type { ContextOptions, DateArg } from "./types.js";
/**
* The {@link setISOWeek} function options.
*/
export interface SetISOWeekOptions<DateType extends Date = Date>
extends ContextOptions<DateType> {}
/**
* @name setISOWeek
* @category ISO Week Helpers
* @summary Set the ISO week to the given date.
*
* @description
* Set the ISO week to the given date, saving the weekday number.
*
* ISO week-numbering year: http://en.wikipedia.org/wiki/ISO_week_date
*
* @typeParam DateType - The `Date` type, the function operates on. Gets inferred from passed arguments. Allows to use extensions like [`UTCDate`](https://github.com/date-fns/utc).
* @typeParam ResultDate - The `Date` type of the context function.
*
* @param date - The date to be changed
* @param week - The ISO week of the new date
* @param options - An object with options
*
* @returns The new date with the ISO week set
*
* @example
* // Set the 53rd ISO week to 7 August 2004:
* const result = setISOWeek(new Date(2004, 7, 7), 53)
* //=> Sat Jan 01 2005 00:00:00
*/
export declare function setISOWeek<
DateType extends Date,
ResultDate extends Date = DateType,
>(
date: DateArg<DateType>,
week: number,
options?: SetISOWeekOptions<ResultDate>,
): ResultDate;

View File

@@ -0,0 +1,41 @@
import { buildVersionCollectionFields, combineQueries } from 'payload';
import toSnakeCase from 'to-snake-case';
import { findMany } from './find/findMany.js';
export const queryDrafts = async function queryDrafts({ collection, joins, limit, locale, page = 1, pagination, req, select, sort, where }) {
const collectionConfig = this.payload.collections[collection].config;
const tableName = this.tableNameMap.get(`_${toSnakeCase(collectionConfig.slug)}${this.versionsSuffix}`);
const fields = buildVersionCollectionFields(this.payload.config, collectionConfig, true);
const combinedWhere = combineQueries({
latest: {
equals: true
}
}, where);
const result = await findMany({
adapter: this,
collectionSlug: collection,
fields,
joins,
limit,
locale,
page,
pagination,
req,
select,
sort,
tableName,
versions: true,
where: combinedWhere
});
return {
...result,
docs: result.docs.map((doc)=>{
doc = {
id: doc.parent,
...doc.version
};
return doc;
})
};
};
//# sourceMappingURL=queryDrafts.js.map

View File

@@ -0,0 +1,10 @@
"use strict";
exports.isSunday = void 0;
var _index = require("../isSunday.cjs");
var _index2 = require("./_lib/convertToFP.cjs"); // This file is generated automatically by `scripts/build/fp.ts`. Please, don't change it.
const isSunday = (exports.isSunday = (0, _index2.convertToFP)(
_index.isSunday,
1,
));

View File

@@ -0,0 +1,79 @@
/* -*- Mode: js; js-indent-level: 2; -*- */
/*
* Copyright 2014 Mozilla Foundation and contributors
* Licensed under the New BSD license. See LICENSE or:
* http://opensource.org/licenses/BSD-3-Clause
*/
var util = require('./util');
/**
* Determine whether mappingB is after mappingA with respect to generated
* position.
*/
function generatedPositionAfter(mappingA, mappingB) {
// Optimized for most common case
var lineA = mappingA.generatedLine;
var lineB = mappingB.generatedLine;
var columnA = mappingA.generatedColumn;
var columnB = mappingB.generatedColumn;
return lineB > lineA || lineB == lineA && columnB >= columnA ||
util.compareByGeneratedPositionsInflated(mappingA, mappingB) <= 0;
}
/**
* A data structure to provide a sorted view of accumulated mappings in a
* performance conscious manner. It trades a neglibable overhead in general
* case for a large speedup in case of mappings being added in order.
*/
function MappingList() {
this._array = [];
this._sorted = true;
// Serves as infimum
this._last = {generatedLine: -1, generatedColumn: 0};
}
/**
* Iterate through internal items. This method takes the same arguments that
* `Array.prototype.forEach` takes.
*
* NOTE: The order of the mappings is NOT guaranteed.
*/
MappingList.prototype.unsortedForEach =
function MappingList_forEach(aCallback, aThisArg) {
this._array.forEach(aCallback, aThisArg);
};
/**
* Add the given source mapping.
*
* @param Object aMapping
*/
MappingList.prototype.add = function MappingList_add(aMapping) {
if (generatedPositionAfter(this._last, aMapping)) {
this._last = aMapping;
this._array.push(aMapping);
} else {
this._sorted = false;
this._array.push(aMapping);
}
};
/**
* Returns the flat, sorted array of mappings. The mappings are sorted by
* generated position.
*
* WARNING: This method returns internal data without copying, for
* performance. The return value must NOT be mutated, and should be treated as
* an immutable borrow. If you want to take ownership, you must make your own
* copy.
*/
MappingList.prototype.toArray = function MappingList_toArray() {
if (!this._sorted) {
this._array.sort(util.compareByGeneratedPositionsInflated);
this._sorted = true;
}
return this._array;
};
exports.MappingList = MappingList;

View File

@@ -0,0 +1 @@
{"version":3,"file":"feedback.js","sources":["../../src/feedback.ts"],"sourcesContent":["import { getClient, getCurrentScope } from './currentScopes';\nimport type { EventHint } from './types-hoist/event';\nimport type { FeedbackEvent, SendFeedbackParams } from './types-hoist/feedback';\n\n/**\n * Send user feedback to Sentry.\n */\nexport function captureFeedback(\n params: SendFeedbackParams,\n hint: EventHint & { includeReplay?: boolean } = {},\n scope = getCurrentScope(),\n): string {\n const { message, name, email, url, source, associatedEventId, tags } = params;\n\n const feedbackEvent: FeedbackEvent = {\n contexts: {\n feedback: {\n contact_email: email,\n name,\n message,\n url,\n source,\n associated_event_id: associatedEventId,\n },\n },\n type: 'feedback',\n level: 'info',\n tags,\n };\n\n const client = scope?.getClient() || getClient();\n\n if (client) {\n client.emit('beforeSendFeedback', feedbackEvent, hint);\n }\n\n const eventId = scope.captureEvent(feedbackEvent, hint);\n\n return eventId;\n}\n"],"names":["getCurrentScope","getClient"],"mappings":";;;;AAIA;AACA;AACA;AACO,SAAS,eAAe;AAC/B,EAAE,MAAM;AACR,EAAE,IAAI,GAA4C,EAAE;AACpD,EAAE,KAAA,GAAQA,6BAAe,EAAE;AAC3B,EAAU;AACV,EAAE,MAAM,EAAE,OAAO,EAAE,IAAI,EAAE,KAAK,EAAE,GAAG,EAAE,MAAM,EAAE,iBAAiB,EAAE,IAAA,EAAK,GAAI,MAAM;;AAE/E,EAAE,MAAM,aAAa,GAAkB;AACvC,IAAI,QAAQ,EAAE;AACd,MAAM,QAAQ,EAAE;AAChB,QAAQ,aAAa,EAAE,KAAK;AAC5B,QAAQ,IAAI;AACZ,QAAQ,OAAO;AACf,QAAQ,GAAG;AACX,QAAQ,MAAM;AACd,QAAQ,mBAAmB,EAAE,iBAAiB;AAC9C,OAAO;AACP,KAAK;AACL,IAAI,IAAI,EAAE,UAAU;AACpB,IAAI,KAAK,EAAE,MAAM;AACjB,IAAI,IAAI;AACR,GAAG;;AAEH,EAAE,MAAM,MAAA,GAAS,KAAK,EAAE,SAAS,EAAC,IAAKC,uBAAS,EAAE;;AAElD,EAAE,IAAI,MAAM,EAAE;AACd,IAAI,MAAM,CAAC,IAAI,CAAC,oBAAoB,EAAE,aAAa,EAAE,IAAI,CAAC;AAC1D,EAAE;;AAEF,EAAE,MAAM,OAAA,GAAU,KAAK,CAAC,YAAY,CAAC,aAAa,EAAE,IAAI,CAAC;;AAEzD,EAAE,OAAO,OAAO;AAChB;;;;"}

View File

@@ -0,0 +1,189 @@
"use strict";
exports.localize = void 0;
var _index = require("../../_lib/buildLocalizeFn.cjs");
const eraValues = {
narrow: ["R", "A"],
abbreviated: ["RC", "AD"],
wide: ["ro Chrìosta", "anno domini"],
};
const quarterValues = {
narrow: ["1", "2", "3", "4"],
abbreviated: ["C1", "C2", "C3", "C4"],
wide: [
"a' chiad chairteal",
"an dàrna cairteal",
"an treas cairteal",
"an ceathramh cairteal",
],
};
// Note: in English, the names of days of the week and months are capitalized.
// If you are making a new locale based on this one, check if the same is true for the language you're working on.
// Generally, formatted dates should look like they are in the middle of a sentence,
// e.g. in Spanish language the weekdays and months should be in the lowercase.
const monthValues = {
narrow: ["F", "G", "M", "G", "C", "Ò", "I", "L", "S", "D", "S", "D"],
abbreviated: [
"Faoi",
"Gear",
"Màrt",
"Gibl",
"Cèit",
"Ògmh",
"Iuch",
"Lùn",
"Sult",
"Dàmh",
"Samh",
"Dùbh",
],
wide: [
"Am Faoilleach",
"An Gearran",
"Am Màrt",
"An Giblean",
"An Cèitean",
"An t-Ògmhios",
"An t-Iuchar",
"An Lùnastal",
"An t-Sultain",
"An Dàmhair",
"An t-Samhain",
"An Dùbhlachd",
],
};
const dayValues = {
narrow: ["D", "L", "M", "C", "A", "H", "S"],
short: ["Dò", "Lu", "Mà", "Ci", "Ar", "Ha", "Sa"],
abbreviated: ["Did", "Dil", "Dim", "Dic", "Dia", "Dih", "Dis"],
wide: [
"Didòmhnaich",
"Diluain",
"Dimàirt",
"Diciadain",
"Diardaoin",
"Dihaoine",
"Disathairne",
],
};
const dayPeriodValues = {
narrow: {
am: "m",
pm: "f",
midnight: "m.o.",
noon: "m.l.",
morning: "madainn",
afternoon: "feasgar",
evening: "feasgar",
night: "oidhche",
},
abbreviated: {
am: "M.",
pm: "F.",
midnight: "meadhan oidhche",
noon: "meadhan là",
morning: "madainn",
afternoon: "feasgar",
evening: "feasgar",
night: "oidhche",
},
wide: {
am: "m.",
pm: "f.",
midnight: "meadhan oidhche",
noon: "meadhan là",
morning: "madainn",
afternoon: "feasgar",
evening: "feasgar",
night: "oidhche",
},
};
const formattingDayPeriodValues = {
narrow: {
am: "m",
pm: "f",
midnight: "m.o.",
noon: "m.l.",
morning: "sa mhadainn",
afternoon: "feasgar",
evening: "feasgar",
night: "air an oidhche",
},
abbreviated: {
am: "M.",
pm: "F.",
midnight: "meadhan oidhche",
noon: "meadhan là",
morning: "sa mhadainn",
afternoon: "feasgar",
evening: "feasgar",
night: "air an oidhche",
},
wide: {
am: "m.",
pm: "f.",
midnight: "meadhan oidhche",
noon: "meadhan là",
morning: "sa mhadainn",
afternoon: "feasgar",
evening: "feasgar",
night: "air an oidhche",
},
};
const ordinalNumber = (dirtyNumber) => {
const number = Number(dirtyNumber);
const rem100 = number % 100;
if (rem100 > 20 || rem100 < 10) {
switch (rem100 % 10) {
case 1:
return number + "d";
case 2:
return number + "na";
}
}
if (rem100 === 12) {
return number + "na";
}
return number + "mh";
};
const localize = (exports.localize = {
ordinalNumber,
era: (0, _index.buildLocalizeFn)({
values: eraValues,
defaultWidth: "wide",
}),
quarter: (0, _index.buildLocalizeFn)({
values: quarterValues,
defaultWidth: "wide",
argumentCallback: (quarter) => quarter - 1,
}),
month: (0, _index.buildLocalizeFn)({
values: monthValues,
defaultWidth: "wide",
}),
day: (0, _index.buildLocalizeFn)({
values: dayValues,
defaultWidth: "wide",
}),
dayPeriod: (0, _index.buildLocalizeFn)({
values: dayPeriodValues,
defaultWidth: "wide",
formattingValues: formattingDayPeriodValues,
defaultFormattingWidth: "wide",
}),
});

View File

@@ -0,0 +1,5 @@
import { LoaderContext } from 'webpack';
declare function load(this: LoaderContext<any>, source: string, map: any): Promise<void>;
export { load as default };

View File

@@ -0,0 +1,31 @@
/**
* Copyright (c) Meta Platforms, Inc. and affiliates.
*
* This source code is licensed under the MIT license found in the
* LICENSE file in the root directory of this source tree.
*
*/
import * as modDev from './LexicalList.dev.mjs';
import * as modProd from './LexicalList.prod.mjs';
const mod = process.env.NODE_ENV !== 'production' ? modDev : modProd;
export const $createListItemNode = mod.$createListItemNode;
export const $createListNode = mod.$createListNode;
export const $getListDepth = mod.$getListDepth;
export const $handleListInsertParagraph = mod.$handleListInsertParagraph;
export const $insertList = mod.$insertList;
export const $isListItemNode = mod.$isListItemNode;
export const $isListNode = mod.$isListNode;
export const $removeList = mod.$removeList;
export const INSERT_CHECK_LIST_COMMAND = mod.INSERT_CHECK_LIST_COMMAND;
export const INSERT_ORDERED_LIST_COMMAND = mod.INSERT_ORDERED_LIST_COMMAND;
export const INSERT_UNORDERED_LIST_COMMAND = mod.INSERT_UNORDERED_LIST_COMMAND;
export const ListItemNode = mod.ListItemNode;
export const ListNode = mod.ListNode;
export const REMOVE_LIST_COMMAND = mod.REMOVE_LIST_COMMAND;
export const UPDATE_LIST_START_COMMAND = mod.UPDATE_LIST_START_COMMAND;
export const insertList = mod.insertList;
export const registerCheckList = mod.registerCheckList;
export const registerList = mod.registerList;
export const registerListStrictIndentTransform = mod.registerListStrictIndentTransform;
export const removeList = mod.removeList;

View File

@@ -0,0 +1,10 @@
"use strict";
exports.lastDayOfYear = void 0;
var _index = require("../lastDayOfYear.js");
var _index2 = require("./_lib/convertToFP.js"); // This file is generated automatically by `scripts/build/fp.ts`. Please, don't change it.
const lastDayOfYear = (exports.lastDayOfYear = (0, _index2.convertToFP)(
_index.lastDayOfYear,
1,
));

View File

@@ -0,0 +1,8 @@
// This file is generated automatically by `scripts/build/fp.ts`. Please, don't change it.
import { isWeekend as fn } from "../isWeekend.mjs";
import { convertToFP } from "./_lib/convertToFP.mjs";
export const isWeekend = convertToFP(fn, 1);
// Fallback for modularized imports:
export default isWeekend;

View File

@@ -0,0 +1 @@
{"version":3,"file":"verifyEmail.d.ts","sourceRoot":"","sources":["../../../src/resolvers/auth/verifyEmail.ts"],"names":[],"mappings":"AAAA,OAAO,KAAK,EAAE,UAAU,EAAE,MAAM,SAAS,CAAA;AAIzC,OAAO,KAAK,EAAE,OAAO,EAAE,MAAM,aAAa,CAAA;AAE1C,wBAAgB,WAAW,CAAC,UAAU,EAAE,UAAU,gCACN,OAAO,sBAoBlD"}

View File

@@ -0,0 +1,28 @@
import type { SanitizedCollectionConfig } from '../collections/config/types.js';
import type { SanitizedGlobalConfig } from '../globals/config/types.js';
import type { Payload } from '../index.js';
import type { JsonObject, PayloadRequest, SelectType } from '../types/index.js';
type Args<T extends JsonObject = JsonObject> = {
autosave?: boolean;
collection?: SanitizedCollectionConfig;
docWithLocales: T;
draft?: boolean;
global?: SanitizedGlobalConfig;
id?: number | string;
operation?: 'create' | 'restoreVersion' | 'update';
payload: Payload;
publishSpecificLocale?: string;
req?: PayloadRequest;
returning?: boolean;
select?: SelectType;
snapshot?: any;
};
export declare function saveVersion<TData extends JsonObject = JsonObject>(args: {
returning: false;
} & Args<TData>): Promise<null>;
export declare function saveVersion<TData extends JsonObject = JsonObject>(args: {
returning: true;
} & Args<TData>): Promise<JsonObject>;
export declare function saveVersion<TData extends JsonObject = JsonObject>(args: Omit<Args<TData>, 'returning'>): Promise<JsonObject>;
export {};
//# sourceMappingURL=saveVersion.d.ts.map

View File

@@ -0,0 +1,4 @@
import type { DefaultTranslationsObject, Language } from '../types.js';
export declare const hrTranslations: DefaultTranslationsObject;
export declare const hr: Language;
//# sourceMappingURL=hr.d.ts.map

View File

@@ -0,0 +1,61 @@
import type {
ContextOptions,
DateArg,
FirstWeekContainsDateOptions,
LocalizedOptions,
WeekOptions,
} from "./types.js";
/**
* The {@link setWeek} function options.
*/
export interface SetWeekOptions<DateType extends Date = Date>
extends LocalizedOptions<"options">,
WeekOptions,
FirstWeekContainsDateOptions,
ContextOptions<DateType> {}
/**
* @name setWeek
* @category Week Helpers
* @summary Set the local week to the given date.
*
* @description
* Set the local week to the given date, saving the weekday number.
* The exact calculation depends on the values of
* `options.weekStartsOn` (which is the index of the first day of the week)
* and `options.firstWeekContainsDate` (which is the day of January, which is always in
* the first week of the week-numbering year)
*
* Week numbering: https://en.wikipedia.org/wiki/Week#The_ISO_week_date_system
*
* @typeParam DateType - The `Date` type, the function operates on. Gets inferred from passed arguments. Allows to use extensions like [`UTCDate`](https://github.com/date-fns/utc).
* @typeParam ResultDate - The result `Date` type, it is the type returned from the context function if it is passed, or inferred from the arguments.
*
* @param date - The date to be changed
* @param week - The week of the new date
* @param options - An object with options
*
* @returns The new date with the local week set
*
* @example
* // Set the 1st week to 2 January 2005 with default options:
* const result = setWeek(new Date(2005, 0, 2), 1)
* //=> Sun Dec 26 2004 00:00:00
*
* @example
* // Set the 1st week to 2 January 2005,
* // if Monday is the first day of the week,
* // and the first week of the year always contains 4 January:
* const result = setWeek(new Date(2005, 0, 2), 1, {
* weekStartsOn: 1,
* firstWeekContainsDate: 4
* })
* //=> Sun Jan 4 2004 00:00:00
*/
export declare function setWeek<
DateType extends Date,
ResultDate extends Date = DateType,
>(
date: DateArg<DateType>,
week: number,
options?: SetWeekOptions<ResultDate>,
): ResultDate;

View File

@@ -0,0 +1,39 @@
import { buildFormatLongFn } from "../../_lib/buildFormatLongFn.mjs";
const dateFormats = {
full: "d MMMM, y, EEEE",
long: "d MMMM, y",
medium: "d MMM, y",
short: "dd.MM.yyyy",
};
const timeFormats = {
full: "HH:mm:ss zzzz",
long: "HH:mm:ss z",
medium: "HH:mm:ss",
short: "HH:mm",
};
const dateTimeFormats = {
full: "{{date}} 'ժ․'{{time}}",
long: "{{date}} 'ժ․'{{time}}",
medium: "{{date}}, {{time}}",
short: "{{date}}, {{time}}",
};
export const formatLong = {
date: buildFormatLongFn({
formats: dateFormats,
defaultWidth: "full",
}),
time: buildFormatLongFn({
formats: timeFormats,
defaultWidth: "full",
}),
dateTime: buildFormatLongFn({
formats: dateTimeFormats,
defaultWidth: "full",
}),
};

View File

@@ -0,0 +1,58 @@
export interface IStreamReader {
/**
* Peak ahead (peek) from stream. Subsequent read or peeks will return the same data.
* @param uint8Array - Uint8Array (or Buffer) to store data read from stream in
* @param offset - Offset target
* @param length - Number of bytes to read
* @returns Number of bytes peeked
*/
peek(uint8Array: Uint8Array, offset: number, length: number): Promise<number>;
/**
* Read from stream the stream.
* @param uint8Array - Uint8Array (or Buffer) to store data read from stream in
* @param offset - Offset target
* @param length - Number of bytes to read
* @returns Number of bytes peeked
*/
read(uint8Array: Uint8Array, offset: number, length: number): Promise<number>;
/**
* Close underlying resources, claims.
*/
close(): Promise<void>;
/**
* Abort any active asynchronous operation are active, abort those before they may have completed.
*/
abort(): Promise<void>;
}
export declare abstract class AbstractStreamReader implements IStreamReader {
/**
* Maximum request length on read-stream operation
*/
protected maxStreamReadSize: number;
protected endOfStream: boolean;
/**
* Store peeked data
* @type {Array}
*/
protected peekQueue: Uint8Array[];
peek(uint8Array: Uint8Array, offset: number, length: number): Promise<number>;
read(buffer: Uint8Array, offset: number, length: number): Promise<number>;
/**
* Read chunk from stream
* @param buffer - Target Uint8Array (or Buffer) to store data read from stream in
* @param offset - Offset target
* @param length - Number of bytes to read
* @returns Number of bytes read
*/
protected readFromPeekBuffer(buffer: Uint8Array, offset: number, length: number): number;
readRemainderFromStream(buffer: Uint8Array, offset: number, initialRemaining: number): Promise<number>;
protected abstract readFromStream(buffer: Uint8Array, offset: number, length: number): Promise<number>;
/**
* abort synchronous operations
*/
abstract close(): Promise<void>;
/**
* Abort any active asynchronous operation are active, abort those before they may have completed.
*/
abstract abort(): Promise<void>;
}

View File

@@ -0,0 +1 @@
{"version":3,"file":"index.js","names":["DefaultEditView","React","EditView","props","_jsx"],"sources":["../../../src/views/Edit/index.tsx"],"sourcesContent":["'use client'\n\nimport type { DocumentViewClientProps } from 'payload'\n\nimport { DefaultEditView } from '@payloadcms/ui'\nimport React from 'react'\n\nexport const EditView: React.FC<DocumentViewClientProps> = (props) => {\n return <DefaultEditView {...props} />\n}\n"],"mappings":"AAAA;;;AAIA,SAASA,eAAe,QAAQ;AAChC,OAAOC,KAAA,MAAW;AAElB,OAAO,MAAMC,QAAA,GAA+CC,KAAA;EAC1D,oBAAOC,IAAA,CAACJ,eAAA;IAAiB,GAAGG;;AAC9B","ignoreList":[]}

View File

@@ -0,0 +1 @@
{"version":3,"file":"circuit-board.js","sources":["../../../src/icons/circuit-board.ts"],"sourcesContent":["import createLucideIcon from '../createLucideIcon';\n\n/**\n * @component @name CircuitBoard\n * @description Lucide SVG icon component, renders SVG Element with children.\n *\n * @preview ![img](data:image/svg+xml;base64,PHN2ZyAgeG1sbnM9Imh0dHA6Ly93d3cudzMub3JnLzIwMDAvc3ZnIgogIHdpZHRoPSIyNCIKICBoZWlnaHQ9IjI0IgogIHZpZXdCb3g9IjAgMCAyNCAyNCIKICBmaWxsPSJub25lIgogIHN0cm9rZT0iIzAwMCIgc3R5bGU9ImJhY2tncm91bmQtY29sb3I6ICNmZmY7IGJvcmRlci1yYWRpdXM6IDJweCIKICBzdHJva2Utd2lkdGg9IjIiCiAgc3Ryb2tlLWxpbmVjYXA9InJvdW5kIgogIHN0cm9rZS1saW5lam9pbj0icm91bmQiCj4KICA8cmVjdCB3aWR0aD0iMTgiIGhlaWdodD0iMTgiIHg9IjMiIHk9IjMiIHJ4PSIyIiAvPgogIDxwYXRoIGQ9Ik0xMSA5aDRhMiAyIDAgMCAwIDItMlYzIiAvPgogIDxjaXJjbGUgY3g9IjkiIGN5PSI5IiByPSIyIiAvPgogIDxwYXRoIGQ9Ik03IDIxdi00YTIgMiAwIDAgMSAyLTJoNCIgLz4KICA8Y2lyY2xlIGN4PSIxNSIgY3k9IjE1IiByPSIyIiAvPgo8L3N2Zz4K) - https://lucide.dev/icons/circuit-board\n * @see https://lucide.dev/guide/packages/lucide-react - Documentation\n *\n * @param {Object} props - Lucide icons props and any valid SVG attribute\n * @returns {JSX.Element} JSX Element\n *\n */\nconst CircuitBoard = createLucideIcon('CircuitBoard', [\n ['rect', { width: '18', height: '18', x: '3', y: '3', rx: '2', key: 'afitv7' }],\n ['path', { d: 'M11 9h4a2 2 0 0 0 2-2V3', key: '1ve2rv' }],\n ['circle', { cx: '9', cy: '9', r: '2', key: 'af1f0g' }],\n ['path', { d: 'M7 21v-4a2 2 0 0 1 2-2h4', key: '1fwkro' }],\n ['circle', { cx: '15', cy: '15', r: '2', key: '3i40o0' }],\n]);\n\nexport default CircuitBoard;\n"],"names":[],"mappings":";;;;;;;;;AAaM,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAe,iBAAiB,cAAgB,CAAA,CAAA,CAAA;AAAA,CAAA,CACpD,CAAC,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAQ,CAAA,CAAA,CAAE,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAO,MAAM,CAAQ,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAM,CAAG,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAK,GAAG,CAAK,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAI,CAAK,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAK,UAAU,CAAA,CAAA;AAAA,CAAA,CAC9E,CAAC,CAAA,CAAA,CAAA,CAAA,CAAA,CAAQ,CAAA,CAAA,CAAA,CAAE,GAAG,CAA2B,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAK,UAAU,CAAA,CAAA;AAAA,CACxD,CAAA,CAAC,QAAU,CAAA,CAAA,CAAA,CAAE,EAAI,CAAA,CAAA,CAAA,CAAA,CAAA,EAAK,CAAI,CAAA,CAAA,CAAA,GAAA,CAAK,CAAA,CAAG,EAAA,CAAA,CAAA,CAAA,CAAA,CAAK,GAAK,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,EAAU,CAAA,CAAA;AAAA,CAAA,CACtD,CAAC,CAAA,CAAA,CAAA,CAAA,CAAA,CAAQ,CAAA,CAAA,CAAA,CAAE,GAAG,CAA4B,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAK,UAAU,CAAA,CAAA;AAAA,CACzD,CAAA,CAAC,QAAU,CAAA,CAAA,CAAA,CAAE,EAAI,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,EAAM,CAAI,CAAA,CAAA,CAAA,IAAA,CAAM,CAAA,CAAG,EAAA,CAAA,CAAA,CAAA,CAAA,CAAK,GAAK,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,EAAU,CAAA;AAC1D,CAAC,CAAA,CAAA;;"}

View File

@@ -0,0 +1,42 @@
import { entityKind } from "../entity.js";
import { SQLiteTable } from "./table.js";
function primaryKey(...config) {
if (config[0].columns) {
return new PrimaryKeyBuilder(config[0].columns, config[0].name);
}
return new PrimaryKeyBuilder(config);
}
class PrimaryKeyBuilder {
static [entityKind] = "SQLitePrimaryKeyBuilder";
/** @internal */
columns;
/** @internal */
name;
constructor(columns, name) {
this.columns = columns;
this.name = name;
}
/** @internal */
build(table) {
return new PrimaryKey(table, this.columns, this.name);
}
}
class PrimaryKey {
constructor(table, columns, name) {
this.table = table;
this.columns = columns;
this.name = name;
}
static [entityKind] = "SQLitePrimaryKey";
columns;
name;
getName() {
return this.name ?? `${this.table[SQLiteTable.Symbol.Name]}_${this.columns.map((column) => column.name).join("_")}_pk`;
}
}
export {
PrimaryKey,
PrimaryKeyBuilder,
primaryKey
};
//# sourceMappingURL=primary-keys.js.map

View File

@@ -0,0 +1,44 @@
import { Parser, ParserOptions } from "./Parser.js";
export { Parser, type ParserOptions } from "./Parser.js";
import { DomHandlerOptions, ChildNode, Element, Document } from "domhandler";
export { DomHandler, DomHandler as DefaultHandler, type DomHandlerOptions, } from "domhandler";
export type Options = ParserOptions & DomHandlerOptions;
/**
* Parses the data, returns the resulting document.
*
* @param data The data that should be parsed.
* @param options Optional options for the parser and DOM builder.
*/
export declare function parseDocument(data: string, options?: Options): Document;
/**
* Parses data, returns an array of the root nodes.
*
* Note that the root nodes still have a `Document` node as their parent.
* Use `parseDocument` to get the `Document` node instead.
*
* @param data The data that should be parsed.
* @param options Optional options for the parser and DOM builder.
* @deprecated Use `parseDocument` instead.
*/
export declare function parseDOM(data: string, options?: Options): ChildNode[];
/**
* Creates a parser instance, with an attached DOM handler.
*
* @param callback A callback that will be called once parsing has been completed.
* @param options Optional options for the parser and DOM builder.
* @param elementCallback An optional callback that will be called every time a tag has been completed inside of the DOM.
*/
export declare function createDomStream(callback: (error: Error | null, dom: ChildNode[]) => void, options?: Options, elementCallback?: (element: Element) => void): Parser;
export { default as Tokenizer, type Callbacks as TokenizerCallbacks, } from "./Tokenizer.js";
export * as ElementType from "domelementtype";
import { Feed } from "domutils";
export { getFeed } from "domutils";
/**
* Parse a feed.
*
* @param feed The feed that should be parsed, as a string.
* @param options Optionally, options for parsing. When using this, you should set `xmlMode` to `true`.
*/
export declare function parseFeed(feed: string, options?: Options): Feed | null;
export * as DomUtils from "domutils";
//# sourceMappingURL=index.d.ts.map

View File

@@ -0,0 +1,28 @@
import type { ColumnBuilderBaseConfig } from "../../column-builder.js";
import type { ColumnBaseConfig } from "../../column.js";
import { entityKind } from "../../entity.js";
import { SingleStoreColumnBuilderWithAutoIncrement, SingleStoreColumnWithAutoIncrement } from "./common.js";
export type SingleStoreIntBuilderInitial<TName extends string> = SingleStoreIntBuilder<{
name: TName;
dataType: 'number';
columnType: 'SingleStoreInt';
data: number;
driverParam: number | string;
enumValues: undefined;
generated: undefined;
}>;
export declare class SingleStoreIntBuilder<T extends ColumnBuilderBaseConfig<'number', 'SingleStoreInt'>> extends SingleStoreColumnBuilderWithAutoIncrement<T, SingleStoreIntConfig> {
static readonly [entityKind]: string;
constructor(name: T['name'], config?: SingleStoreIntConfig);
}
export declare class SingleStoreInt<T extends ColumnBaseConfig<'number', 'SingleStoreInt'>> extends SingleStoreColumnWithAutoIncrement<T, SingleStoreIntConfig> {
static readonly [entityKind]: string;
getSQLType(): string;
mapFromDriverValue(value: number | string): number;
}
export interface SingleStoreIntConfig {
unsigned?: boolean;
}
export declare function int(): SingleStoreIntBuilderInitial<''>;
export declare function int(config?: SingleStoreIntConfig): SingleStoreIntBuilderInitial<''>;
export declare function int<TName extends string>(name: TName, config?: SingleStoreIntConfig): SingleStoreIntBuilderInitial<TName>;

View File

@@ -0,0 +1 @@
{"version":3,"file":"mimeTypeValidator.d.ts","sourceRoot":"","sources":["../../src/uploads/mimeTypeValidator.ts"],"names":[],"mappings":"AAAA,OAAO,KAAK,EAAE,QAAQ,EAAE,MAAM,2BAA2B,CAAA;AAIzD,eAAO,MAAM,iBAAiB,cAChB,MAAM,EAAE,KAAG,QAYtB,CAAA"}

View File

@@ -0,0 +1,18 @@
import type { InstrumentationHandlerCallback } from './instrument';
/**
* Start tracking INP webvital events.
*/
export declare function startTrackingINP(): () => void;
/** Starts tracking the Interaction to Next Paint on the current page. #
* exported only for testing
*/
export declare function _trackINP(): () => void;
/**
* exported only for testing
*/
export declare const _onInp: InstrumentationHandlerCallback;
/**
* Register a listener to cache route information for INP interactions.
*/
export declare function registerInpInteractionListener(): void;
//# sourceMappingURL=inp.d.ts.map

View File

@@ -0,0 +1,9 @@
// This file is generated automatically by `scripts/build/fp.ts`. Please, don't change it.
import { addDays as fn } from "../addDays.js";
import { convertToFP } from "./_lib/convertToFP.js";
export const addDays = convertToFP(fn, 2);
// Fallback for modularized imports:
export default addDays;

View File

@@ -0,0 +1,8 @@
import type { DrizzleAdapter } from './types.js';
/**
* Drop the current database and run all migrate up functions
*/
export declare function migrateFresh(this: DrizzleAdapter, { forceAcceptWarning }: {
forceAcceptWarning?: boolean;
}): Promise<void>;
//# sourceMappingURL=migrateFresh.d.ts.map

View File

@@ -0,0 +1,257 @@
var parseInt64 = require('pg-int8');
var parseBits = function(data, bits, offset, invert, callback) {
offset = offset || 0;
invert = invert || false;
callback = callback || function(lastValue, newValue, bits) { return (lastValue * Math.pow(2, bits)) + newValue; };
var offsetBytes = offset >> 3;
var inv = function(value) {
if (invert) {
return ~value & 0xff;
}
return value;
};
// read first (maybe partial) byte
var mask = 0xff;
var firstBits = 8 - (offset % 8);
if (bits < firstBits) {
mask = (0xff << (8 - bits)) & 0xff;
firstBits = bits;
}
if (offset) {
mask = mask >> (offset % 8);
}
var result = 0;
if ((offset % 8) + bits >= 8) {
result = callback(0, inv(data[offsetBytes]) & mask, firstBits);
}
// read bytes
var bytes = (bits + offset) >> 3;
for (var i = offsetBytes + 1; i < bytes; i++) {
result = callback(result, inv(data[i]), 8);
}
// bits to read, that are not a complete byte
var lastBits = (bits + offset) % 8;
if (lastBits > 0) {
result = callback(result, inv(data[bytes]) >> (8 - lastBits), lastBits);
}
return result;
};
var parseFloatFromBits = function(data, precisionBits, exponentBits) {
var bias = Math.pow(2, exponentBits - 1) - 1;
var sign = parseBits(data, 1);
var exponent = parseBits(data, exponentBits, 1);
if (exponent === 0) {
return 0;
}
// parse mantissa
var precisionBitsCounter = 1;
var parsePrecisionBits = function(lastValue, newValue, bits) {
if (lastValue === 0) {
lastValue = 1;
}
for (var i = 1; i <= bits; i++) {
precisionBitsCounter /= 2;
if ((newValue & (0x1 << (bits - i))) > 0) {
lastValue += precisionBitsCounter;
}
}
return lastValue;
};
var mantissa = parseBits(data, precisionBits, exponentBits + 1, false, parsePrecisionBits);
// special cases
if (exponent == (Math.pow(2, exponentBits + 1) - 1)) {
if (mantissa === 0) {
return (sign === 0) ? Infinity : -Infinity;
}
return NaN;
}
// normale number
return ((sign === 0) ? 1 : -1) * Math.pow(2, exponent - bias) * mantissa;
};
var parseInt16 = function(value) {
if (parseBits(value, 1) == 1) {
return -1 * (parseBits(value, 15, 1, true) + 1);
}
return parseBits(value, 15, 1);
};
var parseInt32 = function(value) {
if (parseBits(value, 1) == 1) {
return -1 * (parseBits(value, 31, 1, true) + 1);
}
return parseBits(value, 31, 1);
};
var parseFloat32 = function(value) {
return parseFloatFromBits(value, 23, 8);
};
var parseFloat64 = function(value) {
return parseFloatFromBits(value, 52, 11);
};
var parseNumeric = function(value) {
var sign = parseBits(value, 16, 32);
if (sign == 0xc000) {
return NaN;
}
var weight = Math.pow(10000, parseBits(value, 16, 16));
var result = 0;
var digits = [];
var ndigits = parseBits(value, 16);
for (var i = 0; i < ndigits; i++) {
result += parseBits(value, 16, 64 + (16 * i)) * weight;
weight /= 10000;
}
var scale = Math.pow(10, parseBits(value, 16, 48));
return ((sign === 0) ? 1 : -1) * Math.round(result * scale) / scale;
};
var parseDate = function(isUTC, value) {
var sign = parseBits(value, 1);
var rawValue = parseBits(value, 63, 1);
// discard usecs and shift from 2000 to 1970
var result = new Date((((sign === 0) ? 1 : -1) * rawValue / 1000) + 946684800000);
if (!isUTC) {
result.setTime(result.getTime() + result.getTimezoneOffset() * 60000);
}
// add microseconds to the date
result.usec = rawValue % 1000;
result.getMicroSeconds = function() {
return this.usec;
};
result.setMicroSeconds = function(value) {
this.usec = value;
};
result.getUTCMicroSeconds = function() {
return this.usec;
};
return result;
};
var parseArray = function(value) {
var dim = parseBits(value, 32);
var flags = parseBits(value, 32, 32);
var elementType = parseBits(value, 32, 64);
var offset = 96;
var dims = [];
for (var i = 0; i < dim; i++) {
// parse dimension
dims[i] = parseBits(value, 32, offset);
offset += 32;
// ignore lower bounds
offset += 32;
}
var parseElement = function(elementType) {
// parse content length
var length = parseBits(value, 32, offset);
offset += 32;
// parse null values
if (length == 0xffffffff) {
return null;
}
var result;
if ((elementType == 0x17) || (elementType == 0x14)) {
// int/bigint
result = parseBits(value, length * 8, offset);
offset += length * 8;
return result;
}
else if (elementType == 0x19) {
// string
result = value.toString(this.encoding, offset >> 3, (offset += (length << 3)) >> 3);
return result;
}
else {
console.log("ERROR: ElementType not implemented: " + elementType);
}
};
var parse = function(dimension, elementType) {
var array = [];
var i;
if (dimension.length > 1) {
var count = dimension.shift();
for (i = 0; i < count; i++) {
array[i] = parse(dimension, elementType);
}
dimension.unshift(count);
}
else {
for (i = 0; i < dimension[0]; i++) {
array[i] = parseElement(elementType);
}
}
return array;
};
return parse(dims, elementType);
};
var parseText = function(value) {
return value.toString('utf8');
};
var parseBool = function(value) {
if(value === null) return null;
return (parseBits(value, 8) > 0);
};
var init = function(register) {
register(20, parseInt64);
register(21, parseInt16);
register(23, parseInt32);
register(26, parseInt32);
register(1700, parseNumeric);
register(700, parseFloat32);
register(701, parseFloat64);
register(16, parseBool);
register(1114, parseDate.bind(null, false));
register(1184, parseDate.bind(null, true));
register(1000, parseArray);
register(1007, parseArray);
register(1016, parseArray);
register(1008, parseArray);
register(1009, parseArray);
register(25, parseText);
};
module.exports = {
init: init
};

View File

@@ -0,0 +1,5 @@
import { GraphQLScalarType } from 'graphql';
export declare const GraphQLLongConfig: import("graphql").GraphQLScalarTypeConfig<number | bigint, string | number | bigint> & {
name: string;
};
export declare const GraphQLLong: GraphQLScalarType<number | bigint, string | number | bigint>;

View File

@@ -0,0 +1,45 @@
import { Component } from "react";
import { TransitionProps } from "./Transition";
export interface CSSTransitionClassNames {
appear?: string | undefined;
appearActive?: string | undefined;
appearDone?: string | undefined;
enter?: string | undefined;
enterActive?: string | undefined;
enterDone?: string | undefined;
exit?: string | undefined;
exitActive?: string | undefined;
exitDone?: string | undefined;
}
export type CSSTransitionProps<Ref extends undefined | HTMLElement = undefined> = TransitionProps<Ref> & {
/**
* The animation `classNames` applied to the component as it enters or exits.
* A single name can be provided and it will be suffixed for each stage: e.g.
*
* `classNames="fade"` applies `fade-enter`, `fade-enter-active`,
* `fade-exit`, `fade-exit-active`, `fade-appear`, and `fade-appear-active`.
*
* Each individual classNames can also be specified independently like:
*
* ```js
* classNames={{
* appear: 'my-appear',
* appearActive: 'my-appear-active',
* appearDone: 'my-appear-done',
* enter: 'my-enter',
* enterActive: 'my-enter-active',
* enterDone: 'my-enter-done',
* exit: 'my-exit',
* exitActive: 'my-exit-active',
* exitDone: 'my-exit-done'
* }}
* ```
*/
classNames?: string | CSSTransitionClassNames | undefined;
};
declare class CSSTransition<Ref extends undefined | HTMLElement> extends Component<CSSTransitionProps<Ref>> {}
export default CSSTransition;

View File

@@ -0,0 +1,51 @@
import { NestedPartial, UnpackList } from "../../../types/utils.cjs";
import { CollectionType } from "../../../types/schema.cjs";
import { ApplyQueryFields } from "../../../types/output.cjs";
import { Query } from "../../../types/query.cjs";
import { RestCommand } from "../../types.cjs";
//#region src/rest/commands/update/items.d.ts
type UpdateItemOutput<Schema, Collection extends keyof Schema, TQuery extends Query<Schema, Schema[Collection]>> = ApplyQueryFields<Schema, CollectionType<Schema, Collection>, TQuery['fields']>;
/**
* Update multiple items at the same time.
*
* @param collection The collection of the items
* @param keysOrQuery The primary keys or a query
* @param item The item data to update
* @param query Optional return data query
*
* @returns Returns the item objects for the updated items.
* @throws Will throw if keysOrQuery is empty
* @throws Will throw if collection is empty
* @throws Will throw if collection is a core collection
*/
declare const updateItems: <Schema, Collection extends keyof Schema, const TQuery extends Query<Schema, Schema[Collection]>>(collection: Collection, keysOrQuery: string[] | number[] | Query<Schema, Schema[Collection]>, item: NestedPartial<UnpackList<Schema[Collection]>>, query?: TQuery) => RestCommand<UpdateItemOutput<Schema, Collection, TQuery>[], Schema>;
/**
* Update multiple items as batch.
*
* @param collection The collection of the items
* @param items The items to update
* @param query Optional return data query
*
* @returns Returns the item objects for the updated items.
* @throws Will throw if collection is empty
* @throws Will throw if collection is a core collection
*/
declare const updateItemsBatch: <Schema, Collection extends keyof Schema, const TQuery extends Query<Schema, Schema[Collection]>>(collection: Collection, items: NestedPartial<UnpackList<Schema[Collection]>>[], query?: TQuery) => RestCommand<UpdateItemOutput<Schema, Collection, TQuery>[], Schema>;
/**
* Update an existing item.
*
* @param collection The collection of the item
* @param key The primary key of the item
* @param item The item data to update
* @param query Optional return data query
*
* @returns Returns the item object of the item that was updated.
* @throws Will throw if key is empty
* @throws Will throw if collection is empty
* @throws Will throw if collection is a core collection
*/
declare const updateItem: <Schema, Collection extends keyof Schema, const TQuery extends Query<Schema, Schema[Collection]>, Item = UnpackList<Schema[Collection]>>(collection: Collection, key: string | number, item: NestedPartial<Item>, query?: TQuery) => RestCommand<UpdateItemOutput<Schema, Collection, TQuery>, Schema>;
//#endregion
export { UpdateItemOutput, updateItem, updateItems, updateItemsBatch };
//# sourceMappingURL=items.d.cts.map

View File

@@ -0,0 +1,52 @@
"use strict";
var __defProp = Object.defineProperty;
var __getOwnPropDesc = Object.getOwnPropertyDescriptor;
var __getOwnPropNames = Object.getOwnPropertyNames;
var __hasOwnProp = Object.prototype.hasOwnProperty;
var __export = (target, all) => {
for (var name in all)
__defProp(target, name, { get: all[name], enumerable: true });
};
var __copyProps = (to, from, except, desc) => {
if (from && typeof from === "object" || typeof from === "function") {
for (let key of __getOwnPropNames(from))
if (!__hasOwnProp.call(to, key) && key !== except)
__defProp(to, key, { get: () => from[key], enumerable: !(desc = __getOwnPropDesc(from, key)) || desc.enumerable });
}
return to;
};
var __toCommonJS = (mod) => __copyProps(__defProp({}, "__esModule", { value: true }), mod);
var sequence_exports = {};
__export(sequence_exports, {
PgSequence: () => PgSequence,
isPgSequence: () => isPgSequence,
pgSequence: () => pgSequence,
pgSequenceWithSchema: () => pgSequenceWithSchema
});
module.exports = __toCommonJS(sequence_exports);
var import_entity = require("../entity.cjs");
class PgSequence {
constructor(seqName, seqOptions, schema) {
this.seqName = seqName;
this.seqOptions = seqOptions;
this.schema = schema;
}
static [import_entity.entityKind] = "PgSequence";
}
function pgSequence(name, options) {
return pgSequenceWithSchema(name, options, void 0);
}
function pgSequenceWithSchema(name, options, schema) {
return new PgSequence(name, options, schema);
}
function isPgSequence(obj) {
return (0, import_entity.is)(obj, PgSequence);
}
// Annotate the CommonJS export names for ESM import in node:
0 && (module.exports = {
PgSequence,
isPgSequence,
pgSequence,
pgSequenceWithSchema
});
//# sourceMappingURL=sequence.cjs.map

View File

@@ -0,0 +1 @@
{"version":3,"file":"traverseFields.d.ts","sourceRoot":"","sources":["../../../../src/fields/hooks/beforeValidate/traverseFields.ts"],"names":[],"mappings":"AAAA,OAAO,KAAK,EAAE,yBAAyB,EAAE,MAAM,sCAAsC,CAAA;AACrF,OAAO,KAAK,EAAE,qBAAqB,EAAE,MAAM,kCAAkC,CAAA;AAC7E,OAAO,KAAK,EAAE,cAAc,EAAE,MAAM,mBAAmB,CAAA;AACvD,OAAO,KAAK,EAAE,UAAU,EAAE,cAAc,EAAE,MAAM,yBAAyB,CAAA;AACzE,OAAO,KAAK,EAAE,KAAK,EAAE,UAAU,EAAE,MAAM,uBAAuB,CAAA;AAI9D,KAAK,IAAI,CAAC,CAAC,IAAI;IACb;;OAEG;IACH,SAAS,CAAC,EAAE,UAAU,CAAA;IACtB,UAAU,EAAE,IAAI,GAAG,yBAAyB,CAAA;IAC5C,OAAO,EAAE,cAAc,CAAA;IACvB,IAAI,EAAE,CAAC,CAAA;IACP;;OAEG;IACH,GAAG,EAAE,CAAC,CAAA;IACN,MAAM,EAAE,CAAC,KAAK,GAAG,UAAU,CAAC,EAAE,CAAA;IAC9B,MAAM,EAAE,IAAI,GAAG,qBAAqB,CAAA;IACpC,EAAE,CAAC,EAAE,MAAM,GAAG,MAAM,CAAA;IACpB,SAAS,EAAE,QAAQ,GAAG,QAAQ,CAAA;IAC9B,cAAc,EAAE,OAAO,CAAA;IACvB,eAAe,EAAE,MAAM,CAAA;IACvB;;OAEG;IACH,iBAAiB,CAAC,EAAE,OAAO,CAAA;IAC3B,UAAU,EAAE,MAAM,CAAA;IAClB,gBAAgB,EAAE,MAAM,CAAA;IACxB,GAAG,EAAE,cAAc,CAAA;IACnB,WAAW,EAAE,UAAU,CAAA;IACvB;;OAEG;IACH,UAAU,EAAE,UAAU,CAAA;CACvB,CAAA;AAED,eAAO,MAAM,cAAc,GAAU,CAAC,iMAkBnC,IAAI,CAAC,CAAC,CAAC,KAAG,OAAO,CAAC,IAAI,CA8BxB,CAAA"}

View File

@@ -0,0 +1,209 @@
import cjs from "./sass.node.js";
export const compile = cjs.compile;
export const compileAsync = cjs.compileAsync;
export const compileString = cjs.compileString;
export const compileStringAsync = cjs.compileStringAsync;
export const initCompiler = cjs.initCompiler;
export const initAsyncCompiler = cjs.initAsyncCompiler;
export const Compiler = cjs.Compiler;
export const AsyncCompiler = cjs.AsyncCompiler;
export const Logger = cjs.Logger;
export const SassArgumentList = cjs.SassArgumentList;
export const SassBoolean = cjs.SassBoolean;
export const SassCalculation = cjs.SassCalculation;
export const CalculationOperation = cjs.CalculationOperation;
export const CalculationInterpolation = cjs.CalculationInterpolation;
export const SassColor = cjs.SassColor;
export const SassFunction = cjs.SassFunction;
export const SassList = cjs.SassList;
export const SassMap = cjs.SassMap;
export const SassMixin = cjs.SassMixin;
export const SassNumber = cjs.SassNumber;
export const SassString = cjs.SassString;
export const Value = cjs.Value;
export const CustomFunction = cjs.CustomFunction;
export const ListSeparator = cjs.ListSeparator;
export const sassFalse = cjs.sassFalse;
export const sassNull = cjs.sassNull;
export const sassTrue = cjs.sassTrue;
export const Exception = cjs.Exception;
export const PromiseOr = cjs.PromiseOr;
export const info = cjs.info;
export const render = cjs.render;
export const renderSync = cjs.renderSync;
export const TRUE = cjs.TRUE;
export const FALSE = cjs.FALSE;
export const NULL = cjs.NULL;
export const types = cjs.types;
export const NodePackageImporter = cjs.NodePackageImporter;
export const deprecations = cjs.deprecations;
export const Version = cjs.Version;
let printedDefaultExportDeprecation = false;
function defaultExportDeprecation() {
if (printedDefaultExportDeprecation) return;
printedDefaultExportDeprecation = true;
console.error(
"`import sass from 'sass'` is deprecated.\n" +
"Please use `import * as sass from 'sass'` instead.");
}
export default {
get compile() {
defaultExportDeprecation();
return cjs.compile;
},
get compileAsync() {
defaultExportDeprecation();
return cjs.compileAsync;
},
get compileString() {
defaultExportDeprecation();
return cjs.compileString;
},
get compileStringAsync() {
defaultExportDeprecation();
return cjs.compileStringAsync;
},
get initCompiler() {
defaultExportDeprecation();
return cjs.initCompiler;
},
get initAsyncCompiler() {
defaultExportDeprecation();
return cjs.initAsyncCompiler;
},
get Compiler() {
defaultExportDeprecation();
return cjs.Compiler;
},
get AsyncCompiler() {
defaultExportDeprecation();
return cjs.AsyncCompiler;
},
get Logger() {
defaultExportDeprecation();
return cjs.Logger;
},
get SassArgumentList() {
defaultExportDeprecation();
return cjs.SassArgumentList;
},
get SassBoolean() {
defaultExportDeprecation();
return cjs.SassBoolean;
},
get SassCalculation() {
defaultExportDeprecation();
return cjs.SassCalculation;
},
get CalculationOperation() {
defaultExportDeprecation();
return cjs.CalculationOperation;
},
get CalculationInterpolation() {
defaultExportDeprecation();
return cjs.CalculationInterpolation;
},
get SassColor() {
defaultExportDeprecation();
return cjs.SassColor;
},
get SassFunction() {
defaultExportDeprecation();
return cjs.SassFunction;
},
get SassList() {
defaultExportDeprecation();
return cjs.SassList;
},
get SassMap() {
defaultExportDeprecation();
return cjs.SassMap;
},
get SassMixin() {
defaultExportDeprecation();
return cjs.SassMixin;
},
get SassNumber() {
defaultExportDeprecation();
return cjs.SassNumber;
},
get SassString() {
defaultExportDeprecation();
return cjs.SassString;
},
get Value() {
defaultExportDeprecation();
return cjs.Value;
},
get CustomFunction() {
defaultExportDeprecation();
return cjs.CustomFunction;
},
get ListSeparator() {
defaultExportDeprecation();
return cjs.ListSeparator;
},
get sassFalse() {
defaultExportDeprecation();
return cjs.sassFalse;
},
get sassNull() {
defaultExportDeprecation();
return cjs.sassNull;
},
get sassTrue() {
defaultExportDeprecation();
return cjs.sassTrue;
},
get Exception() {
defaultExportDeprecation();
return cjs.Exception;
},
get PromiseOr() {
defaultExportDeprecation();
return cjs.PromiseOr;
},
get info() {
defaultExportDeprecation();
return cjs.info;
},
get render() {
defaultExportDeprecation();
return cjs.render;
},
get renderSync() {
defaultExportDeprecation();
return cjs.renderSync;
},
get TRUE() {
defaultExportDeprecation();
return cjs.TRUE;
},
get FALSE() {
defaultExportDeprecation();
return cjs.FALSE;
},
get NULL() {
defaultExportDeprecation();
return cjs.NULL;
},
get types() {
defaultExportDeprecation();
return cjs.types;
},
get NodePackageImporter() {
defaultExportDeprecation();
return cjs.NodePackageImporter;
},
get deprecations() {
defaultExportDeprecation();
return cjs.deprecations;
},
get Version() {
defaultExportDeprecation();
return cjs.Version;
},
};

View File

@@ -0,0 +1,9 @@
import { _ as _array_with_holes } from "./_array_with_holes.js";
import { _ as _iterable_to_array_limit_loose } from "./_iterable_to_array_limit_loose.js";
import { _ as _non_iterable_rest } from "./_non_iterable_rest.js";
import { _ as _unsupported_iterable_to_array } from "./_unsupported_iterable_to_array.js";
function _sliced_to_array_loose(arr, i) {
return _array_with_holes(arr) || _iterable_to_array_limit_loose(arr, i) || _unsupported_iterable_to_array(arr, i) || _non_iterable_rest();
}
export { _sliced_to_array_loose as _ };

View File

@@ -0,0 +1,2 @@
const e=(e={})=>()=>{let t={mode:e.mode??`cookie`};return t.mode===`json`&&e.refresh_token&&(t.refresh_token=e.refresh_token),{path:`/auth/refresh`,method:`POST`,body:JSON.stringify(t)}};exports.refresh=e;
//# sourceMappingURL=refresh.cjs.map

View File

@@ -0,0 +1,59 @@
import type { ColumnBuilderBaseConfig } from "../../column-builder.js";
import type { ColumnBaseConfig } from "../../column.js";
import { entityKind } from "../../entity.js";
import { type Equal } from "../../utils.js";
import { PgColumn, PgColumnBuilder } from "./common.js";
export type PgLineBuilderInitial<TName extends string> = PgLineBuilder<{
name: TName;
dataType: 'array';
columnType: 'PgLine';
data: [number, number, number];
driverParam: number | string;
enumValues: undefined;
}>;
export declare class PgLineBuilder<T extends ColumnBuilderBaseConfig<'array', 'PgLine'>> extends PgColumnBuilder<T> {
static readonly [entityKind]: string;
constructor(name: T['name']);
}
export declare class PgLineTuple<T extends ColumnBaseConfig<'array', 'PgLine'>> extends PgColumn<T> {
static readonly [entityKind]: string;
getSQLType(): string;
mapFromDriverValue(value: string): [number, number, number];
mapToDriverValue(value: [number, number, number]): string;
}
export type PgLineABCBuilderInitial<TName extends string> = PgLineABCBuilder<{
name: TName;
dataType: 'json';
columnType: 'PgLineABC';
data: {
a: number;
b: number;
c: number;
};
driverParam: string;
enumValues: undefined;
}>;
export declare class PgLineABCBuilder<T extends ColumnBuilderBaseConfig<'json', 'PgLineABC'>> extends PgColumnBuilder<T> {
static readonly [entityKind]: string;
constructor(name: T['name']);
}
export declare class PgLineABC<T extends ColumnBaseConfig<'json', 'PgLineABC'>> extends PgColumn<T> {
static readonly [entityKind]: string;
getSQLType(): string;
mapFromDriverValue(value: string): {
a: number;
b: number;
c: number;
};
mapToDriverValue(value: {
a: number;
b: number;
c: number;
}): string;
}
export interface PgLineTypeConfig<T extends 'tuple' | 'abc' = 'tuple' | 'abc'> {
mode?: T;
}
export declare function line(): PgLineBuilderInitial<''>;
export declare function line<TMode extends PgLineTypeConfig['mode'] & {}>(config?: PgLineTypeConfig<TMode>): Equal<TMode, 'abc'> extends true ? PgLineABCBuilderInitial<''> : PgLineBuilderInitial<''>;
export declare function line<TName extends string, TMode extends PgLineTypeConfig['mode'] & {}>(name: TName, config?: PgLineTypeConfig<TMode>): Equal<TMode, 'abc'> extends true ? PgLineABCBuilderInitial<TName> : PgLineBuilderInitial<TName>;

View File

@@ -0,0 +1,7 @@
/** @jsx jsx */
import { FocusEventHandler, FunctionComponent } from 'react';
declare const RequiredInput: FunctionComponent<{
readonly name?: string;
readonly onFocus: FocusEventHandler<HTMLInputElement>;
}>;
export default RequiredInput;

View File

@@ -0,0 +1,21 @@
The MIT License (MIT)
Copyright (c) 2020 Kevin Jahns <kevin.jahns@protonmail.com>.
Permission is hereby granted, free of charge, to any person obtaining a copy
of this software and associated documentation files (the "Software"), to deal
in the Software without restriction, including without limitation the rights
to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
copies of the Software, and to permit persons to whom the Software is
furnished to do so, subject to the following conditions:
The above copyright notice and this permission notice shall be included in all
copies or substantial portions of the Software.
THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE
SOFTWARE.

View File

@@ -0,0 +1,39 @@
import { buildFormatLongFn } from "../../_lib/buildFormatLongFn.mjs";
const dateFormats = {
full: "EEEE, do MMMM y 'il'",
long: "do MMMM y 'il'",
medium: "d MMM y 'il'",
short: "dd.MM.yyyy",
};
const timeFormats = {
full: "H:mm:ss zzzz",
long: "H:mm:ss z",
medium: "H:mm:ss",
short: "H:mm",
};
const dateTimeFormats = {
full: "{{date}} {{time}} - 'də'",
long: "{{date}} {{time}} - 'də'",
medium: "{{date}}, {{time}}",
short: "{{date}}, {{time}}",
};
export const formatLong = {
date: buildFormatLongFn({
formats: dateFormats,
defaultWidth: "full",
}),
time: buildFormatLongFn({
formats: timeFormats,
defaultWidth: "full",
}),
dateTime: buildFormatLongFn({
formats: dateTimeFormats,
defaultWidth: "full",
}),
};

Some files were not shown because too many files have changed in this diff Show More