Skip to content

Commit

Permalink
fix: rename className to class
Browse files Browse the repository at this point in the history
  • Loading branch information
gsbenevides2 committed Nov 5, 2024
1 parent 086b618 commit 700afaa
Show file tree
Hide file tree
Showing 36 changed files with 224 additions and 215 deletions.
12 changes: 6 additions & 6 deletions components/Icons/IconChevronsDown.tsx
Original file line number Diff line number Diff line change
@@ -1,11 +1,11 @@
interface Props {
className?: string;
strokeClassName?: string;
class?: string;
strokeclass?: string;
strokeWidth?: number;
}

export function IconCheveronsDown(
{ className, strokeClassName, strokeWidth }: Props,
{ class: className, strokeclass, strokeWidth }: Props,
) {
return (
<svg
Expand All @@ -14,18 +14,18 @@ export function IconCheveronsDown(
viewBox="0 0 24 24"
fill="none"
xmlns="http://www.w3.org/2000/svg"
className={className}
class={className}
>
<path
d="M7 13L12 18L17 13"
className={strokeClassName}
class={strokeclass}
stroke-width={strokeWidth ?? "2"}
stroke-linecap="round"
stroke-linejoin="round"
/>
<path
d="M7 6L12 11L17 6"
className={strokeClassName}
class={strokeclass}
stroke-width={strokeWidth ?? "2"}
stroke-linecap="round"
stroke-linejoin="round"
Expand Down
12 changes: 6 additions & 6 deletions components/Icons/IconChevronsUp.tsx
Original file line number Diff line number Diff line change
@@ -1,11 +1,11 @@
interface Props {
className?: string;
strokeClassName?: string;
class?: string;
strokeclass?: string;
strokeWidth?: number;
}

export function IconCheveronsUp(
{ className, strokeClassName, strokeWidth }: Props,
{ class: className, strokeclass, strokeWidth }: Props,
) {
return (
<svg
Expand All @@ -14,18 +14,18 @@ export function IconCheveronsUp(
viewBox="0 0 24 24"
fill="none"
xmlns="http://www.w3.org/2000/svg"
className={className}
class={className}
>
<path
d="M17 11L12 6L7 11"
className={strokeClassName}
class={strokeclass}
stroke-width={strokeWidth ?? "2"}
stroke-linecap="round"
stroke-linejoin="round"
/>
<path
d="M17 18L12 13L7 18"
className={strokeClassName}
class={strokeclass}
stroke-width={strokeWidth ?? "2"}
stroke-linecap="round"
stroke-linejoin="round"
Expand Down
6 changes: 3 additions & 3 deletions components/Icons/IconMenuDrawerOpen.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -9,21 +9,21 @@ export function IconMenuDrawerOpen() {
>
<path
d="M2.5 10H17.5"
className="stroke-primary"
class="stroke-primary"
stroke-width="2"
stroke-linecap="round"
stroke-linejoin="round"
/>
<path
d="M2.5 5H17.5"
className="stroke-primary"
class="stroke-primary"
stroke-width="2"
stroke-linecap="round"
stroke-linejoin="round"
/>
<path
d="M2.5 15H17.5"
className="stroke-primary"
class="stroke-primary"
stroke-width="2"
stroke-linecap="round"
stroke-linejoin="round"
Expand Down
12 changes: 7 additions & 5 deletions components/Icons/IconMinus.tsx
Original file line number Diff line number Diff line change
@@ -1,21 +1,23 @@
interface Props {
className?: string;
strokeClassName?: string;
class?: string;
strokeclass?: string;
strokeWidth?: number;
}
export function IconMinus({ className, strokeClassName, strokeWidth }: Props) {
export function IconMinus(
{ class: className, strokeclass, strokeWidth }: Props,
) {
return (
<svg
width="24"
height="24"
viewBox="0 0 24 24"
fill="none"
xmlns="http://www.w3.org/2000/svg"
className={className}
class={className}
>
<path
d="M5 12H19"
className={strokeClassName}
class={strokeclass}
stroke-width={strokeWidth ?? "2"}
stroke-linecap="round"
stroke-linejoin="round"
Expand Down
14 changes: 8 additions & 6 deletions components/Icons/IconPlus.tsx
Original file line number Diff line number Diff line change
@@ -1,31 +1,33 @@
interface Props {
className?: string;
strokeClassName?: string;
class?: string;
strokeclass?: string;
strokeWidth?: number;
}
export function IconPlus({ className, strokeClassName, strokeWidth }: Props) {
export function IconPlus(
{ class: className, strokeclass, strokeWidth }: Props,
) {
return (
<svg
width="24"
height="24"
viewBox="0 0 24 24"
fill="none"
xmlns="http://www.w3.org/2000/svg"
className={className}
class={className}
>
<path
d="M12 5V19"
stroke-width={strokeWidth ?? "2"}
stroke-linecap="round"
stroke-linejoin="round"
className={strokeClassName}
class={strokeclass}
/>
<path
d="M5 12H19"
stroke-width={strokeWidth ?? "2"}
stroke-linecap="round"
stroke-linejoin="round"
className={strokeClassName}
class={strokeclass}
/>
</svg>
);
Expand Down
10 changes: 5 additions & 5 deletions components/Icons/IconUser.tsx
Original file line number Diff line number Diff line change
@@ -1,29 +1,29 @@
import { clx } from "../../sdk/clx.ts";

interface Props {
className?: string;
class?: string;
}

export function IconUser({ className = "" }: Props) {
export function IconUser({ class: className = "" }: Props) {
return (
<svg
width="20"
height="20"
viewBox="0 0 20 20"
fill="none"
xmlns="http://www.w3.org/2000/svg"
className={clx(className)}
class={clx(className)}
>
<path
d="M16.6663 17.5V15.8333C16.6663 14.9493 16.3152 14.1014 15.69 13.4763C15.0649 12.8512 14.2171 12.5 13.333 12.5H6.66634C5.78229 12.5 4.93444 12.8512 4.30932 13.4763C3.6842 14.1014 3.33301 14.9493 3.33301 15.8333V17.5"
className="stroke-primary"
class="stroke-primary"
stroke-width="2"
stroke-linecap="round"
stroke-linejoin="round"
/>
<path
d="M10.0003 9.16667C11.8413 9.16667 13.3337 7.67428 13.3337 5.83333C13.3337 3.99238 11.8413 2.5 10.0003 2.5C8.15938 2.5 6.66699 3.99238 6.66699 5.83333C6.66699 7.67428 8.15938 9.16667 10.0003 9.16667Z"
className="stroke-primary"
class="stroke-primary"
stroke-width="2"
stroke-linecap="round"
stroke-linejoin="round"
Expand Down
2 changes: 1 addition & 1 deletion components/Session.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -320,7 +320,7 @@ export default function Session(
drawer={MINICART_DRAWER_ID}
class="max-w-full desk:max-w-[375px] desk:w-full"
>
<div className="h-full flex flex-col bg-base-100 items-center justify-center overflow-auto border-none w-full">
<div class="h-full flex flex-col bg-base-100 items-center justify-center overflow-auto border-none w-full">
<CartProvider
cart={minicart!}
minicartSettings={props.minicartClientSettings}
Expand Down
12 changes: 6 additions & 6 deletions components/footer/Card.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -6,7 +6,7 @@ export function Card(props: CardProps) {
const { image } = props;

return (
<article className="bg-primary flex text-white gap-[10px] items-center p-[10px] desk:p-5 rounded-2xl">
<article class="bg-primary flex text-white gap-[10px] items-center p-[10px] desk:p-5 rounded-2xl">
<Picture>
<Source
media="(max-width: 1023px)"
Expand All @@ -23,26 +23,26 @@ export function Card(props: CardProps) {
<img
src={image.mobile}
alt={image.alt}
className="rounded-md"
class="rounded-md"
/>
</Picture>
<div>
{props.badge && (
<span className="text-xs leading-[18px] font-bold">
<span class="text-xs leading-[18px] font-bold">
{props.badge}
</span>
)}
<h3 className="font-beccaPerry text-xl leading-6 font-medium">
<h3 class="font-beccaPerry text-xl leading-6 font-medium">
{props.title}
</h3>
<p className="text-xs leading-[18px] max-w-[158px] desk:max-w-[187px] mt-[10px] mb-[14px]">
<p class="text-xs leading-[18px] max-w-[158px] desk:max-w-[187px] mt-[10px] mb-[14px]">
{props.description}
</p>
<ButtonAnchor
styleType={ButtonType.Secondary}
href={props.button.href}
disableHover
className="text-xs leading-[18px] mobile:px-3 min-h-[35px] h-[35px]"
class="text-xs leading-[18px] mobile:px-3 min-h-[35px] h-[35px]"
>
{props.button.text}
</ButtonAnchor>
Expand Down
10 changes: 5 additions & 5 deletions components/footer/CopyrightRow.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -12,12 +12,12 @@ export default function CopyrightRow(props: Props) {
new Date().getFullYear().toString(),
);
return (
<div className="bg-[#F6F6F6] desk:bg-[#F5F4F1] ">
<div className="container flex justify-between desktop:gap-7 items-center mobile:flex-col-reverse py-[14px] desk:py-4">
<p className="text-[#676767] text-[12px] leading-[18px] mobile:text-center">
<div class="bg-[#F6F6F6] desk:bg-[#F5F4F1] ">
<div class="container flex justify-between desktop:gap-7 items-center mobile:flex-col-reverse py-[14px] desk:py-4">
<p class="text-[#676767] text-[12px] leading-[18px] mobile:text-center">
{copyText}
</p>
<div className="flex gap-3 desk:hidden pt-[46px] pb-4">
<div class="flex gap-3 desk:hidden pt-[46px] pb-4">
<a
href={props.tecnologiesLogo.econverse.url}
target="_blank"
Expand All @@ -38,7 +38,7 @@ export default function CopyrightRow(props: Props) {
/>
</a>
</div>
<ul className="flex gap-1">
<ul class="flex gap-1">
{props.cardFlags.map((flag) => (
<li key={flag.title}>
<Image
Expand Down
20 changes: 10 additions & 10 deletions components/footer/MenusAndCardDesktop.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -19,10 +19,10 @@ function Menu(props: MenuProps) {
: props.title;

return (
<ul className="flex flex-col text-[13px] leading-[19.5px] gap-3">
<li className="text-primary font-bold mb-2">{titleContent}</li>
<ul class="flex flex-col text-[13px] leading-[19.5px] gap-3">
<li class="text-primary font-bold mb-2">{titleContent}</li>
{props.itens.map((item) => (
<li className="text-base-content hover:text-primary">
<li class="text-base-content hover:text-primary">
<a href={item.href} target={item.openInNewTab ? "_blank" : "_self"}>
{item.title}
</a>
Expand All @@ -35,13 +35,13 @@ function Menu(props: MenuProps) {
function Column(props: ColumnProps) {
return (
<div>
<nav className="flex flex-col gap-[50px]">
<nav class="flex flex-col gap-[50px]">
{props.menus.map((menu) => <Menu {...menu} />)}
</nav>
{props.socialLogos?.length != null && (
<nav className="flex gap-[10px] mt-8">
<nav class="flex gap-[10px] mt-8">
{props.socialLogos.map((socialLogo) => (
<a href={socialLogo.url} target="_blank" className="block w-5 h-5">
<a href={socialLogo.url} target="_blank" class="block w-5 h-5">
<Image
src={socialLogo.logo}
width={20}
Expand All @@ -58,14 +58,14 @@ function Column(props: ColumnProps) {

export default function MenusAndCardDesktop(props: Props) {
return (
<div className="relative">
<div className="flex items-center justify-between container gap-4 pt-[30px] pb-7 px-10">
<div className="flex max-w-[871px] w-full justify-between gap-4">
<div class="relative">
<div class="flex items-center justify-between container gap-4 pt-[30px] pb-7 px-10">
<div class="flex max-w-[871px] w-full justify-between gap-4">
{props.columns.map((column) => <Column {...column} />)}
</div>
<Card {...props.card} />
</div>
<div className="flex gap-3 absolute left-[max(40px,_calc(((100vw_-_95rem)_/_2)_+_40px))] bottom-4">
<div class="flex gap-3 absolute left-[max(40px,_calc(((100vw_-_95rem)_/_2)_+_40px))] bottom-4">
<a href={props.tecnologiesLogo.econverse.url} target="_blank">
<Image
src={props.tecnologiesLogo.econverse.image}
Expand Down
26 changes: 13 additions & 13 deletions components/footer/MenusAndCardMobile.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -54,35 +54,35 @@ function Menu(props: ExtendedMenuProps) {
const titleContent = props.href
? (
<a
className="text-[13px] leading-[19.5px] font-bold text-primary"
class="text-[13px] leading-[19.5px] font-bold text-primary"
href={props.href}
target="_blank"
>
{props.title}
</a>
)
: (
<span className="text-[13px] leading-[19.5px] font-bold text-primary">
<span class="text-[13px] leading-[19.5px] font-bold text-primary">
{props.title}
</span>
);

return (
<nav className="mb-4 border-b border-dashed border-secondary" id={props.id}>
<button className="flex justify-between mb-4 w-full">
<nav class="mb-4 border-b border-dashed border-secondary" id={props.id}>
<button class="flex justify-between mb-4 w-full">
{titleContent}
<div className="text-[#D6DE23] ">
<Icon className="block" id="plus" size={20} />
<Icon className="hidden" id="minus" size={20} />
<div class="text-[#D6DE23] ">
<Icon class="block" id="plus" size={20} />
<Icon class="hidden" id="minus" size={20} />
</div>
</button>

<ul
className="flex flex-col text-[12px] leading-[18px] gap-4 transition-[height] duration-200 ease-linear overflow-hidden"
class="flex flex-col text-[12px] leading-[18px] gap-4 transition-[height] duration-200 ease-linear overflow-hidden"
style={{ height: 0 }}
>
{props.itens.map((item) => (
<li className="text-[#676767] hover:text-primary first:mt-1 last:mb-4">
<li class="text-[#676767] hover:text-primary first:mt-1 last:mb-4">
<a href={item.href} target={item.openInNewTab ? "_blank" : "_self"}>
{item.title}
</a>
Expand All @@ -104,12 +104,12 @@ export default function MenusAndCardMobile(props: Props) {
.flat();

return (
<div className="container pt-5 pb-[9px]">
<div class="container pt-5 pb-[9px]">
<Card {...props.card} />
{allSocialLogos.length != null && (
<nav className="flex gap-[10px] mt-[22px] justify-center">
<nav class="flex gap-[10px] mt-[22px] justify-center">
{allSocialLogos.map((socialLogo) => (
<a href={socialLogo.url} target="_blank" className="block w-5 h-5">
<a href={socialLogo.url} target="_blank" class="block w-5 h-5">
<Image
src={socialLogo.logo}
width={20}
Expand All @@ -121,7 +121,7 @@ export default function MenusAndCardMobile(props: Props) {
</nav>
)}

<div className="mt-[30px]">
<div class="mt-[30px]">
{allMenus.map((menu) => <Menu {...menu} />)}
<script
type="module"
Expand Down
Loading

0 comments on commit 700afaa

Please sign in to comment.