mirror of
https://github.com/abhay-raizada/PeerScribe.git
synced 2026-04-26 16:24:03 +00:00
Fix input colors in dark mode
This commit is contained in:
@@ -21,11 +21,14 @@ export const InputFiller: React.FC<InputFillerProps> = ({
|
|||||||
const handleInputChange = (
|
const handleInputChange = (
|
||||||
e: any
|
e: any
|
||||||
) => {
|
) => {
|
||||||
setInputValue(e.target.value)
|
console.log("E is", e)
|
||||||
|
setInputValue(e.target.value);
|
||||||
|
onChange(e.target.value)
|
||||||
};
|
};
|
||||||
|
|
||||||
const handleValueChange = (value: string | null) => {
|
const handleValueChange = (value: string) => {
|
||||||
if (!value) return;
|
if (!value) return;
|
||||||
|
setInputValue(value)
|
||||||
onChange(value);
|
onChange(value);
|
||||||
};
|
};
|
||||||
|
|
||||||
@@ -41,15 +44,17 @@ export const InputFiller: React.FC<InputFillerProps> = ({
|
|||||||
[AnswerTypes.label]: <></>,
|
[AnswerTypes.label]: <></>,
|
||||||
[AnswerTypes.shortText]: (
|
[AnswerTypes.shortText]: (
|
||||||
<InputItem
|
<InputItem
|
||||||
onChange={handleInputChange}
|
onChange={handleValueChange}
|
||||||
defaultValue={defaultValue as string}
|
defaultValue={defaultValue as string}
|
||||||
placeholder="enter a value...">
|
placeholder="enter a value..."
|
||||||
|
placeholderTextColor="#aaaaaa">
|
||||||
</InputItem>
|
</InputItem>
|
||||||
),
|
),
|
||||||
[AnswerTypes.paragraph]: (
|
[AnswerTypes.paragraph]: (
|
||||||
<TextareaItem
|
<TextareaItem
|
||||||
rows={10}
|
rows={10}
|
||||||
placeholder="enter a value.."
|
placeholder="enter a value.."
|
||||||
|
placeholderTextColor="#aaaaaa"
|
||||||
onChange={handleInputChange}
|
onChange={handleInputChange}
|
||||||
autoHeight
|
autoHeight
|
||||||
style={{ paddingVertical: 5 }}
|
style={{ paddingVertical: 5 }}
|
||||||
@@ -84,7 +89,7 @@ export const InputFiller: React.FC<InputFillerProps> = ({
|
|||||||
),
|
),
|
||||||
[AnswerTypes.dropdown]: (
|
[AnswerTypes.dropdown]: (
|
||||||
<RNPickerSelect
|
<RNPickerSelect
|
||||||
onValueChange={(value) => { setInputValue(value), console.log("selected value is: ", value)}}
|
onValueChange={handleValueChange}
|
||||||
items={dropdownItems}
|
items={dropdownItems}
|
||||||
placeholder={{}}
|
placeholder={{}}
|
||||||
key="picker"
|
key="picker"
|
||||||
|
|||||||
@@ -96,7 +96,7 @@ export const PrescriptionCreator = ({form} : {form: any}) => {
|
|||||||
}}>
|
}}>
|
||||||
<Text
|
<Text
|
||||||
style={{
|
style={{
|
||||||
color: Colors.green,
|
color: "#000000",
|
||||||
}}>
|
}}>
|
||||||
{field.question}
|
{field.question}
|
||||||
</Text>
|
</Text>
|
||||||
|
|||||||
Reference in New Issue
Block a user