Please allow to refer to document properties from HTML or JavaScript code of text area, for example use notion like "${property-name} " to refer to the value of document properties.
Also please trigger text area to re-draw once the value of document properties is changed.