half functional textOptions sync
This commit is contained in:
parent
c63ab30f1e
commit
5ffa82de53
|
@ -209,7 +209,7 @@ function IsolatedEntry({ state, dictionary, isolateEntry }: {
|
||||||
<Modal.Title>Delete from wordlist?</Modal.Title>
|
<Modal.Title>Delete from wordlist?</Modal.Title>
|
||||||
</Modal.Header>
|
</Modal.Header>
|
||||||
<Modal.Body>Delete <InlinePs
|
<Modal.Body>Delete <InlinePs
|
||||||
opts={state.options.textOptions}
|
opts={textOptions}
|
||||||
>{{ p: entry.p, f: entry.f }}</InlinePs> from your wordlist?
|
>{{ p: entry.p, f: entry.f }}</InlinePs> from your wordlist?
|
||||||
</Modal.Body>
|
</Modal.Body>
|
||||||
<Modal.Footer>
|
<Modal.Footer>
|
||||||
|
|
|
@ -23,6 +23,7 @@ import {
|
||||||
} from "@lingdocs/pashto-inflector";
|
} from "@lingdocs/pashto-inflector";
|
||||||
import InflectionSearchResult from "../components/InflectionSearchResult";
|
import InflectionSearchResult from "../components/InflectionSearchResult";
|
||||||
import { searchAllInflections } from "../lib/search-all-inflections";
|
import { searchAllInflections } from "../lib/search-all-inflections";
|
||||||
|
import { getTextOptions } from "../lib/get-text-options";
|
||||||
|
|
||||||
const inflectionSearchIcon = "fas fa-search-plus";
|
const inflectionSearchIcon = "fas fa-search-plus";
|
||||||
|
|
||||||
|
@ -41,7 +42,7 @@ function Results({ state, isolateEntry }: {
|
||||||
const [pashto, setPashto] = useState<string>("");
|
const [pashto, setPashto] = useState<string>("");
|
||||||
const [phonetics, setPhonetics] = useState<string>("");
|
const [phonetics, setPhonetics] = useState<string>("");
|
||||||
const [english, setEnglish] = useState<string>("");
|
const [english, setEnglish] = useState<string>("");
|
||||||
const textOptions = state.user?.textOptions ? state.user.textOptions : state.options.textOptions;
|
const textOptions = getTextOptions(state);
|
||||||
useEffect(() => {
|
useEffect(() => {
|
||||||
setPowerResults(undefined);
|
setPowerResults(undefined);
|
||||||
}, [state.searchValue])
|
}, [state.searchValue])
|
||||||
|
|
Loading…
Reference in New Issue