@read-frog/definitions 0.1.4 → 0.3.0
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/index.d.ts +772 -21
- package/dist/index.d.ts.map +1 -1
- package/dist/index.js +840 -516
- package/dist/index.js.map +1 -1
- package/package.json +21 -9
- package/src/constants/dictionary.ts +1 -1
- package/src/constants/notebase-column.ts +2 -0
- package/src/index.ts +5 -2
- package/src/schemas/cell-value.ts +4 -4
- package/src/types/card.ts +73 -0
- package/src/types/language-names/en.ts +183 -0
- package/src/types/language-names/locale.ts +183 -0
- package/src/types/language-names/zh.ts +183 -0
- package/src/types/languages.ts +3 -363
- package/src/types/{column.ts → notebase-column.ts} +14 -14
- package/src/types/srs.ts +68 -0
- package/src/utils/srs-day.test.ts +132 -0
- package/src/utils/srs-day.ts +60 -0
- package/src/constants/column.ts +0 -2
package/dist/index.d.ts
CHANGED
|
@@ -16,9 +16,554 @@ declare const BETA_FEATURE_KEYS: readonly ["notebase"];
|
|
|
16
16
|
type BetaFeatureKey = (typeof BETA_FEATURE_KEYS)[number];
|
|
17
17
|
declare const NOTEBASE_BETA_FEATURE_KEY: "notebase";
|
|
18
18
|
//#endregion
|
|
19
|
-
//#region src/
|
|
20
|
-
declare const
|
|
21
|
-
|
|
19
|
+
//#region src/types/language-names/en.d.ts
|
|
20
|
+
declare const LANG_CODE_TO_EN_NAME: {
|
|
21
|
+
eng: string;
|
|
22
|
+
cmn: string;
|
|
23
|
+
"cmn-Hant": string;
|
|
24
|
+
yue: string;
|
|
25
|
+
spa: string;
|
|
26
|
+
rus: string;
|
|
27
|
+
arb: string;
|
|
28
|
+
ben: string;
|
|
29
|
+
hin: string;
|
|
30
|
+
por: string;
|
|
31
|
+
ind: string;
|
|
32
|
+
jpn: string;
|
|
33
|
+
fra: string;
|
|
34
|
+
deu: string;
|
|
35
|
+
jav: string;
|
|
36
|
+
kor: string;
|
|
37
|
+
tel: string;
|
|
38
|
+
vie: string;
|
|
39
|
+
mar: string;
|
|
40
|
+
ita: string;
|
|
41
|
+
tam: string;
|
|
42
|
+
tur: string;
|
|
43
|
+
urd: string;
|
|
44
|
+
guj: string;
|
|
45
|
+
pol: string;
|
|
46
|
+
ukr: string;
|
|
47
|
+
kan: string;
|
|
48
|
+
mai: string;
|
|
49
|
+
mal: string;
|
|
50
|
+
pes: string;
|
|
51
|
+
mya: string;
|
|
52
|
+
swh: string;
|
|
53
|
+
sun: string;
|
|
54
|
+
ron: string;
|
|
55
|
+
pan: string;
|
|
56
|
+
bho: string;
|
|
57
|
+
amh: string;
|
|
58
|
+
hau: string;
|
|
59
|
+
fuv: string;
|
|
60
|
+
bos: string;
|
|
61
|
+
hrv: string;
|
|
62
|
+
nld: string;
|
|
63
|
+
srp: string;
|
|
64
|
+
tha: string;
|
|
65
|
+
ckb: string;
|
|
66
|
+
yor: string;
|
|
67
|
+
uzn: string;
|
|
68
|
+
zlm: string;
|
|
69
|
+
ibo: string;
|
|
70
|
+
npi: string;
|
|
71
|
+
ceb: string;
|
|
72
|
+
skr: string;
|
|
73
|
+
tgl: string;
|
|
74
|
+
hun: string;
|
|
75
|
+
azj: string;
|
|
76
|
+
sin: string;
|
|
77
|
+
koi: string;
|
|
78
|
+
ell: string;
|
|
79
|
+
ces: string;
|
|
80
|
+
mag: string;
|
|
81
|
+
run: string;
|
|
82
|
+
bel: string;
|
|
83
|
+
plt: string;
|
|
84
|
+
qug: string;
|
|
85
|
+
mad: string;
|
|
86
|
+
nya: string;
|
|
87
|
+
zyb: string;
|
|
88
|
+
pbu: string;
|
|
89
|
+
kin: string;
|
|
90
|
+
zul: string;
|
|
91
|
+
bul: string;
|
|
92
|
+
swe: string;
|
|
93
|
+
lin: string;
|
|
94
|
+
som: string;
|
|
95
|
+
hms: string;
|
|
96
|
+
hnj: string;
|
|
97
|
+
ilo: string;
|
|
98
|
+
kaz: string;
|
|
99
|
+
heb: string;
|
|
100
|
+
nob: string;
|
|
101
|
+
nno: string;
|
|
102
|
+
afr: string;
|
|
103
|
+
sqi: string;
|
|
104
|
+
asm: string;
|
|
105
|
+
eus: string;
|
|
106
|
+
bre: string;
|
|
107
|
+
cat: string;
|
|
108
|
+
cos: string;
|
|
109
|
+
cym: string;
|
|
110
|
+
dan: string;
|
|
111
|
+
div: string;
|
|
112
|
+
epo: string;
|
|
113
|
+
ekk: string;
|
|
114
|
+
fao: string;
|
|
115
|
+
fij: string;
|
|
116
|
+
fin: string;
|
|
117
|
+
fry: string;
|
|
118
|
+
gla: string;
|
|
119
|
+
gle: string;
|
|
120
|
+
glg: string;
|
|
121
|
+
grn: string;
|
|
122
|
+
hat: string;
|
|
123
|
+
haw: string;
|
|
124
|
+
hye: string;
|
|
125
|
+
ido: string;
|
|
126
|
+
ina: string;
|
|
127
|
+
isl: string;
|
|
128
|
+
kat: string;
|
|
129
|
+
khm: string;
|
|
130
|
+
kir: string;
|
|
131
|
+
lao: string;
|
|
132
|
+
lat: string;
|
|
133
|
+
lvs: string;
|
|
134
|
+
lit: string;
|
|
135
|
+
ltz: string;
|
|
136
|
+
mkd: string;
|
|
137
|
+
mlt: string;
|
|
138
|
+
mon: string;
|
|
139
|
+
mri: string;
|
|
140
|
+
nso: string;
|
|
141
|
+
oci: string;
|
|
142
|
+
ori: string;
|
|
143
|
+
orm: string;
|
|
144
|
+
prs: string;
|
|
145
|
+
san: string;
|
|
146
|
+
slk: string;
|
|
147
|
+
slv: string;
|
|
148
|
+
smo: string;
|
|
149
|
+
sna: string;
|
|
150
|
+
snd: string;
|
|
151
|
+
sot: string;
|
|
152
|
+
tah: string;
|
|
153
|
+
tat: string;
|
|
154
|
+
tgk: string;
|
|
155
|
+
tir: string;
|
|
156
|
+
ton: string;
|
|
157
|
+
tsn: string;
|
|
158
|
+
tuk: string;
|
|
159
|
+
uig: string;
|
|
160
|
+
vol: string;
|
|
161
|
+
wol: string;
|
|
162
|
+
xho: string;
|
|
163
|
+
ydd: string;
|
|
164
|
+
aka: string;
|
|
165
|
+
bam: string;
|
|
166
|
+
bis: string;
|
|
167
|
+
bod: string;
|
|
168
|
+
che: string;
|
|
169
|
+
chv: string;
|
|
170
|
+
dzo: string;
|
|
171
|
+
ewe: string;
|
|
172
|
+
kab: string;
|
|
173
|
+
lug: string;
|
|
174
|
+
oss: string;
|
|
175
|
+
ssw: string;
|
|
176
|
+
ven: string;
|
|
177
|
+
war: string;
|
|
178
|
+
nde: string;
|
|
179
|
+
nbl: string;
|
|
180
|
+
pam: string;
|
|
181
|
+
hil: string;
|
|
182
|
+
bcl: string;
|
|
183
|
+
min: string;
|
|
184
|
+
ace: string;
|
|
185
|
+
bug: string;
|
|
186
|
+
ban: string;
|
|
187
|
+
bjn: string;
|
|
188
|
+
mak: string;
|
|
189
|
+
sas: string;
|
|
190
|
+
tet: string;
|
|
191
|
+
cha: string;
|
|
192
|
+
niu: string;
|
|
193
|
+
tvl: string;
|
|
194
|
+
gil: string;
|
|
195
|
+
mah: string;
|
|
196
|
+
pau: string;
|
|
197
|
+
wls: string;
|
|
198
|
+
rar: string;
|
|
199
|
+
hif: string;
|
|
200
|
+
};
|
|
201
|
+
//#endregion
|
|
202
|
+
//#region src/types/language-names/locale.d.ts
|
|
203
|
+
declare const LANG_CODE_TO_LOCALE_NAME: {
|
|
204
|
+
eng: string;
|
|
205
|
+
cmn: string;
|
|
206
|
+
"cmn-Hant": string;
|
|
207
|
+
yue: string;
|
|
208
|
+
spa: string;
|
|
209
|
+
rus: string;
|
|
210
|
+
arb: string;
|
|
211
|
+
ben: string;
|
|
212
|
+
hin: string;
|
|
213
|
+
por: string;
|
|
214
|
+
ind: string;
|
|
215
|
+
jpn: string;
|
|
216
|
+
fra: string;
|
|
217
|
+
deu: string;
|
|
218
|
+
jav: string;
|
|
219
|
+
kor: string;
|
|
220
|
+
tel: string;
|
|
221
|
+
vie: string;
|
|
222
|
+
mar: string;
|
|
223
|
+
ita: string;
|
|
224
|
+
tam: string;
|
|
225
|
+
tur: string;
|
|
226
|
+
urd: string;
|
|
227
|
+
guj: string;
|
|
228
|
+
pol: string;
|
|
229
|
+
ukr: string;
|
|
230
|
+
kan: string;
|
|
231
|
+
mai: string;
|
|
232
|
+
mal: string;
|
|
233
|
+
pes: string;
|
|
234
|
+
mya: string;
|
|
235
|
+
swh: string;
|
|
236
|
+
sun: string;
|
|
237
|
+
ron: string;
|
|
238
|
+
pan: string;
|
|
239
|
+
bho: string;
|
|
240
|
+
amh: string;
|
|
241
|
+
hau: string;
|
|
242
|
+
fuv: string;
|
|
243
|
+
bos: string;
|
|
244
|
+
hrv: string;
|
|
245
|
+
nld: string;
|
|
246
|
+
srp: string;
|
|
247
|
+
tha: string;
|
|
248
|
+
ckb: string;
|
|
249
|
+
yor: string;
|
|
250
|
+
uzn: string;
|
|
251
|
+
zlm: string;
|
|
252
|
+
ibo: string;
|
|
253
|
+
npi: string;
|
|
254
|
+
ceb: string;
|
|
255
|
+
skr: string;
|
|
256
|
+
tgl: string;
|
|
257
|
+
hun: string;
|
|
258
|
+
azj: string;
|
|
259
|
+
sin: string;
|
|
260
|
+
koi: string;
|
|
261
|
+
ell: string;
|
|
262
|
+
ces: string;
|
|
263
|
+
mag: string;
|
|
264
|
+
run: string;
|
|
265
|
+
bel: string;
|
|
266
|
+
plt: string;
|
|
267
|
+
qug: string;
|
|
268
|
+
mad: string;
|
|
269
|
+
nya: string;
|
|
270
|
+
zyb: string;
|
|
271
|
+
pbu: string;
|
|
272
|
+
kin: string;
|
|
273
|
+
zul: string;
|
|
274
|
+
bul: string;
|
|
275
|
+
swe: string;
|
|
276
|
+
lin: string;
|
|
277
|
+
som: string;
|
|
278
|
+
hms: string;
|
|
279
|
+
hnj: string;
|
|
280
|
+
ilo: string;
|
|
281
|
+
kaz: string;
|
|
282
|
+
heb: string;
|
|
283
|
+
nob: string;
|
|
284
|
+
nno: string;
|
|
285
|
+
afr: string;
|
|
286
|
+
sqi: string;
|
|
287
|
+
asm: string;
|
|
288
|
+
eus: string;
|
|
289
|
+
bre: string;
|
|
290
|
+
cat: string;
|
|
291
|
+
cos: string;
|
|
292
|
+
cym: string;
|
|
293
|
+
dan: string;
|
|
294
|
+
div: string;
|
|
295
|
+
epo: string;
|
|
296
|
+
ekk: string;
|
|
297
|
+
fao: string;
|
|
298
|
+
fij: string;
|
|
299
|
+
fin: string;
|
|
300
|
+
fry: string;
|
|
301
|
+
gla: string;
|
|
302
|
+
gle: string;
|
|
303
|
+
glg: string;
|
|
304
|
+
grn: string;
|
|
305
|
+
hat: string;
|
|
306
|
+
haw: string;
|
|
307
|
+
hye: string;
|
|
308
|
+
ido: string;
|
|
309
|
+
ina: string;
|
|
310
|
+
isl: string;
|
|
311
|
+
kat: string;
|
|
312
|
+
khm: string;
|
|
313
|
+
kir: string;
|
|
314
|
+
lao: string;
|
|
315
|
+
lat: string;
|
|
316
|
+
lvs: string;
|
|
317
|
+
lit: string;
|
|
318
|
+
ltz: string;
|
|
319
|
+
mkd: string;
|
|
320
|
+
mlt: string;
|
|
321
|
+
mon: string;
|
|
322
|
+
mri: string;
|
|
323
|
+
nso: string;
|
|
324
|
+
oci: string;
|
|
325
|
+
ori: string;
|
|
326
|
+
orm: string;
|
|
327
|
+
prs: string;
|
|
328
|
+
san: string;
|
|
329
|
+
slk: string;
|
|
330
|
+
slv: string;
|
|
331
|
+
smo: string;
|
|
332
|
+
sna: string;
|
|
333
|
+
snd: string;
|
|
334
|
+
sot: string;
|
|
335
|
+
tah: string;
|
|
336
|
+
tat: string;
|
|
337
|
+
tgk: string;
|
|
338
|
+
tir: string;
|
|
339
|
+
ton: string;
|
|
340
|
+
tsn: string;
|
|
341
|
+
tuk: string;
|
|
342
|
+
uig: string;
|
|
343
|
+
vol: string;
|
|
344
|
+
wol: string;
|
|
345
|
+
xho: string;
|
|
346
|
+
ydd: string;
|
|
347
|
+
aka: string;
|
|
348
|
+
bam: string;
|
|
349
|
+
bis: string;
|
|
350
|
+
bod: string;
|
|
351
|
+
che: string;
|
|
352
|
+
chv: string;
|
|
353
|
+
dzo: string;
|
|
354
|
+
ewe: string;
|
|
355
|
+
kab: string;
|
|
356
|
+
lug: string;
|
|
357
|
+
oss: string;
|
|
358
|
+
ssw: string;
|
|
359
|
+
ven: string;
|
|
360
|
+
war: string;
|
|
361
|
+
nde: string;
|
|
362
|
+
nbl: string;
|
|
363
|
+
pam: string;
|
|
364
|
+
hil: string;
|
|
365
|
+
bcl: string;
|
|
366
|
+
min: string;
|
|
367
|
+
ace: string;
|
|
368
|
+
bug: string;
|
|
369
|
+
ban: string;
|
|
370
|
+
bjn: string;
|
|
371
|
+
mak: string;
|
|
372
|
+
sas: string;
|
|
373
|
+
tet: string;
|
|
374
|
+
cha: string;
|
|
375
|
+
niu: string;
|
|
376
|
+
tvl: string;
|
|
377
|
+
gil: string;
|
|
378
|
+
mah: string;
|
|
379
|
+
pau: string;
|
|
380
|
+
wls: string;
|
|
381
|
+
rar: string;
|
|
382
|
+
hif: string;
|
|
383
|
+
};
|
|
384
|
+
//#endregion
|
|
385
|
+
//#region src/types/language-names/zh.d.ts
|
|
386
|
+
declare const LANG_CODE_TO_ZH_NAME: {
|
|
387
|
+
eng: string;
|
|
388
|
+
cmn: string;
|
|
389
|
+
"cmn-Hant": string;
|
|
390
|
+
yue: string;
|
|
391
|
+
spa: string;
|
|
392
|
+
rus: string;
|
|
393
|
+
arb: string;
|
|
394
|
+
ben: string;
|
|
395
|
+
hin: string;
|
|
396
|
+
por: string;
|
|
397
|
+
ind: string;
|
|
398
|
+
jpn: string;
|
|
399
|
+
fra: string;
|
|
400
|
+
deu: string;
|
|
401
|
+
jav: string;
|
|
402
|
+
kor: string;
|
|
403
|
+
tel: string;
|
|
404
|
+
vie: string;
|
|
405
|
+
mar: string;
|
|
406
|
+
ita: string;
|
|
407
|
+
tam: string;
|
|
408
|
+
tur: string;
|
|
409
|
+
urd: string;
|
|
410
|
+
guj: string;
|
|
411
|
+
pol: string;
|
|
412
|
+
ukr: string;
|
|
413
|
+
kan: string;
|
|
414
|
+
mai: string;
|
|
415
|
+
mal: string;
|
|
416
|
+
pes: string;
|
|
417
|
+
mya: string;
|
|
418
|
+
swh: string;
|
|
419
|
+
sun: string;
|
|
420
|
+
ron: string;
|
|
421
|
+
pan: string;
|
|
422
|
+
bho: string;
|
|
423
|
+
amh: string;
|
|
424
|
+
hau: string;
|
|
425
|
+
fuv: string;
|
|
426
|
+
bos: string;
|
|
427
|
+
hrv: string;
|
|
428
|
+
nld: string;
|
|
429
|
+
srp: string;
|
|
430
|
+
tha: string;
|
|
431
|
+
ckb: string;
|
|
432
|
+
yor: string;
|
|
433
|
+
uzn: string;
|
|
434
|
+
zlm: string;
|
|
435
|
+
ibo: string;
|
|
436
|
+
npi: string;
|
|
437
|
+
ceb: string;
|
|
438
|
+
skr: string;
|
|
439
|
+
tgl: string;
|
|
440
|
+
hun: string;
|
|
441
|
+
azj: string;
|
|
442
|
+
sin: string;
|
|
443
|
+
koi: string;
|
|
444
|
+
ell: string;
|
|
445
|
+
ces: string;
|
|
446
|
+
mag: string;
|
|
447
|
+
run: string;
|
|
448
|
+
bel: string;
|
|
449
|
+
plt: string;
|
|
450
|
+
qug: string;
|
|
451
|
+
mad: string;
|
|
452
|
+
nya: string;
|
|
453
|
+
zyb: string;
|
|
454
|
+
pbu: string;
|
|
455
|
+
kin: string;
|
|
456
|
+
zul: string;
|
|
457
|
+
bul: string;
|
|
458
|
+
swe: string;
|
|
459
|
+
lin: string;
|
|
460
|
+
som: string;
|
|
461
|
+
hms: string;
|
|
462
|
+
hnj: string;
|
|
463
|
+
ilo: string;
|
|
464
|
+
kaz: string;
|
|
465
|
+
heb: string;
|
|
466
|
+
nob: string;
|
|
467
|
+
nno: string;
|
|
468
|
+
afr: string;
|
|
469
|
+
sqi: string;
|
|
470
|
+
asm: string;
|
|
471
|
+
eus: string;
|
|
472
|
+
bre: string;
|
|
473
|
+
cat: string;
|
|
474
|
+
cos: string;
|
|
475
|
+
cym: string;
|
|
476
|
+
dan: string;
|
|
477
|
+
div: string;
|
|
478
|
+
epo: string;
|
|
479
|
+
ekk: string;
|
|
480
|
+
fao: string;
|
|
481
|
+
fij: string;
|
|
482
|
+
fin: string;
|
|
483
|
+
fry: string;
|
|
484
|
+
gla: string;
|
|
485
|
+
gle: string;
|
|
486
|
+
glg: string;
|
|
487
|
+
grn: string;
|
|
488
|
+
hat: string;
|
|
489
|
+
haw: string;
|
|
490
|
+
hye: string;
|
|
491
|
+
ido: string;
|
|
492
|
+
ina: string;
|
|
493
|
+
isl: string;
|
|
494
|
+
kat: string;
|
|
495
|
+
khm: string;
|
|
496
|
+
kir: string;
|
|
497
|
+
lao: string;
|
|
498
|
+
lat: string;
|
|
499
|
+
lvs: string;
|
|
500
|
+
lit: string;
|
|
501
|
+
ltz: string;
|
|
502
|
+
mkd: string;
|
|
503
|
+
mlt: string;
|
|
504
|
+
mon: string;
|
|
505
|
+
mri: string;
|
|
506
|
+
nso: string;
|
|
507
|
+
oci: string;
|
|
508
|
+
ori: string;
|
|
509
|
+
orm: string;
|
|
510
|
+
prs: string;
|
|
511
|
+
san: string;
|
|
512
|
+
slk: string;
|
|
513
|
+
slv: string;
|
|
514
|
+
smo: string;
|
|
515
|
+
sna: string;
|
|
516
|
+
snd: string;
|
|
517
|
+
sot: string;
|
|
518
|
+
tah: string;
|
|
519
|
+
tat: string;
|
|
520
|
+
tgk: string;
|
|
521
|
+
tir: string;
|
|
522
|
+
ton: string;
|
|
523
|
+
tsn: string;
|
|
524
|
+
tuk: string;
|
|
525
|
+
uig: string;
|
|
526
|
+
vol: string;
|
|
527
|
+
wol: string;
|
|
528
|
+
xho: string;
|
|
529
|
+
ydd: string;
|
|
530
|
+
aka: string;
|
|
531
|
+
bam: string;
|
|
532
|
+
bis: string;
|
|
533
|
+
bod: string;
|
|
534
|
+
che: string;
|
|
535
|
+
chv: string;
|
|
536
|
+
dzo: string;
|
|
537
|
+
ewe: string;
|
|
538
|
+
kab: string;
|
|
539
|
+
lug: string;
|
|
540
|
+
oss: string;
|
|
541
|
+
ssw: string;
|
|
542
|
+
ven: string;
|
|
543
|
+
war: string;
|
|
544
|
+
nde: string;
|
|
545
|
+
nbl: string;
|
|
546
|
+
pam: string;
|
|
547
|
+
hil: string;
|
|
548
|
+
bcl: string;
|
|
549
|
+
min: string;
|
|
550
|
+
ace: string;
|
|
551
|
+
bug: string;
|
|
552
|
+
ban: string;
|
|
553
|
+
bjn: string;
|
|
554
|
+
mak: string;
|
|
555
|
+
sas: string;
|
|
556
|
+
tet: string;
|
|
557
|
+
cha: string;
|
|
558
|
+
niu: string;
|
|
559
|
+
tvl: string;
|
|
560
|
+
gil: string;
|
|
561
|
+
mah: string;
|
|
562
|
+
pau: string;
|
|
563
|
+
wls: string;
|
|
564
|
+
rar: string;
|
|
565
|
+
hif: string;
|
|
566
|
+
};
|
|
22
567
|
//#endregion
|
|
23
568
|
//#region src/types/languages.d.ts
|
|
24
569
|
declare const LANG_CODE_ISO6393_OPTIONS: readonly ["eng", "cmn", "cmn-Hant", "yue", "spa", "rus", "arb", "ben", "hin", "por", "ind", "jpn", "fra", "deu", "jav", "kor", "tel", "vie", "mar", "ita", "tam", "tur", "urd", "guj", "pol", "ukr", "kan", "mai", "mal", "pes", "mya", "swh", "sun", "ron", "pan", "bho", "amh", "hau", "fuv", "bos", "hrv", "nld", "srp", "tha", "ckb", "yor", "uzn", "zlm", "ibo", "npi", "ceb", "skr", "tgl", "hun", "azj", "sin", "koi", "ell", "ces", "mag", "run", "bel", "plt", "qug", "mad", "nya", "zyb", "pbu", "kin", "zul", "bul", "swe", "lin", "som", "hms", "hnj", "ilo", "kaz", "heb", "nob", "nno", "afr", "sqi", "asm", "eus", "bre", "cat", "cos", "cym", "dan", "div", "epo", "ekk", "fao", "fij", "fin", "fry", "gla", "gle", "glg", "grn", "hat", "haw", "hye", "ido", "ina", "isl", "kat", "khm", "kir", "lao", "lat", "lvs", "lit", "ltz", "mkd", "mlt", "mon", "mri", "nso", "oci", "ori", "orm", "prs", "san", "slk", "slv", "smo", "sna", "snd", "sot", "tah", "tat", "tgk", "tir", "ton", "tsn", "tuk", "uig", "vol", "wol", "xho", "ydd", "aka", "bam", "bis", "bod", "che", "chv", "dzo", "ewe", "kab", "lug", "oss", "ssw", "ven", "war", "nde", "nbl", "pam", "hil", "bcl", "min", "ace", "bug", "ban", "bjn", "mak", "sas", "tet", "cha", "niu", "tvl", "gil", "mah", "pau", "wls", "rar", "hif"];
|
|
@@ -205,6 +750,7 @@ declare const langCodeISO6393Schema: z.ZodEnum<{
|
|
|
205
750
|
hif: "hif";
|
|
206
751
|
}>;
|
|
207
752
|
declare const langCodeISO6391Schema: z.ZodEnum<{
|
|
753
|
+
id: "id";
|
|
208
754
|
en: "en";
|
|
209
755
|
zh: "zh";
|
|
210
756
|
"zh-TW": "zh-TW";
|
|
@@ -214,7 +760,6 @@ declare const langCodeISO6391Schema: z.ZodEnum<{
|
|
|
214
760
|
bn: "bn";
|
|
215
761
|
hi: "hi";
|
|
216
762
|
pt: "pt";
|
|
217
|
-
id: "id";
|
|
218
763
|
ja: "ja";
|
|
219
764
|
fr: "fr";
|
|
220
765
|
de: "de";
|
|
@@ -348,8 +893,6 @@ declare const langCodeISO6391Schema: z.ZodEnum<{
|
|
|
348
893
|
}>;
|
|
349
894
|
type LangCodeISO6391 = z.infer<typeof langCodeISO6391Schema>;
|
|
350
895
|
type LangCodeISO6393 = z.infer<typeof langCodeISO6393Schema>;
|
|
351
|
-
declare const LANG_CODE_TO_EN_NAME: Record<LangCodeISO6393, string>;
|
|
352
|
-
declare const LANG_CODE_TO_LOCALE_NAME: Record<LangCodeISO6393, string>;
|
|
353
896
|
declare const ISO6393_TO_6391: Record<LangCodeISO6393, LangCodeISO6391 | undefined>;
|
|
354
897
|
declare const LOCALE_TO_ISO6393: Partial<Record<LangCodeISO6391, LangCodeISO6393>>;
|
|
355
898
|
declare const langLevel: z.ZodEnum<{
|
|
@@ -379,19 +922,23 @@ interface DictionaryFieldLabels {
|
|
|
379
922
|
}
|
|
380
923
|
declare const LANG_DICTIONARY_LABELS: Record<LangCodeISO6393, DictionaryFieldLabels>;
|
|
381
924
|
//#endregion
|
|
925
|
+
//#region src/constants/notebase-column.d.ts
|
|
926
|
+
declare const NOTEBASE_COLUMN_MIN_WIDTH = 100;
|
|
927
|
+
declare const NOTEBASE_COLUMN_MAX_WIDTH = 500;
|
|
928
|
+
//#endregion
|
|
382
929
|
//#region src/constants/url.d.ts
|
|
383
930
|
declare const CHROME_EXTENSION_ORIGIN = "chrome-extension://modkelfkcfjpgbfmnbnllalkiogfofhb";
|
|
384
931
|
declare const EDGE_EXTENSION_ORIGIN = "extension://cbcbomlgikfbdnoaohcjfledcoklcjbo";
|
|
385
932
|
//#endregion
|
|
386
|
-
//#region src/types/column.d.ts
|
|
387
|
-
declare const
|
|
388
|
-
type
|
|
389
|
-
declare const
|
|
933
|
+
//#region src/types/notebase-column.d.ts
|
|
934
|
+
declare const NOTEBASE_COLUMN_TYPES: readonly ["string", "number", "boolean", "date", "select"];
|
|
935
|
+
type NotebaseColumnType = (typeof NOTEBASE_COLUMN_TYPES)[number];
|
|
936
|
+
declare const notebaseSelectOptionSchema: z.ZodObject<{
|
|
390
937
|
id: z.ZodString;
|
|
391
938
|
value: z.ZodString;
|
|
392
939
|
color: z.ZodString;
|
|
393
940
|
}, z.core.$strip>;
|
|
394
|
-
declare const
|
|
941
|
+
declare const notebaseColumnConfigSchema: z.ZodDiscriminatedUnion<[z.ZodObject<{
|
|
395
942
|
type: z.ZodLiteral<"string">;
|
|
396
943
|
}, z.core.$strip>, z.ZodObject<{
|
|
397
944
|
type: z.ZodLiteral<"number">;
|
|
@@ -414,16 +961,16 @@ declare const columnConfigSchema: z.ZodDiscriminatedUnion<[z.ZodObject<{
|
|
|
414
961
|
color: z.ZodString;
|
|
415
962
|
}, z.core.$strip>>>;
|
|
416
963
|
}, z.core.$strip>], "type">;
|
|
417
|
-
type
|
|
418
|
-
type
|
|
419
|
-
declare const
|
|
964
|
+
type NotebaseColumnConfig = z.infer<typeof notebaseColumnConfigSchema>;
|
|
965
|
+
type NotebaseSelectOption = z.infer<typeof notebaseSelectOptionSchema>;
|
|
966
|
+
declare const NOTEBASE_COLUMN_TYPE_INFO: Record<NotebaseColumnType, {
|
|
420
967
|
label: string;
|
|
421
|
-
defaultConfig:
|
|
968
|
+
defaultConfig: NotebaseColumnConfig;
|
|
422
969
|
}>;
|
|
423
|
-
declare function isNumberConfig(config:
|
|
970
|
+
declare function isNumberConfig(config: NotebaseColumnConfig): config is Extract<NotebaseColumnConfig, {
|
|
424
971
|
type: "number";
|
|
425
972
|
}>;
|
|
426
|
-
declare function isSelectConfig(config:
|
|
973
|
+
declare function isSelectConfig(config: NotebaseColumnConfig): config is Extract<NotebaseColumnConfig, {
|
|
427
974
|
type: "select";
|
|
428
975
|
}>;
|
|
429
976
|
//#endregion
|
|
@@ -432,7 +979,7 @@ declare function isSelectConfig(config: ColumnConfig): config is Extract<ColumnC
|
|
|
432
979
|
* Create a Zod schema for a cell value based on column config.
|
|
433
980
|
* All cell schemas are nullable (empty cells are valid).
|
|
434
981
|
*/
|
|
435
|
-
declare function createCellSchema(config:
|
|
982
|
+
declare function createCellSchema(config: NotebaseColumnConfig): z.ZodType;
|
|
436
983
|
/**
|
|
437
984
|
* Create a Zod schema for an entire row based on column definitions.
|
|
438
985
|
* Each column becomes a field in the object schema.
|
|
@@ -440,7 +987,7 @@ declare function createCellSchema(config: ColumnConfig): z.ZodType;
|
|
|
440
987
|
declare function createRowSchema(columns: Array<{
|
|
441
988
|
id: string;
|
|
442
989
|
name: string;
|
|
443
|
-
config:
|
|
990
|
+
config: NotebaseColumnConfig;
|
|
444
991
|
}>): z.ZodObject<Record<string, z.ZodType>>;
|
|
445
992
|
/**
|
|
446
993
|
* Convert row schema to JSON Schema for AI structured outputs.
|
|
@@ -449,7 +996,7 @@ declare function createRowSchema(columns: Array<{
|
|
|
449
996
|
declare function rowSchemaToJsonSchema(columns: Array<{
|
|
450
997
|
id: string;
|
|
451
998
|
name: string;
|
|
452
|
-
config:
|
|
999
|
+
config: NotebaseColumnConfig;
|
|
453
1000
|
}>): z.core.ZodStandardJSONSchemaPayload<z.ZodObject<Record<string, z.ZodType<unknown, unknown, z.core.$ZodTypeInternals<unknown, unknown>>>, z.core.$strip>>;
|
|
454
1001
|
//#endregion
|
|
455
1002
|
//#region src/schemas/version.d.ts
|
|
@@ -515,5 +1062,209 @@ declare function parseSemanticVersion(version: string): {
|
|
|
515
1062
|
*/
|
|
516
1063
|
declare function getVersionType(version: string): VersionType;
|
|
517
1064
|
//#endregion
|
|
518
|
-
|
|
1065
|
+
//#region src/types/card.d.ts
|
|
1066
|
+
declare const CARD_STATE_VALUES: readonly ["new", "learning", "review", "relearning"];
|
|
1067
|
+
declare const SCHEDULE_STATUS_VALUES: readonly ["new", "learning", "review", "suspended", "buried"];
|
|
1068
|
+
declare const cardStateSchema: z.ZodEnum<{
|
|
1069
|
+
new: "new";
|
|
1070
|
+
learning: "learning";
|
|
1071
|
+
review: "review";
|
|
1072
|
+
relearning: "relearning";
|
|
1073
|
+
}>;
|
|
1074
|
+
type CardState = z.infer<typeof cardStateSchema>;
|
|
1075
|
+
declare const scheduleStatusSchema: z.ZodEnum<{
|
|
1076
|
+
new: "new";
|
|
1077
|
+
learning: "learning";
|
|
1078
|
+
review: "review";
|
|
1079
|
+
suspended: "suspended";
|
|
1080
|
+
buried: "buried";
|
|
1081
|
+
}>;
|
|
1082
|
+
type ScheduleStatus = z.infer<typeof scheduleStatusSchema>;
|
|
1083
|
+
declare const CARD_STATE_TO_SCHEDULE_STATUS: {
|
|
1084
|
+
new: "new";
|
|
1085
|
+
learning: "learning";
|
|
1086
|
+
relearning: "learning";
|
|
1087
|
+
review: "review";
|
|
1088
|
+
};
|
|
1089
|
+
declare const basicCardTemplateConfigSchema: z.ZodObject<{
|
|
1090
|
+
type: z.ZodLiteral<"basic">;
|
|
1091
|
+
frontPattern: z.ZodString;
|
|
1092
|
+
backPattern: z.ZodString;
|
|
1093
|
+
}, z.core.$strict>;
|
|
1094
|
+
declare const cardTemplateConfigSchema: z.ZodDiscriminatedUnion<[z.ZodObject<{
|
|
1095
|
+
type: z.ZodLiteral<"basic">;
|
|
1096
|
+
frontPattern: z.ZodString;
|
|
1097
|
+
backPattern: z.ZodString;
|
|
1098
|
+
}, z.core.$strict>], "type">;
|
|
1099
|
+
type BasicCardTemplateConfig = z.infer<typeof basicCardTemplateConfigSchema>;
|
|
1100
|
+
type CardTemplateConfig = z.infer<typeof cardTemplateConfigSchema>;
|
|
1101
|
+
declare const cardIdentityShape: {
|
|
1102
|
+
id: z.ZodUUID;
|
|
1103
|
+
notebaseId: z.ZodUUID;
|
|
1104
|
+
notebaseRowId: z.ZodUUID;
|
|
1105
|
+
templateId: z.ZodUUID;
|
|
1106
|
+
variantKey: z.ZodString;
|
|
1107
|
+
};
|
|
1108
|
+
declare const cardReviewStateShape: {
|
|
1109
|
+
state: z.ZodEnum<{
|
|
1110
|
+
new: "new";
|
|
1111
|
+
learning: "learning";
|
|
1112
|
+
review: "review";
|
|
1113
|
+
relearning: "relearning";
|
|
1114
|
+
}>;
|
|
1115
|
+
scheduleStatus: z.ZodEnum<{
|
|
1116
|
+
new: "new";
|
|
1117
|
+
learning: "learning";
|
|
1118
|
+
review: "review";
|
|
1119
|
+
suspended: "suspended";
|
|
1120
|
+
buried: "buried";
|
|
1121
|
+
}>;
|
|
1122
|
+
dueAt: z.ZodCoercedDate<unknown>;
|
|
1123
|
+
lastReviewTime: z.ZodNullable<z.ZodCoercedDate<unknown>>;
|
|
1124
|
+
stability: z.ZodNumber;
|
|
1125
|
+
difficulty: z.ZodNumber;
|
|
1126
|
+
step: z.ZodNumber;
|
|
1127
|
+
lapses: z.ZodNumber;
|
|
1128
|
+
reps: z.ZodNumber;
|
|
1129
|
+
};
|
|
1130
|
+
declare const cardMemoryStateShape: {
|
|
1131
|
+
buriedAt: z.ZodNullable<z.ZodCoercedDate<unknown>>;
|
|
1132
|
+
state: z.ZodEnum<{
|
|
1133
|
+
new: "new";
|
|
1134
|
+
learning: "learning";
|
|
1135
|
+
review: "review";
|
|
1136
|
+
relearning: "relearning";
|
|
1137
|
+
}>;
|
|
1138
|
+
scheduleStatus: z.ZodEnum<{
|
|
1139
|
+
new: "new";
|
|
1140
|
+
learning: "learning";
|
|
1141
|
+
review: "review";
|
|
1142
|
+
suspended: "suspended";
|
|
1143
|
+
buried: "buried";
|
|
1144
|
+
}>;
|
|
1145
|
+
dueAt: z.ZodCoercedDate<unknown>;
|
|
1146
|
+
lastReviewTime: z.ZodNullable<z.ZodCoercedDate<unknown>>;
|
|
1147
|
+
stability: z.ZodNumber;
|
|
1148
|
+
difficulty: z.ZodNumber;
|
|
1149
|
+
step: z.ZodNumber;
|
|
1150
|
+
lapses: z.ZodNumber;
|
|
1151
|
+
reps: z.ZodNumber;
|
|
1152
|
+
};
|
|
1153
|
+
declare const cardReviewStateSchema: z.ZodObject<{
|
|
1154
|
+
state: z.ZodEnum<{
|
|
1155
|
+
new: "new";
|
|
1156
|
+
learning: "learning";
|
|
1157
|
+
review: "review";
|
|
1158
|
+
relearning: "relearning";
|
|
1159
|
+
}>;
|
|
1160
|
+
scheduleStatus: z.ZodEnum<{
|
|
1161
|
+
new: "new";
|
|
1162
|
+
learning: "learning";
|
|
1163
|
+
review: "review";
|
|
1164
|
+
suspended: "suspended";
|
|
1165
|
+
buried: "buried";
|
|
1166
|
+
}>;
|
|
1167
|
+
dueAt: z.ZodCoercedDate<unknown>;
|
|
1168
|
+
lastReviewTime: z.ZodNullable<z.ZodCoercedDate<unknown>>;
|
|
1169
|
+
stability: z.ZodNumber;
|
|
1170
|
+
difficulty: z.ZodNumber;
|
|
1171
|
+
step: z.ZodNumber;
|
|
1172
|
+
lapses: z.ZodNumber;
|
|
1173
|
+
reps: z.ZodNumber;
|
|
1174
|
+
}, z.core.$strip>;
|
|
1175
|
+
type CardReviewState = z.infer<typeof cardReviewStateSchema>;
|
|
1176
|
+
declare const cardMemoryStateSchema: z.ZodObject<{
|
|
1177
|
+
buriedAt: z.ZodNullable<z.ZodCoercedDate<unknown>>;
|
|
1178
|
+
state: z.ZodEnum<{
|
|
1179
|
+
new: "new";
|
|
1180
|
+
learning: "learning";
|
|
1181
|
+
review: "review";
|
|
1182
|
+
relearning: "relearning";
|
|
1183
|
+
}>;
|
|
1184
|
+
scheduleStatus: z.ZodEnum<{
|
|
1185
|
+
new: "new";
|
|
1186
|
+
learning: "learning";
|
|
1187
|
+
review: "review";
|
|
1188
|
+
suspended: "suspended";
|
|
1189
|
+
buried: "buried";
|
|
1190
|
+
}>;
|
|
1191
|
+
dueAt: z.ZodCoercedDate<unknown>;
|
|
1192
|
+
lastReviewTime: z.ZodNullable<z.ZodCoercedDate<unknown>>;
|
|
1193
|
+
stability: z.ZodNumber;
|
|
1194
|
+
difficulty: z.ZodNumber;
|
|
1195
|
+
step: z.ZodNumber;
|
|
1196
|
+
lapses: z.ZodNumber;
|
|
1197
|
+
reps: z.ZodNumber;
|
|
1198
|
+
}, z.core.$strip>;
|
|
1199
|
+
type CardMemoryState = z.infer<typeof cardMemoryStateSchema>;
|
|
1200
|
+
//#endregion
|
|
1201
|
+
//#region src/types/srs.d.ts
|
|
1202
|
+
declare const REVIEW_RATING_VALUES: readonly ["again", "hard", "good", "easy"];
|
|
1203
|
+
declare const reviewRatingSchema: z.ZodEnum<{
|
|
1204
|
+
again: "again";
|
|
1205
|
+
hard: "hard";
|
|
1206
|
+
good: "good";
|
|
1207
|
+
easy: "easy";
|
|
1208
|
+
}>;
|
|
1209
|
+
type ReviewRating = z.infer<typeof reviewRatingSchema>;
|
|
1210
|
+
declare const SRS_REVIEW_DURATION_MS_MAX = 180000;
|
|
1211
|
+
declare const srsStepSchema: z.ZodTemplateLiteral<`${number}m` | `${number}h` | `${number}d`>;
|
|
1212
|
+
type SrsStep = z.infer<typeof srsStepSchema>;
|
|
1213
|
+
declare const srsWeightsSchema: z.ZodArray<z.ZodNumber>;
|
|
1214
|
+
declare const schedulingParamsShape: {
|
|
1215
|
+
newPerDay: z.ZodNumber;
|
|
1216
|
+
reviewsPerDay: z.ZodNumber;
|
|
1217
|
+
desiredRetention: z.ZodNumber;
|
|
1218
|
+
enableShortTerm: z.ZodBoolean;
|
|
1219
|
+
maximumInterval: z.ZodNumber;
|
|
1220
|
+
learningSteps: z.ZodArray<z.ZodTemplateLiteral<`${number}m` | `${number}h` | `${number}d`>>;
|
|
1221
|
+
relearningSteps: z.ZodArray<z.ZodTemplateLiteral<`${number}m` | `${number}h` | `${number}d`>>;
|
|
1222
|
+
leechThreshold: z.ZodNumber;
|
|
1223
|
+
enableFuzz: z.ZodBoolean;
|
|
1224
|
+
weights: z.ZodOptional<z.ZodArray<z.ZodNumber>>;
|
|
1225
|
+
};
|
|
1226
|
+
declare const schedulingParamsSchema: z.ZodObject<{
|
|
1227
|
+
newPerDay: z.ZodNumber;
|
|
1228
|
+
reviewsPerDay: z.ZodNumber;
|
|
1229
|
+
desiredRetention: z.ZodNumber;
|
|
1230
|
+
enableShortTerm: z.ZodBoolean;
|
|
1231
|
+
maximumInterval: z.ZodNumber;
|
|
1232
|
+
learningSteps: z.ZodArray<z.ZodTemplateLiteral<`${number}m` | `${number}h` | `${number}d`>>;
|
|
1233
|
+
relearningSteps: z.ZodArray<z.ZodTemplateLiteral<`${number}m` | `${number}h` | `${number}d`>>;
|
|
1234
|
+
leechThreshold: z.ZodNumber;
|
|
1235
|
+
enableFuzz: z.ZodBoolean;
|
|
1236
|
+
weights: z.ZodOptional<z.ZodArray<z.ZodNumber>>;
|
|
1237
|
+
}, z.core.$strict>;
|
|
1238
|
+
type SchedulingParams = z.infer<typeof schedulingParamsSchema>;
|
|
1239
|
+
declare const DEFAULT_SRS_SCHEDULING_PARAMS: {
|
|
1240
|
+
newPerDay: number;
|
|
1241
|
+
reviewsPerDay: number;
|
|
1242
|
+
desiredRetention: number;
|
|
1243
|
+
enableShortTerm: true;
|
|
1244
|
+
maximumInterval: number;
|
|
1245
|
+
learningSteps: ("1m" | "10m")[];
|
|
1246
|
+
relearningSteps: "10m"[];
|
|
1247
|
+
leechThreshold: number;
|
|
1248
|
+
enableFuzz: false;
|
|
1249
|
+
};
|
|
1250
|
+
declare const fsrsReviewLogSnapshotSchema: z.ZodObject<{
|
|
1251
|
+
rating: z.ZodUnion<readonly [z.ZodLiteral<1>, z.ZodLiteral<2>, z.ZodLiteral<3>, z.ZodLiteral<4>]>;
|
|
1252
|
+
state: z.ZodUnion<readonly [z.ZodLiteral<0>, z.ZodLiteral<1>, z.ZodLiteral<2>, z.ZodLiteral<3>]>;
|
|
1253
|
+
dueAt: z.ZodString;
|
|
1254
|
+
stability: z.ZodNumber;
|
|
1255
|
+
difficulty: z.ZodNumber;
|
|
1256
|
+
scheduledDays: z.ZodNumber;
|
|
1257
|
+
learningSteps: z.ZodNumber;
|
|
1258
|
+
review: z.ZodString;
|
|
1259
|
+
}, z.core.$strict>;
|
|
1260
|
+
type FsrsReviewLogSnapshot = z.infer<typeof fsrsReviewLogSnapshotSchema>;
|
|
1261
|
+
//#endregion
|
|
1262
|
+
//#region src/utils/srs-day.d.ts
|
|
1263
|
+
declare const SRS_DAY_START_HOUR = 4;
|
|
1264
|
+
declare function getSrsDayStart(date: Date, timezone: string, startHour?: number): Date;
|
|
1265
|
+
declare function getSrsDayEnd(date: Date, timezone: string, startHour?: number): Date;
|
|
1266
|
+
declare function isSameSrsDay(left: Date, right: Date, timezone: string, startHour?: number): boolean;
|
|
1267
|
+
declare function differenceInSrsDays(later: Date, earlier: Date, timezone: string, startHour?: number): number;
|
|
1268
|
+
//#endregion
|
|
1269
|
+
export { APP_NAME, AUTH_BASE_PATH, AUTH_COOKIE_PATTERNS, BETA_FEATURES, BETA_FEATURE_KEYS, BasicCardTemplateConfig, BetaFeatureKey, CARD_STATE_TO_SCHEDULE_STATUS, CARD_STATE_VALUES, CHROME_EXTENSION_ORIGIN, CardMemoryState, CardReviewState, CardState, CardTemplateConfig, DEFAULT_SRS_SCHEDULING_PARAMS, DictionaryFieldLabels, EDGE_EXTENSION_ORIGIN, FsrsReviewLogSnapshot, ISO6393_TO_6391, LANG_CODE_ISO6391_OPTIONS, LANG_CODE_ISO6393_OPTIONS, LANG_CODE_TO_EN_NAME, LANG_CODE_TO_LOCALE_NAME, LANG_CODE_TO_ZH_NAME, LANG_DICTIONARY_LABELS, LOCALE_TO_ISO6393, LangCodeISO6391, LangCodeISO6393, LangLevel, NOTEBASE_BETA_FEATURE_KEY, NOTEBASE_COLUMN_MAX_WIDTH, NOTEBASE_COLUMN_MIN_WIDTH, NOTEBASE_COLUMN_TYPES, NOTEBASE_COLUMN_TYPE_INFO, NotebaseColumnConfig, NotebaseColumnType, NotebaseSelectOption, ORPC_PREFIX, REVIEW_RATING_VALUES, RTL_LANG_CODES, ReviewRating, SCHEDULE_STATUS_VALUES, SEMANTIC_VERSION_REGEX, SRS_DAY_START_HOUR, SRS_REVIEW_DURATION_MS_MAX, ScheduleStatus, SchedulingParams, SemanticVersion, SrsStep, VersionType, basicCardTemplateConfigSchema, cardIdentityShape, cardMemoryStateSchema, cardMemoryStateShape, cardReviewStateSchema, cardReviewStateShape, cardStateSchema, cardTemplateConfigSchema, createCellSchema, createRowSchema, differenceInSrsDays, fsrsReviewLogSnapshotSchema, getSrsDayEnd, getSrsDayStart, getVersionType, isNumberConfig, isSameSrsDay, isSelectConfig, langCodeISO6391Schema, langCodeISO6393Schema, langLevel, notebaseColumnConfigSchema, notebaseSelectOptionSchema, parseSemanticVersion, reviewRatingSchema, rowSchemaToJsonSchema, scheduleStatusSchema, schedulingParamsSchema, schedulingParamsShape, semanticVersionSchema, srsStepSchema, srsWeightsSchema };
|
|
519
1270
|
//# sourceMappingURL=index.d.ts.map
|