trying to write a custom directive