迁移compose fun到AccountActivity类体

master
pan 4 years ago
parent 169a6973f2
commit dc58940561
  1. 22
      foreground/src/main/java/com/gyf/csams/account/ui/AccountActivity.kt

@ -19,7 +19,6 @@ import androidx.compose.ui.text.input.ImeAction
import androidx.compose.ui.text.input.KeyboardType
import androidx.compose.ui.text.input.PasswordVisualTransformation
import androidx.compose.ui.text.withStyle
import androidx.compose.ui.tooling.preview.Preview
import androidx.compose.ui.unit.dp
import androidx.lifecycle.viewmodel.compose.viewModel
import androidx.navigation.compose.NavHost
@ -117,7 +116,6 @@ class AccountActivity : ComponentActivity() {
}
}
}
}
/**
* 帐号表单
@ -374,25 +372,7 @@ private fun PasswordTip(accountViewModel: AccountViewModel = viewModel()) {
)
}
}
}
@Preview(showBackground = true)
@Composable
fun DefaultPreview() {
CSAMSTheme {
Row(
horizontalArrangement = Arrangement.Center,
verticalAlignment = Alignment.CenterVertically,
modifier = Modifier.fillMaxSize()
) {
Column(modifier = Modifier.width(IntrinsicSize.Min)) {
val model: AccountViewModel = viewModel()
StudentId(model, false)
Spacer(modifier = Modifier.height(10.dp))
}
}
}
}

Loading…
Cancel
Save