Fix an issue that autocapitalization or autocorrection will remove all text styles.