@nakafa/aksara-contracts 3.0.0 → 3.0.1
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/date.js +1 -1
- package/dist/quran/notes.js +1 -1
- package/package.json +1 -1
package/dist/date.js
CHANGED
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
import { DateTime, Schema } from "effect";
|
|
2
|
-
const DATE_ONLY_PATTERN =
|
|
2
|
+
const DATE_ONLY_PATTERN = /^\d{4}-\d{2}-\d{2}$/u;
|
|
3
3
|
/** Checks a source-authored date against the real ISO calendar. */
|
|
4
4
|
function isDateOnly(value) {
|
|
5
5
|
if (!DATE_ONLY_PATTERN.test(value)) {
|
package/dist/quran/notes.js
CHANGED
|
@@ -54,7 +54,7 @@ const QuranTranslationSourceSchema = Schema.Struct({
|
|
|
54
54
|
/** Reads every numeric marker without treating editorial brackets as notes. */
|
|
55
55
|
function readMarkers(source) {
|
|
56
56
|
const markers = MutableList.make();
|
|
57
|
-
for (const match of source.matchAll(/\[
|
|
57
|
+
for (const match of source.matchAll(/\[\d+\]/gu)) {
|
|
58
58
|
const rawNumber = match[0].slice(1, -1);
|
|
59
59
|
const start = match.index;
|
|
60
60
|
const number = Number(rawNumber);
|
package/package.json
CHANGED