oops take out modal stuff cause the negative is not ready yet

This commit is contained in:
lingdocs 2022-03-29 16:50:07 +05:00
parent 40794345b7
commit ac538bce64
1 changed files with 23 additions and 23 deletions

View File

@ -78,14 +78,14 @@ function VerbPicker({ onChange, verb, verbs }: { verbs: VerbEntry[], verb: VerbS
}); });
} }
} }
function onTenseCategorySelect(value: "basic" | "modal") { // function onTenseCategorySelect(value: "basic" | "modal") {
if (verb) { // if (verb) {
onChange({ // onChange({
...verb, // ...verb,
tenseCategory: value, // tenseCategory: value,
}); // });
} // }
} // }
function notInstransitive(t: "transitive" | "intransitive" | "grammatically transitive"): "transitive" | "grammatically transitive" { function notInstransitive(t: "transitive" | "intransitive" | "grammatically transitive"): "transitive" | "grammatically transitive" {
return t === "intransitive" ? "transitive" : t; return t === "intransitive" ? "transitive" : t;
} }
@ -113,7 +113,7 @@ function VerbPicker({ onChange, verb, verbs }: { verbs: VerbEntry[], verb: VerbS
placeholder={verb ? options.find(o => o.value === (verb.verb.entry).ts.toString())?.label : "Select Verb..."} placeholder={verb ? options.find(o => o.value === (verb.verb.entry).ts.toString())?.label : "Select Verb..."}
{...zIndexProps} {...zIndexProps}
/> />
{verb && <div className="text-center my-3"> {/* {verb && <div className="text-center my-3">
<ButtonSelect <ButtonSelect
small small
value={verb.tenseCategory} value={verb.tenseCategory}
@ -126,7 +126,7 @@ function VerbPicker({ onChange, verb, verbs }: { verbs: VerbEntry[], verb: VerbS
}]} }]}
handleChange={onTenseCategorySelect} handleChange={onTenseCategorySelect}
/> />
</div>} </div>} */}
<div>Tense:</div> <div>Tense:</div>
<Select <Select
isSearchable={false} isSearchable={false}
@ -202,23 +202,23 @@ function makeVerbSelection(verb: VerbEntry, oldVerbSelection?: VerbSelection): V
const object = (transitivity === "grammatically transitive") const object = (transitivity === "grammatically transitive")
? T.Person.ThirdPlurMale ? T.Person.ThirdPlurMale
: info.type === "dynamic compound" : info.type === "dynamic compound"
? makeNounSelection(info.objComplement.entry as NounEntry, true) ? makeNounSelection(info.objComplement.entry as NounEntry, true)
: (transitivity === "transitive") : (transitivity === "transitive")
? getTransObjFromOldVerbSelection() ? getTransObjFromOldVerbSelection()
: "none"; : "none";
const isCompound = "stative" in info const isCompound = "stative" in info
? "stative" ? "stative"
: info.type === "dynamic compound" : info.type === "dynamic compound"
? "dynamic" ? "dynamic"
: false; : false;
// TODO: here and below in the changeStatDyn function ... allow for entries with complement // TODO: here and below in the changeStatDyn function ... allow for entries with complement
const dynAuxVerb: VerbEntry | undefined = isCompound !== "dynamic" const dynAuxVerb: VerbEntry | undefined = isCompound !== "dynamic"
? undefined ? undefined
: info.type === "dynamic compound" : info.type === "dynamic compound"
? { entry: info.auxVerb } as VerbEntry ? { entry: info.auxVerb } as VerbEntry
: "dynamic" in info : "dynamic" in info
? { entry: info.dynamic.auxVerb } as VerbEntry ? { entry: info.dynamic.auxVerb } as VerbEntry
: undefined; : undefined;
return { return {
type: "verb", type: "verb",
verb: verb, verb: verb,