import React, { useState } from "react"; import { Select } from "@jobber/components-native"; import { ProvinceItems, type ProvinceOption, } from "./SelectComposableProvinces"; /** Validation: the `error` message and critical styling clear once selected. */ export function SelectComposableValidationFlow() { const [value, setValue] = useState(); return ( setValue(option as ProvinceOption | undefined)} error={value ? undefined : "Please select a province."} > Province ); }