matrix to css string bug fix