Split is not working on multivalued string fields

I have record like below in my text file;
id=1
name=Paint
category=Decorative
color=2345|red|5||
color=123|green|4||
color=345|yellow|8||
REC$$

I wanted output (stdout) as below using logstash configuration;

"id" => "1"
"name" => "Paint"
"category" => "Decorative"
"color" => "2345|red|5||"
"color" => "123|green|4||"
"color" => "345|yellow|8||"
"colorName" => "red"
"colorName" => "green"
"colorName" => "yellow"

Please share your findings. Thanks in advance!