Skip to content

Commit

Permalink
Add branding logo
Browse files Browse the repository at this point in the history
  • Loading branch information
pijng committed Mar 25, 2024
1 parent 5177fe1 commit a83f5be
Show file tree
Hide file tree
Showing 10 changed files with 773 additions and 15 deletions.
2 changes: 1 addition & 1 deletion internal/api/swagger.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -9,7 +9,7 @@ info:
license:
name: Apache 2.0
url: http://www.apache.org/licenses/LICENSE-2.0.html
version: 1.7.3
version: 1.7.4
externalDocs:
description: Find out more about spec
url: ''
Expand Down
180 changes: 180 additions & 0 deletions web/src/shared/assets/images/logo.svg
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
1 change: 0 additions & 1 deletion web/src/shared/lib/i18n/translations/en.ts
Original file line number Diff line number Diff line change
Expand Up @@ -207,7 +207,6 @@ export const en: Translation = {
},
miscellaneous: {
loading: "Loading...",
logo: "🌘",
brand: "Moonlogs",
blank_option: "—",
not_found: "The requested resource could not be found",
Expand Down
1 change: 0 additions & 1 deletion web/src/shared/lib/i18n/translations/ru.ts
Original file line number Diff line number Diff line change
Expand Up @@ -207,7 +207,6 @@ export const ru: Translation = {
},
miscellaneous: {
loading: "Загрузка...",
logo: "🌘",
brand: "Moonlogs",
blank_option: "—",
not_found: "Запрашиваемый ресурс не найден",
Expand Down
1 change: 0 additions & 1 deletion web/src/shared/types/index.ts
Original file line number Diff line number Diff line change
Expand Up @@ -222,7 +222,6 @@ export type Translation = {
};
miscellaneous: {
loading: string;
logo: "🌘";
brand: "Moonlogs";
blank_option: "—";
not_found: string;
Expand Down
1 change: 1 addition & 0 deletions web/src/shared/ui/icons/index.ts
Original file line number Diff line number Diff line change
Expand Up @@ -9,3 +9,4 @@ export { TrashIcon } from "./trash";
export { QuestionIcon } from "./question";
export { ClockIcon } from "./clock";
export { FireIcon } from "./fire";
export { LogoIcon } from "./logo";
569 changes: 569 additions & 0 deletions web/src/shared/ui/icons/logo.ts

Large diffs are not rendered by default.

13 changes: 12 additions & 1 deletion web/src/shared/ui/index.ts
Original file line number Diff line number Diff line change
Expand Up @@ -5,7 +5,18 @@ export { Dropdown } from "./dropdown";
export { FloatingInput } from "./floating-input";
export { Header } from "./header";
export { Subheader } from "./subheader";
export { DownIcon, FilterIcon, ClockIcon, PreviousIcon, NextIcon, CrossIcon, PlusIcon, GearIcon, TrashIcon } from "./icons";
export {
DownIcon,
FilterIcon,
ClockIcon,
PreviousIcon,
NextIcon,
CrossIcon,
PlusIcon,
GearIcon,
TrashIcon,
LogoIcon,
} from "./icons";
export { Input } from "./input";
export { Layout, layoutClicked } from "./layout";
export { Link } from "./link";
Expand Down
7 changes: 2 additions & 5 deletions web/src/shared/ui/logo/index.ts
Original file line number Diff line number Diff line change
@@ -1,17 +1,14 @@
import { i18n } from "@/shared/lib/i18n";
import { h } from "forest";
import { LogoIcon } from "@/shared/ui";

type Size = "xl" | "2xl" | "3xl";

export const Logo = (size?: Size) => {
const localSize = size ?? "xl";

h("div", () => {
h("span", {
classList: ["mr-3", "leading-7", `text-${localSize}`],
attr: { alt: "Moonlogs logo" },
text: i18n("miscellaneous.logo"),
});
LogoIcon();

h("span", {
classList: ["self-center", `text-${localSize}`, "font-semibold", "whitespace-nowrap", "dark:text-white"],
Expand Down
13 changes: 8 additions & 5 deletions web/src/shared/ui/sidebar/index.ts
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
import { RouteInstance, redirect } from "atomic-router";
import { Store, createEvent, createStore, sample } from "effector";
import { DOMElement, h, node, spec } from "forest";
import { PermissionGate } from "@/shared/ui";
import { LogoIcon, PermissionGate } from "@/shared/ui";
import { i18n } from "@/shared/lib/i18n";
import { Link, apiTokensRoute, homeRoute, membersRoute, profileRoute, tagsRoute } from "@/shared/routing";

Expand Down Expand Up @@ -126,10 +126,13 @@ export const Sidebar = () => {
},
});

h("span", {
classList: ["mr-3", "leading-7", "text-2xl"],
attr: { alt: "Moonlogs logo" },
text: i18n("miscellaneous.logo"),
h("div", () => {
spec({
classList: ["mr-2", "leading-7", "text-2xl", "w-8"],
attr: { alt: "Moonlogs logo" },
});

LogoIcon();
});

h("span", {
Expand Down

0 comments on commit a83f5be

Please sign in to comment.