Skip to content

Commit

Permalink
test img tailwind
Browse files Browse the repository at this point in the history
  • Loading branch information
clara7227 committed Oct 16, 2024
1 parent ed97715 commit 9c23c6a
Show file tree
Hide file tree
Showing 4 changed files with 11 additions and 11 deletions.
6 changes: 2 additions & 4 deletions app/page.js
Original file line number Diff line number Diff line change
Expand Up @@ -12,9 +12,7 @@ import Text from "@/components/ui/Text";
import { ArrowRightIcon, EnvelopeOpenIcon } from "@radix-ui/react-icons";
import Image from "@/components/ui/image";

// componentDidMount() {
// document.title = "Boiler GING";
// }

import {
CustomCard,
CardContent,
Expand Down Expand Up @@ -66,7 +64,7 @@ export default function Page() {
</Button>
</BannerContent>
<Image
src="placeholder.png"
src="placeholder.jpg"
alt="Descripción de la imagen"
fit="cover"
hasBadge={false}
Expand Down
4 changes: 0 additions & 4 deletions components/core/Cards.jsx
Original file line number Diff line number Diff line change
Expand Up @@ -31,10 +31,6 @@ import {
} from "@radix-ui/react-icons";
import Link from "next/link";

// const config = require('../../next.config');
// console.log(config.basePath)
// console.log(config)

const CardVariants = cva(
"border border-primary min-w-20 p-4 inline-flex flex-col gap-4 items-center whitespace-nowrap rounded-md font-body text-sm text-text drop-shadow-md hover:scale-[101%] transition-all overflow-hidden",
{
Expand Down
4 changes: 2 additions & 2 deletions next.config.mjs
Original file line number Diff line number Diff line change
Expand Up @@ -47,8 +47,8 @@ const nextConfig = {
* Environment variables
*/
env: {
PUBLIC_URL: isProd ? "https://ging.github.io/boiler/" : "",
BASE_PATH: isProd ? "" : ""
PUBLIC_URL: isProd ? "/boiler" : "",
BASE_PATH: isProd ? "/boiler" : ""
}
};

Expand Down
8 changes: 7 additions & 1 deletion tailwind.config.js
Original file line number Diff line number Diff line change
Expand Up @@ -3,6 +3,12 @@
const plugin = require('tailwindcss/plugin');
import { Card, CardVariants } from "@/components/core/Cards";

const config = require('./next.config.mjs');
console.log(config.basePath)
console.log(config.default.basePath)

// const basePathTailwind = config.default.basePath;
const basePathTailwind = process.env.BASE_PATH || '';

module.exports = {
content: [
Expand Down Expand Up @@ -98,7 +104,7 @@ module.exports = {
'2xl': '1536px',
},
backgroundImage: {
'main': "url('/boiler/assets/fondos/background_banner.png')",
'main': `url('${basePathTailwind}/assets/fondos/background_banner.png')`,
}
},
plugins: [
Expand Down

0 comments on commit 9c23c6a

Please sign in to comment.