I could simplify that regsub a bit like this:

alias chans_noprefix var %a, %b = $regsub($1-,/(?<=^|\s)[^#]+/g,,%a) | return %a