I am a bit confused about how this process functions.
Currently, I am utilizing schema to create an address auto complete configuration.
My goal is to have the option to display or hide the fields for manual input.
This is the current appearance of the form: https://i.sstatic.net/zvZg4.png
Initially, I want the blue section to remain hidden and only appear when Can't find your address?
is selected
Here is my existing code:
{
$formkit: InputType.GROUP,
name: 'address',
label: label,
children: [
// Code continues...
],
};
I am troubleshooting by attempting to change the text color from blue to red based on the status of the $manual
option
attrs: {
class: {
if: '$manual',
then: 'grid grid-cols-2 gap-4 ui-box py-5 px-4 mt-3 text-red-500',
else: 'grid grid-cols-2 gap-4 ui-box py-5 px-4 mt-3 text-blue-500',
},
},
However, despite my efforts, the color does not seem to change when selecting the manual option.
It appears as though the change is not being recognized.
I am referencing this example in playground which demonstrates what I am trying to achieve but it is not working properly for me.
What could be the issue?