fix: adapt business card design to actual prod site brand colors
All checks were successful
Build & Deploy / 🔍 Prepare (push) Successful in 7s
Build & Deploy / 🧪 QA (push) Successful in 57s
Build & Deploy / 🏗️ Build (push) Successful in 1m55s
Build & Deploy / 🚀 Deploy (push) Successful in 15s
Build & Deploy / 🧪 Post-Deploy Verification (push) Has been skipped
Build & Deploy / 🔔 Notify (push) Successful in 1s
All checks were successful
Build & Deploy / 🔍 Prepare (push) Successful in 7s
Build & Deploy / 🧪 QA (push) Successful in 57s
Build & Deploy / 🏗️ Build (push) Successful in 1m55s
Build & Deploy / 🚀 Deploy (push) Successful in 15s
Build & Deploy / 🧪 Post-Deploy Verification (push) Has been skipped
Build & Deploy / 🔔 Notify (push) Successful in 1s
- Switch from Dark Navy to Bright Blue (#011dff) - Remove industrial grid for a cleaner flat aesthetic
This commit is contained in:
@@ -1,5 +1,5 @@
|
|||||||
import React from 'react';
|
import React from 'react';
|
||||||
import { Document, Page, Text, View, StyleSheet, Svg, Line, Image } from '@react-pdf/renderer';
|
import { Document, Page, Text, View, StyleSheet, Image } from '@react-pdf/renderer';
|
||||||
import { KLZLogoVector } from './KLZLogoVector';
|
import { KLZLogoVector } from './KLZLogoVector';
|
||||||
|
|
||||||
export interface PersonData {
|
export interface PersonData {
|
||||||
@@ -14,15 +14,14 @@ interface PDFBusinessCardProps {
|
|||||||
qrCodeDataUrl: string;
|
qrCodeDataUrl: string;
|
||||||
}
|
}
|
||||||
|
|
||||||
// Mintel Aesthetics Colors
|
// Mintel Aesthetics Colors - EXACT PROD COLORS
|
||||||
const COLORS = {
|
const COLORS = {
|
||||||
navy: '#001a4d',
|
primary: '#011dff', // Bright Royal Blue
|
||||||
navyLight: '#002870',
|
primaryDark: '#000e7a',
|
||||||
green: '#82ed20',
|
green: '#82ed20', // Brand Accent Green
|
||||||
white: '#ffffff',
|
white: '#ffffff',
|
||||||
grayText: '#8899aa',
|
grayText: '#6c757d',
|
||||||
darkText: '#000000',
|
lightGray: '#f8f9fa',
|
||||||
lightGray: '#f0f0f0',
|
|
||||||
};
|
};
|
||||||
|
|
||||||
const styles = StyleSheet.create({
|
const styles = StyleSheet.create({
|
||||||
@@ -30,7 +29,7 @@ const styles = StyleSheet.create({
|
|||||||
// 85x55mm + 3mm bleed on each side = 91x61mm
|
// 85x55mm + 3mm bleed on each side = 91x61mm
|
||||||
width: '91mm',
|
width: '91mm',
|
||||||
height: '61mm',
|
height: '61mm',
|
||||||
backgroundColor: COLORS.navy,
|
backgroundColor: COLORS.primary,
|
||||||
position: 'relative',
|
position: 'relative',
|
||||||
fontFamily: 'Helvetica',
|
fontFamily: 'Helvetica',
|
||||||
overflow: 'hidden',
|
overflow: 'hidden',
|
||||||
@@ -48,38 +47,38 @@ const styles = StyleSheet.create({
|
|||||||
frontContainer: {
|
frontContainer: {
|
||||||
flex: 1,
|
flex: 1,
|
||||||
position: 'relative',
|
position: 'relative',
|
||||||
padding: '8mm',
|
|
||||||
flexDirection: 'column',
|
|
||||||
justifyContent: 'center',
|
|
||||||
alignItems: 'center',
|
|
||||||
},
|
},
|
||||||
frontLogoPos: {
|
frontLogoPos: {
|
||||||
position: 'absolute',
|
position: 'absolute',
|
||||||
top: '8mm',
|
top: '8mm',
|
||||||
right: '8mm',
|
right: '8mm',
|
||||||
},
|
},
|
||||||
frontGraphicContainer: {
|
frontBottomBar: {
|
||||||
position: 'absolute',
|
position: 'absolute',
|
||||||
bottom: '-3mm',
|
bottom: 0,
|
||||||
left: '-3mm',
|
left: 0,
|
||||||
right: '-3mm',
|
right: 0,
|
||||||
height: '30mm',
|
height: '35mm',
|
||||||
backgroundColor: COLORS.navyLight,
|
backgroundColor: COLORS.primaryDark,
|
||||||
borderTopWidth: 2,
|
borderTopWidth: 2,
|
||||||
borderTopColor: COLORS.green,
|
borderTopColor: COLORS.green,
|
||||||
|
display: 'flex',
|
||||||
|
justifyContent: 'center',
|
||||||
|
alignItems: 'center',
|
||||||
},
|
},
|
||||||
frontTagline: {
|
frontTagline: {
|
||||||
position: 'absolute',
|
color: COLORS.white,
|
||||||
bottom: '8mm',
|
fontSize: 12,
|
||||||
left: '8mm',
|
|
||||||
color: COLORS.green,
|
|
||||||
fontSize: 10,
|
|
||||||
fontWeight: 'bold',
|
fontWeight: 'bold',
|
||||||
letterSpacing: 1.5,
|
letterSpacing: 2,
|
||||||
|
textTransform: 'uppercase',
|
||||||
},
|
},
|
||||||
gridLine: {
|
frontSubTagline: {
|
||||||
position: 'absolute',
|
color: COLORS.green,
|
||||||
backgroundColor: 'rgba(255,255,255,0.05)',
|
fontSize: 7,
|
||||||
|
marginTop: 4,
|
||||||
|
letterSpacing: 1,
|
||||||
|
textTransform: 'uppercase',
|
||||||
},
|
},
|
||||||
|
|
||||||
// -- BACK --
|
// -- BACK --
|
||||||
@@ -89,13 +88,12 @@ const styles = StyleSheet.create({
|
|||||||
padding: '6mm 6mm',
|
padding: '6mm 6mm',
|
||||||
},
|
},
|
||||||
backLogo: {
|
backLogo: {
|
||||||
marginBottom: '6mm',
|
marginBottom: '8mm',
|
||||||
},
|
},
|
||||||
backMiddle: {
|
backMiddle: {
|
||||||
flexDirection: 'row',
|
flexDirection: 'row',
|
||||||
justifyContent: 'space-between',
|
justifyContent: 'space-between',
|
||||||
alignItems: 'center',
|
alignItems: 'flex-start',
|
||||||
marginBottom: '8mm',
|
|
||||||
width: '100%',
|
width: '100%',
|
||||||
},
|
},
|
||||||
nameSection: {
|
nameSection: {
|
||||||
@@ -103,51 +101,51 @@ const styles = StyleSheet.create({
|
|||||||
width: '35%',
|
width: '35%',
|
||||||
},
|
},
|
||||||
nameText: {
|
nameText: {
|
||||||
fontSize: 14,
|
fontSize: 13,
|
||||||
fontWeight: 'bold',
|
fontWeight: 'bold',
|
||||||
color: COLORS.navy,
|
color: COLORS.primary,
|
||||||
marginBottom: 2,
|
marginBottom: 3,
|
||||||
},
|
},
|
||||||
roleText: {
|
roleText: {
|
||||||
fontSize: 7.5,
|
fontSize: 7,
|
||||||
fontWeight: 'normal',
|
fontWeight: 'normal',
|
||||||
color: COLORS.grayText,
|
color: COLORS.grayText,
|
||||||
letterSpacing: 0.5,
|
letterSpacing: 0.5,
|
||||||
|
textTransform: 'uppercase',
|
||||||
},
|
},
|
||||||
contactSection: {
|
contactSection: {
|
||||||
flexDirection: 'column',
|
flexDirection: 'column',
|
||||||
width: '45%',
|
width: '45%',
|
||||||
paddingLeft: '2mm',
|
paddingLeft: '3mm',
|
||||||
borderLeftWidth: 1,
|
borderLeftWidth: 1,
|
||||||
borderLeftColor: COLORS.lightGray,
|
borderLeftColor: COLORS.lightGray,
|
||||||
},
|
},
|
||||||
contactRow: {
|
contactRow: {
|
||||||
flexDirection: 'row',
|
flexDirection: 'row',
|
||||||
alignItems: 'center',
|
alignItems: 'center',
|
||||||
marginBottom: 4,
|
marginBottom: 5,
|
||||||
},
|
},
|
||||||
iconCircle: {
|
iconCircle: {
|
||||||
width: 10,
|
width: 6,
|
||||||
height: 10,
|
height: 6,
|
||||||
borderRadius: 5,
|
borderRadius: 3,
|
||||||
backgroundColor: COLORS.green,
|
backgroundColor: COLORS.green,
|
||||||
marginRight: 5,
|
marginRight: 6,
|
||||||
},
|
},
|
||||||
contactText: {
|
contactText: {
|
||||||
fontSize: 6.5,
|
fontSize: 6.5,
|
||||||
color: COLORS.navy,
|
color: COLORS.primaryDark,
|
||||||
|
fontWeight: 'normal',
|
||||||
},
|
},
|
||||||
qrSection: {
|
qrSection: {
|
||||||
width: '20%',
|
width: '20%',
|
||||||
alignItems: 'flex-end',
|
alignItems: 'flex-end',
|
||||||
},
|
},
|
||||||
qrCodeWrapper: {
|
qrCodeWrapper: {
|
||||||
width: '16mm',
|
width: '15mm',
|
||||||
height: '16mm',
|
height: '15mm',
|
||||||
padding: 2,
|
padding: 1,
|
||||||
backgroundColor: COLORS.white,
|
backgroundColor: COLORS.white,
|
||||||
borderWidth: 1,
|
|
||||||
borderColor: COLORS.lightGray,
|
|
||||||
},
|
},
|
||||||
qrCode: {
|
qrCode: {
|
||||||
width: '100%',
|
width: '100%',
|
||||||
@@ -161,9 +159,6 @@ const styles = StyleSheet.create({
|
|||||||
flexDirection: 'row',
|
flexDirection: 'row',
|
||||||
justifyContent: 'flex-start',
|
justifyContent: 'flex-start',
|
||||||
alignItems: 'center',
|
alignItems: 'center',
|
||||||
borderTopWidth: 1,
|
|
||||||
borderTopColor: COLORS.lightGray,
|
|
||||||
paddingTop: '2mm',
|
|
||||||
},
|
},
|
||||||
footerText: {
|
footerText: {
|
||||||
fontSize: 6,
|
fontSize: 6,
|
||||||
@@ -173,85 +168,41 @@ const styles = StyleSheet.create({
|
|||||||
pipe: {
|
pipe: {
|
||||||
fontSize: 6,
|
fontSize: 6,
|
||||||
color: COLORS.green,
|
color: COLORS.green,
|
||||||
marginHorizontal: 4,
|
marginHorizontal: 5,
|
||||||
fontWeight: 'bold',
|
fontWeight: 'bold',
|
||||||
},
|
},
|
||||||
greenBar: {
|
|
||||||
position: 'absolute',
|
|
||||||
top: 0,
|
|
||||||
left: 0,
|
|
||||||
width: '3mm',
|
|
||||||
height: '61mm',
|
|
||||||
backgroundColor: COLORS.green,
|
|
||||||
},
|
|
||||||
});
|
});
|
||||||
|
|
||||||
// A simple technical grid background for the industrial aesthetic
|
|
||||||
const IndustrialGrid = () => (
|
|
||||||
<Svg
|
|
||||||
viewBox="0 0 910 610"
|
|
||||||
style={{ position: 'absolute', top: 0, left: 0, right: 0, bottom: 0, opacity: 0.1 }}
|
|
||||||
>
|
|
||||||
{Array.from({ length: 10 }).map((_, i) => (
|
|
||||||
<Line
|
|
||||||
key={`h-${i}`}
|
|
||||||
x1="0"
|
|
||||||
y1={i * 61}
|
|
||||||
x2="910"
|
|
||||||
y2={i * 61}
|
|
||||||
stroke={COLORS.white}
|
|
||||||
strokeWidth={1}
|
|
||||||
/>
|
|
||||||
))}
|
|
||||||
{Array.from({ length: 15 }).map((_, i) => (
|
|
||||||
<Line
|
|
||||||
key={`v-${i}`}
|
|
||||||
x1={i * 61}
|
|
||||||
y1="0"
|
|
||||||
x2={i * 61}
|
|
||||||
y2="610"
|
|
||||||
stroke={COLORS.white}
|
|
||||||
strokeWidth={1}
|
|
||||||
/>
|
|
||||||
))}
|
|
||||||
</Svg>
|
|
||||||
);
|
|
||||||
|
|
||||||
export const PDFBusinessCard: React.FC<PDFBusinessCardProps> = ({ person, qrCodeDataUrl }) => {
|
export const PDFBusinessCard: React.FC<PDFBusinessCardProps> = ({ person, qrCodeDataUrl }) => {
|
||||||
return (
|
return (
|
||||||
<Document
|
<Document
|
||||||
title={`Business Card - ${person.name}`}
|
title={`Business Card - ${person.name}`}
|
||||||
author="KLZ Cables"
|
author="KLZ Cables"
|
||||||
creator="KLZ React-PDF Engine"
|
creator="KLZ Print Engine"
|
||||||
>
|
>
|
||||||
{/* FRONT - Dark Navy Industrial */}
|
{/* FRONT - Clean Modern KLZ Brand */}
|
||||||
<Page size={[258, 173]} style={styles.pageBleed}>
|
<Page size={[258, 173]} style={styles.pageBleed}>
|
||||||
<IndustrialGrid />
|
|
||||||
|
|
||||||
<View style={styles.frontLogoPos}>
|
<View style={styles.frontLogoPos}>
|
||||||
<KLZLogoVector width={100} color={COLORS.white} />
|
<KLZLogoVector width={110} color={COLORS.white} />
|
||||||
</View>
|
</View>
|
||||||
|
|
||||||
<View style={styles.frontGraphicContainer}>
|
<View style={styles.frontBottomBar}>
|
||||||
<IndustrialGrid />
|
<Text style={styles.frontTagline}>Empowering Energy</Text>
|
||||||
|
<Text style={styles.frontSubTagline}>High-Quality Cable Infrastructure</Text>
|
||||||
</View>
|
</View>
|
||||||
|
|
||||||
<Text style={styles.frontTagline}>INDUSTRIAL CABLE SOLUTIONS</Text>
|
|
||||||
</Page>
|
</Page>
|
||||||
|
|
||||||
{/* BACK - Clean White with Green Accents */}
|
{/* BACK - Clean White with Bright Blue & Green Accents */}
|
||||||
<Page size={[258, 173]} style={styles.pageBleedBack}>
|
<Page size={[258, 173]} style={styles.pageBleedBack}>
|
||||||
<View style={styles.greenBar} />
|
|
||||||
|
|
||||||
<View style={styles.backContainer}>
|
<View style={styles.backContainer}>
|
||||||
<View style={styles.backLogo}>
|
<View style={styles.backLogo}>
|
||||||
<KLZLogoVector width={80} color={COLORS.navy} />
|
<KLZLogoVector width={70} color={COLORS.primary} />
|
||||||
</View>
|
</View>
|
||||||
|
|
||||||
<View style={styles.backMiddle}>
|
<View style={styles.backMiddle}>
|
||||||
<View style={styles.nameSection}>
|
<View style={styles.nameSection}>
|
||||||
<Text style={styles.nameText}>{person.name}</Text>
|
<Text style={styles.nameText}>{person.name}</Text>
|
||||||
<Text style={styles.roleText}>{person.role.toUpperCase()}</Text>
|
<Text style={styles.roleText}>{person.role}</Text>
|
||||||
</View>
|
</View>
|
||||||
|
|
||||||
<View style={styles.contactSection}>
|
<View style={styles.contactSection}>
|
||||||
|
|||||||
Reference in New Issue
Block a user