Scope font-size rules to fng-container to avoid overriding full-diagram styles
This commit is contained in:
@@ -153,13 +153,13 @@ export function renderPersonCard(parent, person, config, onClick) {
|
||||
const firstName = data["first name"] || "";
|
||||
const lastName = data["last name"] || "";
|
||||
const displayName = formatDisplayName(firstName, lastName, data.fullName);
|
||||
const maxTextWidth = w - textXOffset - 5;
|
||||
const maxTextWidth = w - textXOffset;
|
||||
|
||||
g.append("text")
|
||||
.attr("class", "person-name")
|
||||
.attr("x", textXOffset)
|
||||
.attr("y", h / 2 - 4)
|
||||
.text(truncateText(displayName, maxTextWidth, 5.5));
|
||||
.text(truncateText(displayName, maxTextWidth, 4.5));
|
||||
|
||||
// Dates line (compact)
|
||||
const dates = formatDates(data.birthYear, data.deathYear, data.isDead);
|
||||
|
||||
Reference in New Issue
Block a user