solved inlined diagram issue