Ternary operator misinterpretation in v-model attribute