Skip to content

Commit 0c974c6

Browse files
authored
Merge pull request #62 from ilo-token/master
0.4.1
2 parents 43b94d1 + 3de76c2 commit 0c974c6

40 files changed

+1508
-1556
lines changed

CHANGELOG.md

Lines changed: 14 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -4,20 +4,30 @@
44
NOTE: Before publishing:
55
- run `deno task update` to update all dependencies including telo misikeke
66
- set parameters on `project-data.json`
7+
- Remove details
78
-->
89

10+
<!--
911
<details>
10-
1112
<summary>On development changelog</summary>
12-
13-
## 0.4.0 (On development)
14-
1513
The latest on-development version can be accessed by building the source code.
1614
On this on-development version, things can be broken.
15+
</details>
16+
-->
17+
18+
## 0.4.1
19+
20+
ilo Token is now a lot faster.
21+
22+
- Fix custom dictionary error messages.
23+
- Fix custom dictionary not loading when ilo Token is newly loaded.
24+
25+
## 0.4.0
1726

1827
ilo Token can now translate into verbs! This means it can translate sentences!
1928
It still can't do the following however:
2029

30+
- X ala X construction
2131
- Preverb
2232
- Preposition
2333
- "o" imperative sentence
@@ -52,8 +62,6 @@ settings after refactoring to make the code easier to work with.
5262
- Implement advanced parsing settings.
5363
- Long texts (>500) are no longer recognized.
5464

55-
</details>
56-
5765
## 0.3.0
5866

5967
Released 15 Aug 2024

CONTRIBUTING.md

Lines changed: 10 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -66,14 +66,19 @@ alternative contact options:
6666
- [Google forms](https://docs.google.com/forms/d/e/1FAIpQLSfdDEMbde9mieybZdbZr8haRzNzGsg0BVkuTIzuHaATCdcrlw/viewform?usp=sf_link)
6767
6868

69-
ilo Token have a dedicated space for the following Discord server. Although
70-
these server themselves serves as a space for broader topics, not just ilo
71-
Token.
69+
ilo Token have a dedicated space for the following site. Although these sites
70+
themselves serves as a space for broader topics, not just ilo Token.
7271

73-
- [ma pona pi toki pona](https://discord.gg/Byqn5z9)
72+
<!--
73+
- [ma pona pi toki pona Discord Server](https://discord.gg/Byqn5z9)
7474
([Thread for ilo Token](https://discord.com/channels/301377942062366741/1053538532993548320)):
7575
A Discord server for Toki Pona.
76-
- [r/ProgrammingLanguages](https://discord.gg/4Kjt3ZE)
76+
-->
77+
78+
- [Conlangs from Space](https://conlangsfrom.space/)
79+
([Forum page for ilo Token](https://conlangsfrom.space/t/ilo-token-a-wip-rule-based-toki-pona-to-english-translator/452)):
80+
A forum site dedicated for all conlangs, not just Toki Pona.
81+
- [r/ProgrammingLanguages Discord Server](https://discord.gg/4Kjt3ZE)
7782
([Channel for ilo Token](https://discord.com/channels/530598289813536771/1224854915214737522)):
7883
A Discord server for programming language development. While ilo Token isn't a
7984
programming language, it uses similar techniques found in programming language

bundle.ts

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -15,7 +15,7 @@ const WATCH = [
1515
"./src/",
1616
"./project-data.json",
1717
];
18-
const DICTIONARY = /dictionary[/\\]/;
18+
const DICTIONARY = /dictionary[/\\][^/\\]+$/;
1919

2020
function buildOptions(minify: boolean): ESBuild.BuildOptions {
2121
return {

deno.json

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -36,6 +36,8 @@
3636
"imports": {
3737
"@luca/esbuild-deno-loader": "jsr:@luca/esbuild-deno-loader@^0.11.1",
3838
"@std/async": "jsr:@std/async@^1.0.10",
39+
"@std/cache": "jsr:@std/cache@^0.1.3",
40+
"@std/collections": "jsr:@std/collections@^1.0.10",
3941
"@std/html": "jsr:@std/html@^1.0.3",
4042
"@std/random": "jsr:@std/random@^0.1.0",
4143
"@std/text": "jsr:@std/text@^1.0.10",

deno.lock

Lines changed: 10 additions & 0 deletions
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

dictionary/build.ts

Lines changed: 6 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -37,14 +37,18 @@ export async function build(checkFile: boolean): Promise<void> {
3737
}
3838
console.log("Building dictionary...");
3939
const text = await currentPromise;
40-
const json = JSON.stringify(parseDictionary(text), undefined, 2);
40+
const json = JSON.stringify(
41+
Object.fromEntries(parseDictionary(text)),
42+
undefined,
43+
2,
44+
);
4145
const original = JSON.stringify(text);
4246
const code = `\
4347
// This code is autogenerated
4448
4549
import { Dictionary } from "./type.ts";
4650
47-
export const dictionary: Dictionary = ${json};
51+
export const dictionary: Dictionary = new Map(Object.entries(${json}));
4852
4953
export const original = ${original};
5054
`;

0 commit comments

Comments
 (0)