diff --git a/src/components/sections/FooterSection.astro b/src/components/sections/FooterSection.astro index c1821e0..5bba7b4 100644 --- a/src/components/sections/FooterSection.astro +++ b/src/components/sections/FooterSection.astro @@ -2,7 +2,7 @@ // Import the necessary dependencies import FooterSocialLink from "../ui/links/FooterSocialLink.astro"; import EmailFooterInput from "../ui/forms/input/EmailFooterInput.astro"; -import { footerLinks, socialLinks } from "../../utils/navigation.ts"; +import { footerLinks, socialLinks } from "@/utils/navigation.ts"; import Icon from "../ui/icons/Icon.astro"; // Define the variables that will be used in this component diff --git a/src/components/sections/Navbar.astro b/src/components/sections/Navbar.astro index 027269f..53c9b73 100644 --- a/src/components/sections/Navbar.astro +++ b/src/components/sections/Navbar.astro @@ -3,7 +3,7 @@ import ThemeIcon from "../ThemeIcon.astro"; import NavLink from "../ui/links/NavLink.astro"; import Authentication from "./Authentication.astro"; -import { navBarLinks } from "../../utils/navigation.ts"; +import { navBarLinks } from "@/utils/navigation.ts"; --- diff --git a/src/components/sections/features/FeaturesStatsAlt.astro b/src/components/sections/features/FeaturesStatsAlt.astro index 350e122..7de64e6 100644 --- a/src/components/sections/features/FeaturesStatsAlt.astro +++ b/src/components/sections/features/FeaturesStatsAlt.astro @@ -1,6 +1,6 @@ --- import { Image } from "astro:assets"; -import product5 from "../../../images/features-image.avif"; +import product5 from "@/images/features-image.avif"; // Define props from Astro const { title, subTitle, benefits } = Astro.props; diff --git a/src/components/ui/cards/CardBlog.astro b/src/components/ui/cards/CardBlog.astro index 80d45fc..0c5056a 100644 --- a/src/components/ui/cards/CardBlog.astro +++ b/src/components/ui/cards/CardBlog.astro @@ -2,7 +2,7 @@ // Import necessary components and utilities import AvatarBlog from "../avatars/AvatarBlog.astro"; import { Image } from "astro:assets"; -import { formatDate } from "../../../utils/utils"; +import { formatDate } from "@/utils/utils"; import type { CollectionEntry } from "astro:content"; const { blogEntry } = Astro.props; diff --git a/src/components/ui/cards/CardRelated.astro b/src/components/ui/cards/CardRelated.astro index 217ac0b..41a669a 100644 --- a/src/components/ui/cards/CardRelated.astro +++ b/src/components/ui/cards/CardRelated.astro @@ -1,7 +1,7 @@ --- // Import necessary modules and utilities import { Image } from "astro:assets"; -import { formatDate } from "../../../utils/utils"; +import { formatDate } from "@/utils/utils"; import type { CollectionEntry } from "astro:content"; const { blogEntry } = Astro.props; diff --git a/src/components/ui/starlight/SiteTitle.astro b/src/components/ui/starlight/SiteTitle.astro index 6d730a6..db03bc5 100644 --- a/src/components/ui/starlight/SiteTitle.astro +++ b/src/components/ui/starlight/SiteTitle.astro @@ -1,6 +1,6 @@ --- -import logo from "../../../images/starlight/screwfast_logo_dark.svg?raw"; -import docs from "../../../images/starlight/docs_logo.svg?raw"; +import logo from "@/images/starlight/screwfast_logo_dark.svg?raw"; +import docs from "@/images/starlight/docs_logo.svg?raw"; import type { Props } from "@astrojs/starlight/props"; const main = "/"; diff --git a/src/content/blog/post-1.md b/src/content/blog/post-1.md index 0b8fd19..b4c3aaa 100644 --- a/src/content/blog/post-1.md +++ b/src/content/blog/post-1.md @@ -2,10 +2,10 @@ title: "Maximizing Efficiency with ScrewFast's Cutting-Edge Tools" description: "Innovating Construction Efficiency with Precision Tools & Support" author: "Jacob" -authorImage: "../../images/blog/jacob.avif" +authorImage: "@/images/blog/jacob.avif" authorImageAlt: "Avatar Description" pubDate: 2024-02-06 -cardImage: "../../images/blog/post-1.avif" +cardImage: "@/images/blog/post-1.avif" cardImageAlt: "Top view mechanical tools arrangement" readTime: 4 tags: ["tools", "construction", "workflow" ] diff --git a/src/content/blog/post-2.md b/src/content/blog/post-2.md index 7cd7e5b..17d80ce 100644 --- a/src/content/blog/post-2.md +++ b/src/content/blog/post-2.md @@ -2,10 +2,10 @@ title: "Enhancing Safety and Workmanship with ScrewFast Construction Services" description: "Quality construction services for lasting results" author: "Brad" -authorImage: "../../images/blog/brad.avif" +authorImage: "@/images/blog/brad.avif" authorImageAlt: "Avatar Description" pubDate: 2024-02-10 -cardImage: "../../images/blog/post-2.avif" +cardImage: "@/images/blog/post-2.avif" cardImageAlt: "Man in black sweatpants using DEWALT circular saw and cutting a wood plank" readTime: 5 tags: ["safety", "craftsmanship", "management" ] diff --git a/src/content/blog/post-3.md b/src/content/blog/post-3.md index 0d4348d..7f6add0 100644 --- a/src/content/blog/post-3.md +++ b/src/content/blog/post-3.md @@ -3,10 +3,10 @@ title: "Simplify Procurement and Stay Within Budget with ScrewFast" description: "Affordable, durable tools for efficient construction projects" author: "Olga Zabegina" role: "Strategic Marketing Manager" -authorImage: "../../images/blog/anna.avif" +authorImage: "@/images/blog/anna.avif" authorImageAlt: "Avatar Description" pubDate: 2024-02-18 -cardImage: "../../images/blog/post-3.avif" +cardImage: "@/images/blog/post-3.avif" cardImageAlt: "Side view worker wearing gloves" readTime: 3 tags: ["procurement", "affordable", "efficiency" ] diff --git a/src/content/insights/insight-1.md b/src/content/insights/insight-1.md index abac73f..74022e9 100644 --- a/src/content/insights/insight-1.md +++ b/src/content/insights/insight-1.md @@ -1,7 +1,7 @@ --- title: "The Future of Construction Technology" description: "Explore ScrewFast's pioneering role in revolutionizing construction through advanced technology and innovative solutions." -cardImage: "../../images/insights/insight-1.avif" +cardImage: "@/images/insights/insight-1.avif" cardImageAlt: "Top view mechanical tools arrangement" contents: [ "As technology continues to evolve, so too does the construction industry. From advanced robotics to augmented reality, the possibilities for innovation are endless. At ScrewFast, we're at the forefront of this technological revolution, developing cutting-edge tools and solutions to drive the industry forward.", diff --git a/src/content/insights/insight-2.md b/src/content/insights/insight-2.md index 8d063c6..2620744 100644 --- a/src/content/insights/insight-2.md +++ b/src/content/insights/insight-2.md @@ -1,7 +1,7 @@ --- title: "The Importance of Collaboration" description: "Explore how collaboration is central to ScrewFast's construction approach, driving effective communication and teamwork to achieve outstanding outcomes." -cardImage: "../../images/insights/insight-2.avif" +cardImage: "@/images/insights/insight-2.avif" cardImageAlt: "Top view mechanical tools arrangement" contents: [ "Construction projects are complex undertakings that require collaboration and coordination among various stakeholders. From architects and engineers to contractors and suppliers, effective collaboration is essential for success.", diff --git a/src/content/insights/insight-3.md b/src/content/insights/insight-3.md index ae6599e..b8ba501 100644 --- a/src/content/insights/insight-3.md +++ b/src/content/insights/insight-3.md @@ -1,7 +1,7 @@ --- title: "The Impact of Sustainable Practices" description: "Discover how ScrewFast is leading the charge in promoting sustainability within the construction industry" -cardImage: "../../images/insights/insight-3.avif" +cardImage: "@/images/insights/insight-3.avif" cardImageAlt: "Top view mechanical tools arrangement" contents: [ "With growing concerns about climate change and environmental sustainability, the construction industry is facing increasing pressure to adopt more eco-friendly practices. At ScrewFast, we're committed to doing our part to minimize our environmental footprint and promote sustainability in everything we do.", diff --git a/src/content/products/a765.md b/src/content/products/a765.md index 24c2505..639668c 100644 --- a/src/content/products/a765.md +++ b/src/content/products/a765.md @@ -5,8 +5,8 @@ main: subTitle: "Assorted Screw Set" content: | Introducing the SF-AB A765 Assorted Screw Set – the ultimate solution for your screw fastening needs. This comprehensive set includes a wide variety of screws meticulously curated to tackle various projects with ease and precision. - imgCard: "../../images/product-image-2.avif" - imgMain: "../../images/product-image-main-2.avif" + imgCard: "@/images/product-image-2.avif" + imgMain: "@/images/product-image-main-2.avif" imgAlt: "Mockup boxes of assorted screw set" tabs: - id: "tabs-with-card-item-1" @@ -50,7 +50,7 @@ specificationsRight: - title: "Applications" subTitle: "Suitable for a wide range of applications, including woodworking, metalworking, construction, and more." blueprints: - first: "../../images/blueprint-1.avif" - second: "../../images/blueprint-2.avif" + first: "@/images/blueprint-1.avif" + second: "@/images/blueprint-2.avif" slug: a765 --- diff --git a/src/content/products/b203.md b/src/content/products/b203.md index 4302560..ecba7a0 100644 --- a/src/content/products/b203.md +++ b/src/content/products/b203.md @@ -5,8 +5,8 @@ main: subTitle: "Tap Bolts and Nuts Set" content: | Meet the SF-BN B203 – your reliable companion for professional-grade fastening. This comprehensive box set comes with a versatile selection of tap bolts and nuts, meticulously crafted to provide the strongest hold for your construction and assembly projects. - imgCard: "../../images/product-image-3.avif" - imgMain: "../../images/product-image-main-3.avif" + imgCard: "@/images/product-image-3.avif" + imgMain: "@/images/product-image-main-3.avif" imgAlt: "Mockup boxes of a tap bolts and nuts set" tabs: - id: "tabs-with-card-item-1" @@ -50,7 +50,7 @@ specificationsRight: - title: "Suitable Applications" subTitle: "Ideal for a wide array of uses, from construction environments to mechanical assemblies that demand strong and secure joints." blueprints: - first: "../../images/blueprint-1.avif" - second: "../../images/blueprint-2.avif" + first: "@/images/blueprint-1.avif" + second: "@/images/blueprint-2.avif" slug: b203 --- diff --git a/src/content/products/f303.md b/src/content/products/f303.md index 4a5b977..5292a05 100644 --- a/src/content/products/f303.md +++ b/src/content/products/f303.md @@ -5,8 +5,8 @@ main: subTitle: "Hex Bolts" content: | Introducing the SF-FN F303 Hex Bolts – the perfect choice for heavy-duty fastening applications. Crafted with precision and durability in mind, these hex bolts provide the strength and reliability you need for your toughest projects. - imgCard: "../../images/product-image-4.avif" - imgMain: "../../images/product-image-main-4.avif" + imgCard: "@/images/product-image-4.avif" + imgMain: "@/images/product-image-main-4.avif" imgAlt: "Mockup boxes of hex bolts" tabs: - id: "tabs-with-card-item-1" @@ -50,7 +50,7 @@ specificationsRight: - title: "Applications" subTitle: "Ideal for use in construction, machinery, automotive, and other heavy-duty applications that demand strong and reliable fastening." blueprints: - first: "../../images/blueprint-1.avif" - second: "../../images/blueprint-2.avif" + first: "@/images/blueprint-1.avif" + second: "@/images/blueprint-2.avif" slug: f303 --- diff --git a/src/content/products/t845.md b/src/content/products/t845.md index f1c16f8..43e8471 100644 --- a/src/content/products/t845.md +++ b/src/content/products/t845.md @@ -5,8 +5,8 @@ main: subTitle: "Machine Screws" content: | Introducing the SF-TB T845 – your go-to solution for precision fastening in machinery and equipment. This comprehensive set of machine screws is meticulously crafted to meet the stringent demands of industrial applications, ensuring secure and reliable fastening. - imgCard: "../../images/product-image-1.avif" - imgMain: "../../images/product-image-main-1.avif" + imgCard: "@/images/product-image-1.avif" + imgMain: "@/images/product-image-main-1.avif" imgAlt: "Mockup boxes of machine screws set" tabs: - id: "tabs-with-card-item-1" @@ -50,7 +50,7 @@ specificationsRight: - title: "Applications" subTitle: "Ideal for use in a wide range of industrial machinery, equipment, and assemblies that demand precise and secure fastening." blueprints: - first: "../../images/blueprint-1.avif" - second: "../../images/blueprint-2.avif" + first: "@/images/blueprint-1.avif" + second: "@/images/blueprint-2.avif" slug: t845 --- diff --git a/src/layouts/MainLayout.astro b/src/layouts/MainLayout.astro index abe753e..a37c802 100644 --- a/src/layouts/MainLayout.astro +++ b/src/layouts/MainLayout.astro @@ -1,17 +1,18 @@ --- // Importing necessary components -import Meta from "../components/Meta.astro"; -import Navbar from "../components/sections/Navbar.astro"; -import FooterSection from "../components/sections/FooterSection.astro"; +import Meta from "@/components/Meta.astro"; +import Navbar from "@/components/sections/Navbar.astro"; +import FooterSection from "@/components/sections/FooterSection.astro"; // Setting expected props -const { title = "ScrewFast", meta, structuredData } = Astro.props; +const { title = "ScrewFast", meta, structuredData, lang = "en" } = Astro.props; // Interface to type-check the properties interface Props { title?: string; meta?: string; structuredData?: object; + lang?: string; } --- @@ -19,7 +20,7 @@ interface Props { This is the main structure for the page. We set the language of the page to English and add classes for scrollbar and scroll behavior. --> - + diff --git a/src/pages/404.astro b/src/pages/404.astro index dda7b50..9d5281c 100644 --- a/src/pages/404.astro +++ b/src/pages/404.astro @@ -1,7 +1,7 @@ --- // Import section components -import MainLayout from "../layouts/MainLayout.astro"; -import Btn404 from "../components/ui/buttons/Btn404.astro"; +import MainLayout from "@/layouts/MainLayout.astro"; +import Btn404 from "@/components/ui/buttons/Btn404.astro"; // Define variables for page content const title: string = "404"; diff --git a/src/pages/blog/[...slug].astro b/src/pages/blog/[...slug].astro index a62d2c7..0fff043 100644 --- a/src/pages/blog/[...slug].astro +++ b/src/pages/blog/[...slug].astro @@ -1,13 +1,13 @@ --- // Import necessary components and utilities -import MainLayout from "../../layouts/MainLayout.astro"; -import AvatarBlogLarge from "../../components/ui/avatars/AvatarBlogLarge.astro"; -import CardRelated from "../../components/ui/cards/CardRelated.astro"; -import Bookmark from "../../components/ui/buttons/Bookmark.astro"; -import SocialShare from "../../components/ui/buttons/SocialShare.astro"; -import PostFeedback from "../../components/ui/feedback/PostFeedback.astro"; +import MainLayout from "@/layouts/MainLayout.astro"; +import AvatarBlogLarge from "@/components/ui/avatars/AvatarBlogLarge.astro"; +import CardRelated from "@/components/ui/cards/CardRelated.astro"; +import Bookmark from "@/components/ui/buttons/Bookmark.astro"; +import SocialShare from "@/components/ui/buttons/SocialShare.astro"; +import PostFeedback from "@/components/ui/feedback/PostFeedback.astro"; import { Image } from "astro:assets"; -import { capitalize, formatDate } from "../../utils/utils"; +import { capitalize, formatDate } from "@/utils/utils"; import { getCollection } from "astro:content"; import type { CollectionEntry } from "astro:content"; diff --git a/src/pages/blog/index.astro b/src/pages/blog/index.astro index 75f598e..ae058c6 100644 --- a/src/pages/blog/index.astro +++ b/src/pages/blog/index.astro @@ -1,9 +1,9 @@ --- // Import necessary components, modules and types -import MainLayout from "../../layouts/MainLayout.astro"; -import CardBlog from "../../components/ui/cards/CardBlog.astro"; -import CardBlogRecent from "../../components/ui/cards/CardBlogRecent.astro"; -import CardInsight from "../../components/ui/cards/CardInsight.astro"; +import MainLayout from "@/layouts/MainLayout.astro"; +import CardBlog from "@/components/ui/cards/CardBlog.astro"; +import CardBlogRecent from "@/components/ui/cards/CardBlogRecent.astro"; +import CardInsight from "@/components/ui/cards/CardInsight.astro"; import { getCollection } from "astro:content"; import type { CollectionEntry } from "astro:content"; diff --git a/src/pages/contact.astro b/src/pages/contact.astro index aa4c782..1efb1f8 100644 --- a/src/pages/contact.astro +++ b/src/pages/contact.astro @@ -1,7 +1,7 @@ --- // Import the necessary components -import MainLayout from "../layouts/MainLayout.astro"; -import ContactSection from "../components/sections/ContactSection.astro"; +import MainLayout from "@/layouts/MainLayout.astro"; +import ContactSection from "@/components/sections/ContactSection.astro"; --- diff --git a/src/pages/index.astro b/src/pages/index.astro index d5a259a..327ef1b 100644 --- a/src/pages/index.astro +++ b/src/pages/index.astro @@ -1,22 +1,22 @@ --- // Import the necessary components -import MainLayout from "../layouts/MainLayout.astro"; -import HeroSection from "../components/sections/landing/HeroSection.astro"; -import HeroSectionAlt from "../components/sections/landing/HeroSectionAlt.astro"; -import ClientsSection from "../components/sections/landing/ClientsSection.astro"; -import FeaturesGeneral from "../components/sections/features/FeaturesGeneral.astro"; -import FeaturesNavs from "../components/sections/features/FeaturesNavs.astro"; -import TestimonialsSection from "../components/sections/testimonials/TestimonialsSection.astro"; -import PricingSection from "../components/sections/pricing/PricingSection.astro"; -import FAQ from "../components/sections/FAQ.astro"; -import AnnouncementBanner from "../components/ui/banners/AnnouncementBanner.astro"; -import heroImage from "../images/hero-image.avif"; -import faqs from "../data_files/faqs.json"; -import features from "../data_files/features.json"; -import featureImage from "../images/features-image.avif"; -import construction from "../images/construction-image.avif"; -import tools from "../images/automated-tools.avif"; -import dashboard from "../images/dashboard-image.avif"; +import MainLayout from "@/layouts/MainLayout.astro"; +import HeroSection from "@/components/sections/landing/HeroSection.astro"; +import HeroSectionAlt from "@/components/sections/landing/HeroSectionAlt.astro"; +import ClientsSection from "@/components/sections/landing/ClientsSection.astro"; +import FeaturesGeneral from "@/components/sections/features/FeaturesGeneral.astro"; +import FeaturesNavs from "@/components/sections/features/FeaturesNavs.astro"; +import TestimonialsSection from "@/components/sections/testimonials/TestimonialsSection.astro"; +import PricingSection from "@/components/sections/pricing/PricingSection.astro"; +import FAQ from "@/components/sections/FAQ.astro"; +import AnnouncementBanner from "@/components/ui/banners/AnnouncementBanner.astro"; +import heroImage from "@/images/hero-image.avif"; +import faqs from "@/data_files/faqs.json"; +import features from "@/data_files/features.json"; +import featureImage from "@/images/features-image.avif"; +import construction from "@/images/construction-image.avif"; +import tools from "@/images/automated-tools.avif"; +import dashboard from "@/images/dashboard-image.avif"; const avatarSrcs: Array = [ "https://images.unsplash.com/photo-1568602471122-7832951cc4c5?ixlib=rb-4.0.3&ixid=MnwxMjA3fDB8MHxwaG90by1wYWdlfHx8fGVufDB8fHx8&auto=format&fit=facearea&facepad=2&w=300&h=300&q=80", diff --git a/src/pages/insights/[...slug].astro b/src/pages/insights/[...slug].astro index e28c54e..0d0ddc5 100644 --- a/src/pages/insights/[...slug].astro +++ b/src/pages/insights/[...slug].astro @@ -1,6 +1,6 @@ --- // Import section components -import MainLayout from "../../layouts/MainLayout.astro"; +import MainLayout from "@/layouts/MainLayout.astro"; import { Image } from "astro:assets"; import { getCollection } from "astro:content"; diff --git a/src/pages/products/[...slug].astro b/src/pages/products/[...slug].astro index 3ead72a..3e68918 100644 --- a/src/pages/products/[...slug].astro +++ b/src/pages/products/[...slug].astro @@ -1,8 +1,8 @@ --- // Import section components -import MainLayout from "../../layouts/MainLayout.astro"; -import ProductTabBtn from "../../components/ui/buttons/ProductTabBtn.astro"; -import PrimaryCTA from "../../components/ui/buttons/PrimaryCTA.astro"; +import MainLayout from "@/layouts/MainLayout.astro"; +import ProductTabBtn from "@/components/ui/buttons/ProductTabBtn.astro"; +import PrimaryCTA from "@/components/ui/buttons/PrimaryCTA.astro"; import { Image } from "astro:assets"; import { getCollection } from "astro:content"; diff --git a/src/pages/products/index.astro b/src/pages/products/index.astro index 3001cf9..cb103be 100644 --- a/src/pages/products/index.astro +++ b/src/pages/products/index.astro @@ -1,11 +1,11 @@ --- // Importing necessary components -import MainLayout from "../../layouts/MainLayout.astro"; -import PrimaryCTA from "../../components/ui/buttons/PrimaryCTA.astro"; -import CardSmall from "../../components/ui/cards/CardSmall.astro"; -import CardWide from "../../components/ui/cards/CardWide.astro"; -import FeaturesStatsAlt from "../../components/sections/features/FeaturesStatsAlt.astro"; -import TestimonialsSectionAlt from "../../components/sections/testimonials/TestimonialsSectionAlt.astro"; +import MainLayout from "@/layouts/MainLayout.astro"; +import PrimaryCTA from "@/components/ui/buttons/PrimaryCTA.astro"; +import CardSmall from "@/components/ui/cards/CardSmall.astro"; +import CardWide from "@/components/ui/cards/CardWide.astro"; +import FeaturesStatsAlt from "@/components/sections/features/FeaturesStatsAlt.astro"; +import TestimonialsSectionAlt from "@/components/sections/testimonials/TestimonialsSectionAlt.astro"; // Importing necessary functions from Astro import { getCollection } from "astro:content"; diff --git a/src/pages/services.astro b/src/pages/services.astro index dea44fa..ac2d0c4 100644 --- a/src/pages/services.astro +++ b/src/pages/services.astro @@ -1,20 +1,20 @@ --- // Import necessary components -import MainLayout from "../layouts/MainLayout.astro"; -import MainSection from "../components/ui/blocks/MainSection.astro"; -import LeftSection from "../components/ui/blocks/LeftSection.astro"; -import RightSection from "../components/ui/blocks/RightSection.astro"; -import FeaturesStats from "../components/sections/features/FeaturesStats.astro"; +import MainLayout from "@/layouts/MainLayout.astro"; +import MainSection from "@/components/ui/blocks/MainSection.astro"; +import LeftSection from "@/components/ui/blocks/LeftSection.astro"; +import RightSection from "@/components/ui/blocks/RightSection.astro"; +import FeaturesStats from "@/components/sections/features/FeaturesStats.astro"; // Import necessary images -import blueprints from "../images/blueprints-image.avif"; -import personWorking from "../images/person-working.avif"; -import beforeAfter from "../images/before-after.avif"; -import constructionWorkers from "../images/construction-workers.avif"; -import aerialView from "../images/aerial-view.avif"; -import usingTools from "../images/using-tools.avif"; -import progressBuilding from "../images/progress-building.avif"; -import underConstruction from "../images/under-construction.avif"; +import blueprints from "@/images/blueprints-image.avif"; +import personWorking from "@/images/person-working.avif"; +import beforeAfter from "@/images/before-after.avif"; +import constructionWorkers from "@/images/construction-workers.avif"; +import aerialView from "@/images/aerial-view.avif"; +import usingTools from "@/images/using-tools.avif"; +import progressBuilding from "@/images/progress-building.avif"; +import underConstruction from "@/images/under-construction.avif"; interface Article { isRightSection: boolean; diff --git a/tsconfig.json b/tsconfig.json index 77da9dd..f356c6f 100644 --- a/tsconfig.json +++ b/tsconfig.json @@ -1,3 +1,9 @@ { - "extends": "astro/tsconfigs/strict" + "extends": "astro/tsconfigs/strict", + "compilerOptions": { + "baseUrl": ".", + "paths": { + "@/*": ["src/*"] + }, + } } \ No newline at end of file