Skip to content

Commit c3f659a

Browse files
refactor(UI): Usage of @preact-icons/tb for icons due to $tabler_icons deprecation (#938)
Fixes #931 --------- Co-authored-by: Augustin Mauroy <[email protected]>
1 parent 0d41a41 commit c3f659a

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.

43 files changed

+160
-466
lines changed

frontend/components/GitHubRepoInput.tsx

+2-2
Original file line numberDiff line numberDiff line change
@@ -1,7 +1,7 @@
11
// Copyright 2024 the JSR authors. All rights reserved. MIT license.
22
import { Signal } from "@preact/signals";
33
import { useRef } from "preact/hooks";
4-
import { GitHub } from "./icons/GitHub.tsx";
4+
import TbBrandGithub from "@preact-icons/tb/TbBrandGithub";
55

66
export interface GithubRepoInputProps {
77
id: string;
@@ -48,7 +48,7 @@ export function GitHubRepoInput(
4848
return (
4949
<div class="flex items-center w-full md:w-88 rounded-md text-jsr-gray-900 shadow-sm pl-3 py-[2px] pr-[2px] sm:text-sm sm:leading-6 bg-white input-container">
5050
<span class="block">
51-
<GitHub class="!size-5" />
51+
<TbBrandGithub class="!size-5" />
5252
</span>
5353
<input
5454
id={id}

frontend/components/Header.tsx

+2-2
Original file line numberDiff line numberDiff line change
@@ -3,7 +3,7 @@
33
import { FullUser } from "../utils/api_types.ts";
44
import { GlobalSearch } from "../islands/GlobalSearch.tsx";
55
import { UserMenu } from "../islands/UserMenu.tsx";
6-
import { GitHub } from "./icons/GitHub.tsx";
6+
import TbBrandGithub from "@preact-icons/tb/TbBrandGithub";
77
import { SearchKind } from "../util.ts";
88
import { HeaderLogo } from "../islands/HeaderLogo.tsx";
99

@@ -107,7 +107,7 @@ export function Header({
107107
? <UserMenu user={user} sudo={sudo} logoutUrl={logoutUrl} />
108108
: (
109109
<a href={loginUrl} class="link-header flex items-center gap-2">
110-
<GitHub class="size-5 flex-none" aria-hidden={true} />
110+
<TbBrandGithub class="size-5 flex-none" aria-hidden={true} />
111111
Sign in
112112
</a>
113113
)}

frontend/components/HomepageHero.tsx

+2-2
Original file line numberDiff line numberDiff line change
@@ -3,7 +3,7 @@ import { asset } from "fresh/runtime";
33
import { GlobalSearch } from "../islands/GlobalSearch.tsx";
44
import { HomepageHeroParticles } from "../islands/HomepageHeroParticles.tsx";
55
import { AnimatedLogo } from "./AnimatedLogo.tsx";
6-
import { Plus } from "./icons/Plus.tsx";
6+
import TbPlus from "@preact-icons/tb/TbPlus";
77

88
const canvasStyle = /*css*/ `.particles-js-canvas-el {
99
position: absolute;
@@ -79,7 +79,7 @@ export function HomepageHero(
7979
class="button-primary relative z-10 pointer-events-auto"
8080
href="/new"
8181
>
82-
<Plus /> Publish a package
82+
<TbPlus class="size-5" /> Publish a package
8383
</a>
8484
</div>
8585
</div>

frontend/components/List.tsx

+2-2
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
11
// Copyright 2024 the JSR authors. All rights reserved. MIT license.
22
import { PaginationData } from "../util.ts";
3-
import { ChevronRight } from "./icons/ChevronRight.tsx";
3+
import TbChevronRight from "@preact-icons/tb/TbChevronRight";
44
import { ComponentChildren } from "preact";
55

66
export interface ListDisplayItem {
@@ -38,7 +38,7 @@ export function ListDisplay(
3838
>
3939
{item.content}
4040

41-
<ChevronRight class="text-jsr-cyan-800 flex-shrink-0" />
41+
<TbChevronRight class="text-jsr-cyan-800 flex-shrink-0 size-6" />
4242
</a>
4343
</li>
4444
))}

frontend/components/Table.tsx

+3-4
Original file line numberDiff line numberDiff line change
@@ -1,8 +1,7 @@
11
// Copyright 2024 the JSR authors. All rights reserved. MIT license.
22

33
import { ComponentChild, ComponentChildren } from "preact";
4-
import { ChevronLeft } from "./icons/ChevronLeft.tsx";
5-
import { ChevronRight } from "./icons/ChevronRight.tsx";
4+
import { TbChevronLeft, TbChevronRight } from "@preact-icons/tb";
65
import { PaginationData } from "../util.ts";
76

87
interface TableProps {
@@ -85,7 +84,7 @@ function Pagination(
8584
class="hover:text-black hover:bg-jsr-cyan-100 p-1 -m-1 rounded-full"
8685
title="Previous page"
8786
>
88-
<ChevronLeft />
87+
<TbChevronLeft class="size-5" />
8988
</a>
9089
)}
9190
<div class="text-sm text-jsr-gray-600">
@@ -103,7 +102,7 @@ function Pagination(
103102
class="hover:text-black hover:bg-jsr-gray-100 p-1 -m-1 rounded-full"
104103
title="Next page"
105104
>
106-
<ChevronRight />
105+
<TbChevronRight class="size-5" />
107106
</a>
108107
)}
109108
</div>

frontend/components/icons/Check.tsx

-18
This file was deleted.

frontend/components/icons/CheckmarkStamp.tsx

-21
This file was deleted.

frontend/components/icons/ChevronDown.tsx

-19
This file was deleted.

frontend/components/icons/ChevronLeft.tsx

-19
This file was deleted.

frontend/components/icons/ChevronRight.tsx

-20
This file was deleted.

frontend/components/icons/ChevronUp.tsx

-19
This file was deleted.

frontend/components/icons/Copy.tsx

-16
This file was deleted.

frontend/components/icons/Cross.tsx

-19
This file was deleted.

frontend/components/icons/Error.tsx

-20
This file was deleted.

frontend/components/icons/ExternalLink.tsx

-19
This file was deleted.

frontend/components/icons/Folder.tsx

-23
This file was deleted.

frontend/components/icons/GitHub.tsx

-17
This file was deleted.

frontend/components/icons/Minus.tsx

-18
This file was deleted.

frontend/components/icons/Pending.tsx

-19
This file was deleted.

0 commit comments

Comments
 (0)