feat: update navigation paths to use '/internship'; enhance certificate generation and user interface elements
This commit is contained in:
@@ -23,13 +23,13 @@ async function ensureFontsLoaded(): Promise<void> {
|
||||
|
||||
// LAYOUT DEFAULT SERTIFIKAT YANG AKAN DIGENERATE
|
||||
const LAYOUT = {
|
||||
internName: { x: 0.54, y: 0.5, size: 130, font: "Great Vibes", color: "#800000" },
|
||||
internName: { x: 0.54, y: 0.47, size: 130, font: "Great Vibes", color: "#800000" },
|
||||
internNameSmall: { x: 0.82, y: 0.889, size: 47, font: "Great Vibes", color: "#090909" },
|
||||
projectName: { x: 0.815, y: 0.598, size: 46, font: "Grenze", color: "#800000" },
|
||||
duration: { x: 0.7, y: 0.645, size: 48, font: "Grenze", color: "#090909" },
|
||||
userposition: { x: 0.855, y: 0.557, size: 46, font: "Grenze", color: "#800000" },
|
||||
duration: { x: 0.7, y: 0.615, size: 48, font: "Grenze", color: "#090909" },
|
||||
certNo: { x: 0.56, y: 0.305, size: 50, font: "Grenze", color: "#090909" },
|
||||
certNoSmall: { x: 0.827, y: 0.92, size: 32, font: "Grenze", color: "#090909"},
|
||||
qr: { x: 0.77, y: 0.715, size: 0.103 },
|
||||
qr: { x: 0.772, y: 0.715, size: 0.103 },
|
||||
};
|
||||
|
||||
// HELPER: kurangi ukuran font 25% jika nama melebihi 22 karakter (termasuk spasi)
|
||||
@@ -48,7 +48,7 @@ function fitNameText(name: string, baseSize: number): number {
|
||||
export async function generateCertificate(
|
||||
templateUrl: string,
|
||||
internName: string,
|
||||
projectName: string,
|
||||
userposition: string,
|
||||
certificateNo: string,
|
||||
ProjectDuration: string,
|
||||
verifyUrl: string,
|
||||
@@ -76,7 +76,7 @@ export async function generateCertificate(
|
||||
|
||||
text(LAYOUT.internName, internName);
|
||||
text(LAYOUT.internNameSmall, internName);
|
||||
text(LAYOUT.projectName, projectName);
|
||||
text(LAYOUT.userposition, userposition);
|
||||
text(LAYOUT.duration, ProjectDuration);
|
||||
text(LAYOUT.certNo, certificateNo);
|
||||
text(LAYOUT.certNoSmall, certificateNo);
|
||||
|
||||
Reference in New Issue
Block a user