package Ġcom . ga ug ust ini . car dd o . util Ċ Ċ import Ġandroid . view . View Ċ import Ġandroidx . core . view . isVisible Ċ import Ġandroidx . databinding . Binding Adapter Ċ import Ġcom . google . android . material . text field . TextInput EditText Ċ Ċ @ Binding Adapter (" is G one ") Ċ fun Ġbind Is G one ( view : ĠView , Ġis G one : ĠBoolean ) Ġ{ ĊĠĠĠ Ġview . isVisible Ġ= Ġis G one Ċ } Ċ Ċ @ Binding Adapter (" contact ") Ċ fun ĠText Input EditText . set Contact ( str : ĠString ?) Ġ{ ĊĠĠĠ Ġif Ġ( str Ġ!= Ġnull ) Ġ{ ĊĠĠĠĠĠĠĠ Ġset Text ( str ) ĊĠĠĠ Ġ} Ċ } Ċ Ċ //@ Binding Adapter (" background ") Ċ // fun ĠText Input EditText . setBackground ( color Hex : ĠString ) Ġ{ Ċ // ĠĠĠ Ġset BackgroundColor ( Color . parse Color ( color Hex )) Ċ //} Ċ Ċ //@ Binding Adapter (" card BackgroundColor ") Ċ // fun ĠMaterial Card View . set Card BackgroundColor ( color Hex : ĠString ) Ġ{ Ċ // ĠĠĠ Ġset BackgroundColor ( Color . parse Color ( color Hex )) Ċ //} Ċ