Constructing ambivalent imidazopyridinium-linked covalent organic frameworks