feat: add the possibility to use classifiers on fields of class diagrams

fix #1953
This commit is contained in:
Xavier Stouder
2021-08-26 10:53:03 +02:00
parent 719de71de4
commit c0c978bbdf
2 changed files with 21 additions and 3 deletions

View File

@@ -156,5 +156,21 @@ describe('class member Renderer, ', function () {
expect(actual.displayText).toBe('List<int> ids');
expect(actual.cssStyle).toBe('');
});
it('should handle abstract classifier', function () {
const str = 'String foo*';
let actual = svgDraw.parseMember(str);
expect(actual.displayText).toBe('String foo');
expect(actual.cssStyle).toBe('font-style:italic;');
});
it('should handle static classifier', function () {
const str = 'String foo$';
let actual = svgDraw.parseMember(str);
expect(actual.displayText).toBe('String foo');
expect(actual.cssStyle).toBe('text-decoration:underline;');
});
});
});