We analyze the problem of locating a public facility on a line in a society where agents have either single-peaked or single-dipped preferences. We consider the domain analyzed in Alcalde-Unzu et al. (2024), where the type of preference of each agent is public information, but the location of her peak/dip as well as the rest of the preference are unknown. We characterize all strategy-proof and type-anonymous rules on this domain. Building on existing results, we provide a two-step characterization": first, the median between the peaks and a collection of fixed values is computed (Moulin, 1980), resulting in either a single alternative or a pair of contiguous alternatives. If the outcome of the median is a pair, we apply a double-quota majority method" in the second step to choose between the two alternatives in the pair (Moulin, 1983). We also show the additional conditions that type-anonymity imposes on the strategy-proof rules characterized by Alcalde-Unzu et al. (2024). Finally, we show the equivalence between the two characterizations.