cleanup
This commit is contained in:
parent
fa01305393
commit
bdbee0e4f7
|
@ -21,9 +21,9 @@ const labels = {
|
|||
[{ masc: "He/It", fem: "She/It"}, "They"],
|
||||
],
|
||||
eObject: [
|
||||
["I", "Us"],
|
||||
["You", "You pl."],
|
||||
[{ masc: "Him/It", fem: "Her/It"}, "Them"],
|
||||
["I", "us"],
|
||||
["you", "you (pl.)"],
|
||||
[{ masc: "him/it", fem: "her/it"}, "them"],
|
||||
],
|
||||
p: {
|
||||
far: [
|
||||
|
|
|
@ -84,7 +84,7 @@ import * as games from "!babel-loader!@lingdocs/mdx-loader!./games.mdx";
|
|||
// @ts-ignore
|
||||
import * as pronounPicker from "!babel-loader!@lingdocs/mdx-loader!./practice-tools/pronoun-picker.mdx";
|
||||
// @ts-ignore
|
||||
import * as phraseBuilder from "!babel-loader!@lingdocs/mdx-loader!./practice-tools/phrase-builder.mdx";
|
||||
// import * as phraseBuilder from "!babel-loader!@lingdocs/mdx-loader!./practice-tools/phrase-builder.mdx";
|
||||
|
||||
const contentTree = [
|
||||
{
|
||||
|
@ -271,10 +271,10 @@ const contentTree = [
|
|||
import: pronounPicker,
|
||||
slug: "pronoun-picker",
|
||||
},
|
||||
{
|
||||
import: phraseBuilder,
|
||||
slug: "phrase-builder",
|
||||
},
|
||||
// {
|
||||
// import: phraseBuilder,
|
||||
// slug: "phrase-builder",
|
||||
// },
|
||||
],
|
||||
},
|
||||
];
|
||||
|
|
|
@ -24,15 +24,23 @@ export function randomPerson(p?: T.Person) {
|
|||
}
|
||||
|
||||
function isInvalidSubjObjCombo(subj: T.Person, obj: T.Person): boolean {
|
||||
// subject is first person
|
||||
if ([0, 1, 6, 7].includes(subj)) {
|
||||
return [0, 1, 6, 7].includes(obj);
|
||||
}
|
||||
// subject is second person
|
||||
if ([2, 3, 8, 9].includes(subj)) {
|
||||
return [2, 3, 8, 9].includes(obj);
|
||||
}
|
||||
return false;
|
||||
const firstPeople = [
|
||||
T.Person.FirstSingMale,
|
||||
T.Person.FirstSingFemale,
|
||||
T.Person.FirstPlurMale,
|
||||
T.Person.FirstPlurFemale,
|
||||
];
|
||||
const secondPeople = [
|
||||
T.Person.SecondSingMale,
|
||||
T.Person.SecondSingFemale,
|
||||
T.Person.SecondPlurMale,
|
||||
T.Person.SecondPlurFemale,
|
||||
];
|
||||
return (
|
||||
(firstPeople.includes(subj) && firstPeople.includes(obj))
|
||||
||
|
||||
(secondPeople.includes(subj) && secondPeople.includes(obj))
|
||||
);
|
||||
}
|
||||
|
||||
export function randomSubjObj(old?: { subj: T.Person, obj: T.Person }): { subj: T.Person, obj: T.Person } {
|
||||
|
|
Loading…
Reference in New Issue