Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
4 changes: 1 addition & 3 deletions configs/sponsors/contribkit.config.ts
Original file line number Diff line number Diff line change
Expand Up @@ -176,7 +176,6 @@ export default defineConfig({
compose.addSpan(30);

const padding = 20; // Padding between supporters
let currentX = padding;
const supporters = [...specialSupporters];

while (supporters.length) {
Expand All @@ -199,8 +198,7 @@ export default defineConfig({
}

// Center row horizontally
const startX = (config.width! - rowWidth + padding) / 2;
currentX = startX;
let currentX = (config.width! - rowWidth + padding) / 2;

// Add supporters in row
for (const supporter of row) {
Expand Down
2 changes: 1 addition & 1 deletion configs/sponsors/svg-utils.ts
Original file line number Diff line number Diff line change
Expand Up @@ -11,7 +11,7 @@ export function extractSvgDimensions(svgContent: string): { width: number; heigh
// Try to get dimensions from viewBox first
const viewBoxMatch = svgContent.match(/viewBox=['"]([^'"]*)['"]/);
if (viewBoxMatch) {
const [minX, minY, width, height] = viewBoxMatch[1].split(/\s+/).map(Number);
const [, , width, height] = viewBoxMatch[1].split(/\s+/).map(Number);
// Check that both width and height are valid numbers (not NaN and not undefined)
if (!Number.isNaN(width) && !Number.isNaN(height) && width !== undefined && height !== undefined) {
return { width, height };
Expand Down