Merge version_1 into main #2
@@ -58,19 +58,19 @@ export default function LandingPage() {
|
||||
imageSrc: "http://img.b2bpic.net/free-vector/road-marking-flat-composition-with-workers-putting-paint-asphalt_1284-64295.jpg", imageAlt: "Construction machinery in action"
|
||||
},
|
||||
{
|
||||
imageSrc: "http://img.b2bpic.net/free-photo/paving-slabs-stacked-pallet-road-repair-process-closeup-selective-focus-tiles-seasonal-reconstruction-pavement-walking-paths-parks_166373-3647.jpg?_wi=1", imageAlt: "Brick making machine"
|
||||
imageSrc: "http://img.b2bpic.net/free-photo/paving-slabs-stacked-pallet-road-repair-process-closeup-selective-focus-tiles-seasonal-reconstruction-pavement-walking-paths-parks_166373-3647.jpg", imageAlt: "Brick making machine"
|
||||
},
|
||||
{
|
||||
imageSrc: "http://img.b2bpic.net/free-photo/factory-employee-working-industrial-drilling-machine-production-line_342744-100.jpg?_wi=1", imageAlt: "Construction lift machine"
|
||||
imageSrc: "http://img.b2bpic.net/free-photo/factory-employee-working-industrial-drilling-machine-production-line_342744-100.jpg", imageAlt: "Construction lift machine"
|
||||
},
|
||||
{
|
||||
imageSrc: "http://img.b2bpic.net/free-photo/pollution-industry-exterior-daylight_23-2149057679.jpg?_wi=1", imageAlt: "Pan mixer equipment"
|
||||
imageSrc: "http://img.b2bpic.net/free-photo/pollution-industry-exterior-daylight_23-2149057679.jpg", imageAlt: "Pan mixer equipment"
|
||||
},
|
||||
{
|
||||
imageSrc: "http://img.b2bpic.net/free-photo/portrait-handsome-young-male-hipster-snapback-sunglasses-carrying-trolley-from-warehouse_343059-3611.jpg?_wi=1", imageAlt: "Concrete mixer machine"
|
||||
imageSrc: "http://img.b2bpic.net/free-photo/portrait-handsome-young-male-hipster-snapback-sunglasses-carrying-trolley-from-warehouse_343059-3611.jpg", imageAlt: "Concrete mixer machine"
|
||||
},
|
||||
{
|
||||
imageSrc: "http://img.b2bpic.net/free-photo/excavator-digging-ground-day-light_23-2149194796.jpg?_wi=1", imageAlt: "Construction trolley"
|
||||
imageSrc: "http://img.b2bpic.net/free-photo/excavator-digging-ground-day-light_23-2149194796.jpg", imageAlt: "Construction trolley"
|
||||
}
|
||||
]}
|
||||
/>
|
||||
@@ -130,19 +130,19 @@ export default function LandingPage() {
|
||||
gridVariant="three-columns-all-equal-width"
|
||||
products={[
|
||||
{
|
||||
id: "1", name: "Brick & Block Making Machines", price: "Contact for Quote", imageSrc: "http://img.b2bpic.net/free-photo/paving-slabs-stacked-pallet-road-repair-process-closeup-selective-focus-tiles-seasonal-reconstruction-pavement-walking-paths-parks_166373-3647.jpg?_wi=2", imageAlt: "brick block making machine industrial"
|
||||
id: "1", name: "Brick & Block Making Machines", price: "Contact for Quote", imageSrc: "http://img.b2bpic.net/free-photo/paving-slabs-stacked-pallet-road-repair-process-closeup-selective-focus-tiles-seasonal-reconstruction-pavement-walking-paths-parks_166373-3647.jpg", imageAlt: "brick block making machine industrial"
|
||||
},
|
||||
{
|
||||
id: "2", name: "Lift Machines", price: "Contact for Quote", imageSrc: "http://img.b2bpic.net/free-photo/factory-employee-working-industrial-drilling-machine-production-line_342744-100.jpg?_wi=2", imageAlt: "construction lift hoist machinery equipment"
|
||||
id: "2", name: "Lift Machines", price: "Contact for Quote", imageSrc: "http://img.b2bpic.net/free-photo/factory-employee-working-industrial-drilling-machine-production-line_342744-100.jpg", imageAlt: "construction lift hoist machinery equipment"
|
||||
},
|
||||
{
|
||||
id: "3", name: "Hydraulic Lift Machines", price: "Contact for Quote", imageSrc: "http://img.b2bpic.net/free-photo/industry-4-0-photovoltaics-plant-manager-industrial-platform-overseeing-work-done-by-engineers_482257-135654.jpg", imageAlt: "hydraulic lift platform machinery equipment"
|
||||
},
|
||||
{
|
||||
id: "4", name: "Pan Mixers", price: "Contact for Quote", imageSrc: "http://img.b2bpic.net/free-photo/pollution-industry-exterior-daylight_23-2149057679.jpg?_wi=2", imageAlt: "concrete mixer pan mixer equipment"
|
||||
id: "4", name: "Pan Mixers", price: "Contact for Quote", imageSrc: "http://img.b2bpic.net/free-photo/pollution-industry-exterior-daylight_23-2149057679.jpg", imageAlt: "concrete mixer pan mixer equipment"
|
||||
},
|
||||
{
|
||||
id: "5", name: "Concrete Mixer (1 Bag)", price: "Contact for Quote", imageSrc: "http://img.b2bpic.net/free-photo/portrait-handsome-young-male-hipster-snapback-sunglasses-carrying-trolley-from-warehouse_343059-3611.jpg?_wi=2", imageAlt: "portable concrete mixer single bag capacity"
|
||||
id: "5", name: "Concrete Mixer (1 Bag)", price: "Contact for Quote", imageSrc: "http://img.b2bpic.net/free-photo/portrait-handsome-young-male-hipster-snapback-sunglasses-carrying-trolley-from-warehouse_343059-3611.jpg", imageAlt: "portable concrete mixer single bag capacity"
|
||||
},
|
||||
{
|
||||
id: "6", name: "Concrete Mixer (2 Bag)", price: "Contact for Quote", imageSrc: "http://img.b2bpic.net/free-vector/construction-background-design_1308-1237.jpg", imageAlt: "dual bag concrete mixer industrial equipment"
|
||||
@@ -154,7 +154,7 @@ export default function LandingPage() {
|
||||
id: "8", name: "Mixer with Lift", price: "Contact for Quote", imageSrc: "http://img.b2bpic.net/free-photo/tractor-operator-sand-pit_1398-1271.jpg", imageAlt: "mixer with lift machine combination equipment"
|
||||
},
|
||||
{
|
||||
id: "9", name: "Construction Trolleys", price: "Contact for Quote", imageSrc: "http://img.b2bpic.net/free-photo/excavator-digging-ground-day-light_23-2149194796.jpg?_wi=2", imageAlt: "heavy duty construction trolley cart equipment"
|
||||
id: "9", name: "Construction Trolleys", price: "Contact for Quote", imageSrc: "http://img.b2bpic.net/free-photo/excavator-digging-ground-day-light_23-2149194796.jpg", imageAlt: "heavy duty construction trolley cart equipment"
|
||||
}
|
||||
]}
|
||||
/>
|
||||
@@ -208,7 +208,7 @@ export default function LandingPage() {
|
||||
<TeamCardTen
|
||||
title="Building Excellence Together: Brothers in Business"
|
||||
tag="Our Founders"
|
||||
membersAnimation="entrance-slide"
|
||||
membersAnimation="slide-up"
|
||||
memberVariant="card"
|
||||
useInvertedBackground={true}
|
||||
members={[
|
||||
|
||||
@@ -1,51 +1,46 @@
|
||||
"use client";
|
||||
|
||||
import { memo } from "react";
|
||||
import useSvgTextLogo from "./useSvgTextLogo";
|
||||
import { cls } from "@/lib/utils";
|
||||
import React from "react";
|
||||
|
||||
interface SvgTextLogoProps {
|
||||
logoText: string;
|
||||
adjustHeightFactor?: number;
|
||||
verticalAlign?: "top" | "center";
|
||||
text: string;
|
||||
className?: string;
|
||||
textClassName?: string;
|
||||
fontSize?: number;
|
||||
fontWeight?: number | string;
|
||||
letterSpacing?: number;
|
||||
}
|
||||
|
||||
const SvgTextLogo = memo<SvgTextLogoProps>(function SvgTextLogo({
|
||||
logoText,
|
||||
adjustHeightFactor,
|
||||
verticalAlign = "top",
|
||||
className = "",
|
||||
}) {
|
||||
const { svgRef, textRef, viewBox, aspectRatio } = useSvgTextLogo(logoText, false, adjustHeightFactor);
|
||||
const SvgTextLogo: React.FC<SvgTextLogoProps> = ({
|
||||
text,
|
||||
className = "", textClassName = "", fontSize = 24,
|
||||
fontWeight = 700,
|
||||
letterSpacing = 0,
|
||||
}) => {
|
||||
const estimatedWidth = text.length * (fontSize * 0.6) + letterSpacing * text.length;
|
||||
const padding = fontSize * 0.5;
|
||||
const viewBoxWidth = estimatedWidth + padding * 2;
|
||||
const viewBoxHeight = fontSize * 1.5;
|
||||
|
||||
return (
|
||||
<svg
|
||||
ref={svgRef}
|
||||
viewBox={viewBox}
|
||||
className={cls("w-full", className)}
|
||||
style={{ aspectRatio: aspectRatio }}
|
||||
preserveAspectRatio="none"
|
||||
role="img"
|
||||
aria-label={`${logoText} logo`}
|
||||
viewBox={`0 0 ${viewBoxWidth} ${viewBoxHeight}`}
|
||||
width={viewBoxWidth}
|
||||
height={viewBoxHeight}
|
||||
className={className}
|
||||
preserveAspectRatio="xMidYMid meet"
|
||||
>
|
||||
<text
|
||||
ref={textRef}
|
||||
x="0"
|
||||
y={verticalAlign === "center" ? "50%" : "0"}
|
||||
className="font-bold fill-current"
|
||||
style={{
|
||||
fontSize: "20px",
|
||||
letterSpacing: "-0.02em",
|
||||
dominantBaseline: verticalAlign === "center" ? "middle" : "text-before-edge"
|
||||
}}
|
||||
x={padding}
|
||||
y={fontSize}
|
||||
fontSize={fontSize}
|
||||
fontWeight={fontWeight}
|
||||
letterSpacing={letterSpacing}
|
||||
dominantBaseline="middle"
|
||||
className={textClassName}
|
||||
>
|
||||
{logoText}
|
||||
{text}
|
||||
</text>
|
||||
</svg>
|
||||
);
|
||||
});
|
||||
|
||||
SvgTextLogo.displayName = "SvgTextLogo";
|
||||
};
|
||||
|
||||
export default SvgTextLogo;
|
||||
|
||||
Reference in New Issue
Block a user