@ptolemy2002/rgx 13.0.0 → 13.0.2
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
package/dist/constants.d.ts
CHANGED
package/dist/constants.js
CHANGED
|
@@ -1,2 +1,2 @@
|
|
|
1
1
|
import { RGXConvertibleToken, RGXToken } from "../types";
|
|
2
|
-
export declare function createRGXBounds(
|
|
2
|
+
export declare function createRGXBounds(positive: RGXToken, negative: RGXToken, flags?: string): [RGXConvertibleToken, RGXConvertibleToken];
|
|
@@ -22,10 +22,10 @@ function convertToBound(token) {
|
|
|
22
22
|
toRgx: () => token
|
|
23
23
|
};
|
|
24
24
|
}
|
|
25
|
-
function createRGXBounds(
|
|
26
|
-
const
|
|
27
|
-
const
|
|
28
|
-
const startBound = convertToBound((0, createRegex_1.createRegex)(`(?<=${
|
|
29
|
-
const endBound = convertToBound((0, createRegex_1.createRegex)(`(?<=${
|
|
25
|
+
function createRGXBounds(positive, negative, flags = "") {
|
|
26
|
+
const resolvedPositive = (0, resolve_1.resolveRGXToken)(convertNoGroupWrap(positive), { groupWrap: false, currentFlags: flags });
|
|
27
|
+
const resolvedNegative = (0, resolve_1.resolveRGXToken)(convertNoGroupWrap(negative), { groupWrap: false, currentFlags: flags });
|
|
28
|
+
const startBound = convertToBound((0, createRegex_1.createRegex)(`(?<=${resolvedNegative})(?=${resolvedPositive})`, flags, true));
|
|
29
|
+
const endBound = convertToBound((0, createRegex_1.createRegex)(`(?<=${resolvedPositive})(?=${resolvedNegative})`, flags, true));
|
|
30
30
|
return [startBound, endBound];
|
|
31
31
|
}
|