Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Update darklight web theme #226

Merged
merged 6 commits into from
Nov 5, 2023
Merged
Show file tree
Hide file tree
Changes from 4 commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
2 changes: 1 addition & 1 deletion frontend/web/app/dashboard/services/page.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -40,7 +40,7 @@ const ServiceLine = ({
onChange={() => setSelectedServiceId(service.id)}
/>

<div className="collapse-title text-2xl font-medium flex">
<div className="m-2 collapse-title text-2xl font-medium flex bg-neutral rounded-lg w-full">
<div className="avatar">
<div className="mask mask-squircle w-8 h-8">
<Image src={service.imageUrl} alt="Service logo" width={500} height={500} />
Expand Down
2 changes: 1 addition & 1 deletion frontend/web/app/editor/page.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -20,7 +20,7 @@ const EditorPage = () => {
}, []);

return (
<div className="bg-neutral text-neutral-content min-h-screen w-screen justify-center items-center">
<div className="bg-primary text-neutral-content min-h-screen w-screen justify-center items-center">
<div className="pt-7">
<EditorCards />
</div>
Expand Down
2 changes: 1 addition & 1 deletion frontend/web/components/Footer.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -3,7 +3,7 @@ import FontAwesomeIcon from "@/components/FontAwesomeIcon";
import ApkDownloadButton from "@/components/ApkDownloadButton";

const Footer = () => (
<footer className="footer p-10 bg-primary text-primary-content">
<footer className="footer p-10 bg-neutral text-primary-content">
<aside>
<Image src="/logo.png" alt="Area logo" width={50} height={50} />
<p>
Expand Down
2 changes: 1 addition & 1 deletion frontend/web/components/Navbar.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -25,7 +25,7 @@ const Navbar = ({ beforeLogoContent, hasLogo = true, centerContent, endContent }
}, [interfaceLanguage]);

return (
<div className="navbar bg-primary">
<div className="navbar bg-neutral">
<div className="navbar-start">
{beforeLogoContent}
{hasLogo ? (
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -13,7 +13,7 @@ type DashboardMenuElementProps = {

const DashboardMenuLink = ({ icon, title, href, isFull }: DashboardMenuElementProps) => (
<li>
<Link className={isFull ? "" : "justify-center"} href={href}>
<Link className={isFull ? "" : "justify-center text-base-100"} href={href}>
<FontAwesomeIcon icon={icon} svgProps={isFull ? undefined : { className: "h-6 w-6" }} />
{isFull ? title : ""}
</Link>
Expand All @@ -22,7 +22,7 @@ const DashboardMenuLink = ({ icon, title, href, isFull }: DashboardMenuElementPr

const DashboardMenuButton = ({ icon, title, href, isFull, onClick }: DashboardMenuElementProps) => (
<Link className="justify-center" href={href} onClick={onClick}>
<button className={`btn btn-secondary ${isFull ? "btn-wide" : ""}`}>
<button className={`btn btn-secondary text-base-100 ${isFull ? "btn-wide" : ""}`}>
<FontAwesomeIcon icon={icon} /> {isFull ? title : ""}
</button>
</Link>
Expand Down
6 changes: 3 additions & 3 deletions frontend/web/components/editor/EditorNavbar.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -45,7 +45,7 @@ const EditorNavbar = ({ isAuthenticated }: EditorNavbarProps) => {
<FontAwesomeIcon icon="chevron-left" />
</button>
<input
className="input w-full max-w-xs"
className="input w-full max-w-xs bg-primary"
type="text"
value={workflow.name}
onChange={(e) => setWorkflow((prev) => ({ ...prev, name: e.target.value }))}
Expand All @@ -63,11 +63,11 @@ const EditorNavbar = ({ isAuthenticated }: EditorNavbarProps) => {
<input
type="checkbox"
name="workflow-running"
className="toggle toggle-success mr-6"
className="toggle toggle-success mr-6 bg-primary"
checked={workflow.active}
onChange={onToggleWorkflow}
/>
<button className="btn btn-secondary" onClick={onSaveWorkflow}>
<button className="btn btn-secondary text-base-100" onClick={onSaveWorkflow}>
{t("actions.save")}
</button>
</>
Expand Down
2 changes: 1 addition & 1 deletion frontend/web/components/editor/EditorSeparator.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -29,7 +29,7 @@ const EditorSeparator = ({ previousId }: { previousId: string }) => {
</div>

<div className="flex w-full justify-center">
<button className="btn btn-circle btn-sm" onClick={onClick}>
<button className="btn btn-circle btn-sm bg-accent border-accent" onClick={onClick}>
<FontAwesomeIcon icon="plus" svgProps={{ className: "h-6 w-6" }} />
</button>
</div>
Expand Down
2 changes: 1 addition & 1 deletion frontend/web/components/editor/EditorStepCardWrapper.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -13,7 +13,7 @@ const EditorStepCardWrapper = ({ title, children, actions }: EditorStepCardWrapp
const { t } = useTranslation();

return (
<div className="card mx-auto w-2/3 shadow-2xl">
<div className="card mx-auto w-2/3 shadow-2xl bg-neutral">
<div className="card-body items-center pt-3">
<div className="flex w-full mb-5">
<p className="card-title justify-center text-2xl ml-2">
Expand Down
8 changes: 4 additions & 4 deletions frontend/web/components/editor/EditorSummaryCard.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -12,14 +12,14 @@ type EditorSummaryCardProps = {
service?: EditorWorkflowElementService;
};
const EditorSummaryCard = ({ title, description, onClick, icon, service }: EditorSummaryCardProps) => (
<div className="card mx-auto w-96 shadow-2xl cursor-pointer" onClick={onClick}>
<div className="card mx-auto w-96 shadow-2xl cursor-pointer bg-neutral" onClick={onClick}>
<div className="card-body bg-pimary">
<div className="flex bg-pimary">
<div className="card shadow-xl">
<div className="card shadow-xl bg-primary">
{service ? (
<div className="card-body p-3">
<div className="card-body p-3 bg-primary">
<div className="avatar m-auto">
<div className="mask mask-squircle w-16 h-16">
<div className="mask mask-squircle w-16 h-16 bg-primary">
<Image src={service.imageUrl} alt="Service logo" width={300} height={300} />
</div>
</div>
Expand Down
10 changes: 5 additions & 5 deletions frontend/web/components/landing/GeneralHero.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -2,17 +2,17 @@ import Image from "next/image";
import Link from "next/link";

const LandingGeneralHero = () => (
<div className="hero min-h-screen bg-accent">
<div className="hero min-h-screen bg-primary">
<div className="hero-content text-center">
<div className="max-w-lg">
<h1 className="text-5xl font-extrabold">CREATE, AUTOMATE,</h1>
<h1 className="text-7xl font-extrabold leading-relaxed">SUCCEED</h1>
<p className="py-6">
<h1 className="text-5xl font-extrabold text-base-100">CREATE, AUTOMATE,</h1>
<h1 className="text-7xl font-extrabold leading-relaxed text-base-100">SUCCEED</h1>
<p className="py-6 text-base-100">
Unlock boundless innovation and creativity with AREA. Our revolutionary software empowers you to turn ideas
into reality, automate tasks, and achieve excellence effortlessly. Join us on a journey where the
extraordinary becomes routine.
</p>
<Link href="/dashboard" className="btn btn-secondary">
<Link href="/dashboard" className="btn btn-secondary text-base-100">
Get Started
</Link>
<Image src="/landing/main.webp" width="1168" height="657" alt="landing-image" className="w-lg" />
Expand Down
4 changes: 2 additions & 2 deletions frontend/web/components/library/LibraryWorkflowLine.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -107,7 +107,7 @@ const LibraryWorkflowLine = ({ workflow, selected, onSelect, onWorkflowChange }:
<input
type="checkbox"
name="workflow-selector"
className="checkbox border-primary"
className="checkbox border-accent"
checked={selected}
onChange={(e) => onSelect(workflow.id, e.target.checked)}
/>
Expand Down Expand Up @@ -138,7 +138,7 @@ const LibraryWorkflowLine = ({ workflow, selected, onSelect, onWorkflowChange }:
<summary className="btn btn-ghost btn-xs">
<FontAwesomeIcon icon="ellipsis" />
</summary>
<ul className="dropdown-content z-[1] menu p-2 shadow-xl bg-base-content rounded-box w-52">
<ul className="dropdown-content z-[1] menu p-2 shadow-xl bg-neutral rounded-box w-52">
<li>
<a className="hover:text-neutral-content" onClick={onClickRename}>
<FontAwesomeIcon icon="input-text" />
Expand Down
2 changes: 1 addition & 1 deletion frontend/web/layouts/auth/AuthLayout.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -51,7 +51,7 @@ const AuthLayout = () => {
<Image alt="Profile picture" width="100" height="100" src="/user/default-profile-picture.webp" />
</div>
</label>
<ul tabIndex={0} className="mt-3 z-[1] p-2 shadow menu menu-sm dropdown-content bg-base-100 rounded-box w-52">
<ul tabIndex={0} className="mt-3 z-[1] p-2 shadow menu menu-sm dropdown-content bg-base-100 rounded-box w-52 bg-neutral">
<li>
<Link href="/dashboard/user">
<FontAwesomeIcon icon="gear" />
Expand Down
4 changes: 2 additions & 2 deletions frontend/web/layouts/dashboard/DashboardPageWrapper.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -5,8 +5,8 @@ type AppPageWrapperProps = {
children?: ReactNode;
};
const DashboardPageWrapper = ({ title, children }: AppPageWrapperProps) => (
<div className="bg-neutral text-neutral-content w-screen justify-center items-center">
<h1 className="text-3xl font-bold m-5">{title}</h1>
<div className="bg-primary text-neutral-content w-screen justify-center items-center">
<h1 className="text-3xl font-bold m-5 text-center text-base-100">{title}</h1>
{children}
</div>
);
Expand Down
2 changes: 1 addition & 1 deletion frontend/web/layouts/editor/EditorCards.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -12,7 +12,7 @@ const EditorCards = () => {
const [workflow] = useAtom(editorWorkflowAtom);

return (
<div className="bg-neutral">
<div>
<ActionCard />
<EditorSeparator previousId={workflow.action.id} />
{getSortedReactions(workflow.reactions, workflow.action.id).map((reaction) => (
Expand Down
4 changes: 2 additions & 2 deletions frontend/web/layouts/editor/EditorSelectEventAndAccount.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -157,13 +157,13 @@ const EditorSelectEventAndAccount = ({

<div className="card-actions">
<button
className="btn btn-outline btn-neutral text-neutral-content hover:text-neutral-content"
className="btn btn-outline btn-base-100 bg-primary text-neutral-content hover:text-neutral-content"
onClick={() => onEvent("back")}
>
{t("editor.back")}
</button>
<button
className="btn btn-primary btn-wide disabled:bg-accent"
className="btn btn-primary btn-wide disabled:bg-primary"
disabled={!selectedEventId}
onClick={() => onEvent("next", { id: selectedEventId!, parameters: selectedParameters })}
>
Expand Down
2 changes: 1 addition & 1 deletion frontend/web/layouts/editor/EditorSelectServiceCard.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -32,7 +32,7 @@ const EditorSelectServiceCard = ({

<div className="card-actions">
<button
className="btn btn-primary btn-wide disabled:bg-accent"
className="btn btn-primary btn-wide disabled:bg-primary"
disabled={!selectedServiceId}
onClick={() => onNextStep(serviceChoices.find((s) => s.id === selectedServiceId)!)}
>
Expand Down
8 changes: 4 additions & 4 deletions frontend/web/layouts/user/UserSettings.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -32,7 +32,7 @@ const UserSettings = ({ user }: UserSettingsProps) => {
<div className="w-fit ml-4">
<div className="mb-4">
<label className="label">
<span className="text-primary label-text">{t("user.settings.email")}</span>
<span className="text-base-100 label-text">{t("user.settings.email")}</span>
</label>
<input
type="text"
Expand All @@ -44,7 +44,7 @@ const UserSettings = ({ user }: UserSettingsProps) => {

<div className="mb-4">
<label className="label">
<span className="text-primary label-text">{t("user.settings.theme")}</span>
<span className="text-base-100 label-text">{t("user.settings.theme")}</span>
</label>
<select
className="select select-bordered select-primary bg-neutral"
Expand All @@ -63,7 +63,7 @@ const UserSettings = ({ user }: UserSettingsProps) => {

<div className="mb-6">
<label className="label">
<span className="text-primary label-text">{t("user.settings.language")}</span>
<span className="text-base-100 label-text">{t("user.settings.language")}</span>
</label>
<select
className="select select-bordered select-primary bg-neutral"
Expand All @@ -81,7 +81,7 @@ const UserSettings = ({ user }: UserSettingsProps) => {
</div>

<button
className="btn"
className="btn btn-secondary"
onClick={async () => {
const settings = {
...userSettings,
Expand Down
18 changes: 9 additions & 9 deletions frontend/web/tailwind.config.ts
Original file line number Diff line number Diff line change
Expand Up @@ -13,23 +13,23 @@ const config: Config = {
{
light: {
"color-scheme": "light",
primary: "#2E3244",
primary: "#FFFFFF",
secondary: "#F1895C",
accent: "#516079",
neutral: "#C5C6C6",
accent: "#91A0B9",
neutral: "#E5E6E6",

"base-100": "#2E3244",
"base-content": "#FFFFFF",
"base-content": "#2E3244",
},
dark: {
"color-scheme": "dark",
primary: "#516079",
primary: "#2E3244",
secondary: "#F1895C",
accent: "#2E3244",
neutral: "#718099",
accent: "#516079",
neutral: "#3E4254",

"base-100": "#2E3244",
"base-content": "#FFFFFF",
"base-100": "#FFFFFF",
"base-content": "#E5E6E6",
},
},
],
Expand Down