Skip to content

Commit

Permalink
feat(docs): design updates
Browse files Browse the repository at this point in the history
  • Loading branch information
alicanerdurmaz committed Jan 16, 2025
1 parent e22f8c7 commit 71ea76e
Show file tree
Hide file tree
Showing 3 changed files with 52 additions and 43 deletions.
4 changes: 2 additions & 2 deletions documentation/src/refine-theme/common-header.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -3,7 +3,6 @@ import clsx from "clsx";
import { motion, useScroll, useTransform } from "framer-motion";
import React, { useState } from "react";

import { RefineLogoXmas } from "./icons/refine-logo xmas";
import { HamburgerIcon } from "./icons/hamburger";

import { openFigma } from "../utils/open-figma";
Expand All @@ -14,6 +13,7 @@ import { TopAnnouncement } from "./top-announcement";

import { LandingGithubStarButton } from "./landing-github-star-button";
import SearchBar from "../theme/SearchBar";
import { RefineLogoIcon } from "./icons/refine-logo";

type Props = {
hasSticky?: boolean;
Expand Down Expand Up @@ -82,7 +82,7 @@ export const CommonHeader = ({
>
<div className={clsx("w-[130px]", "landing-lg:w-[200px]")}>
<Link to="/" onContextMenu={openFigma}>
<RefineLogoXmas className="text-gray-900 dark:text-gray-0" />
<RefineLogoIcon className="text-gray-900 dark:text-gray-0" />
</Link>
</div>
<button
Expand Down
2 changes: 1 addition & 1 deletion documentation/src/refine-theme/landing-footer.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -334,7 +334,7 @@ export const LandingFooter = ({ variant = "landing" }: Props) => {
"font-normal",
)}
>
{2024, Refine from San Francisco to wherever you're with "}
{2025, Refine from San Francisco to wherever you're with "}
<HeartOutlinedIcon
className={clsx("ml-1", "text-refine-red", "inline", "leading-5")}
/>
Expand Down
89 changes: 49 additions & 40 deletions documentation/src/refine-theme/top-announcement.tsx
Original file line number Diff line number Diff line change
@@ -1,49 +1,58 @@
import clsx from "clsx";
import React, { type SVGProps } from "react";
import React from "react";
import { useLocation } from "@docusaurus/router";

export const TopAnnouncement = () => {
return (
<a
href="https://refine.dev/ai"
target="_blank"
rel="noopener noreferrer"
className={clsx(
"w-full",
"h-[48px]",
"relative",
"appearance-none",
"border-none",
"outline-none",
"cursor-pointer",
"flex items-center justify-center",
)}
>
<video
id="refine-ai-banner"
autoPlay
loop
muted
className="w-full h-[48px] object-cover"
poster="/assets/refine-ai-banner-bg.png"
>
<source
src="https://refine.ams3.cdn.digitaloceanspaces.com/website/static/refine-ai-banner.mp4"
type="video/mp4"
/>
</video>
const location = useLocation();

if (location.pathname === "/ai") {
return null;
}

<img
src="/assets/refine-ai-banner-text.png"
alt="Refine AI"
return (
<div className="not-prose">
<a
href="https://refine.dev/ai"
target="_blank"
rel="noopener noreferrer"
className={clsx(
"absolute",
"w-full",
"h-[48px]",
"left-1/2",
"-translate-x-1/2",
"top-1/2",
"-translate-y-1/2",
"relative",
"appearance-none",
"border-none",
"outline-none",
"cursor-pointer",
"flex items-center justify-center",
)}
/>
</a>
>
<video
id="refine-ai-banner"
autoPlay
loop
muted
className="w-full h-[48px] object-cover"
poster="/assets/refine-ai-banner-bg.png"
>
<source
src="https://refine.ams3.cdn.digitaloceanspaces.com/website/static/refine-ai-banner.mp4"
type="video/mp4"
/>
</video>

<img
src="/assets/refine-ai-banner-text.png"
alt="Refine AI"
className={clsx(
"absolute",
"h-[48px]",
"left-1/2",
"-translate-x-1/2",
"top-1/2",
"-translate-y-1/2",
)}
/>
</a>
</div>
);
};

0 comments on commit 71ea76e

Please sign in to comment.