Ternary with three conditions Javascript

I have this structure

const name = user.name;
const email = user.email;
const doc = user.doc;
const paramsSearch = req?.params?.search;
const search = …;

I want to transform search in a ternary like:

const search = paramsSearch === user.name ? …

if its equal to name, email and doc then search will be one of them, else return an empty string

I have tried the if else condition but i need it in ternary