you should try adding b.update() in showb(e) to force re-render like this:
def showb(e): b.border = ft.border.all(1, ft.colors.WHITE) b.update()