Skip to content

Commit

Permalink
Feature 219 styling site landing page (#221)
Browse files Browse the repository at this point in the history
* feat: add calendar picture and icon

* feat: styling landing page and add 404 page
  • Loading branch information
ron-huberfeld committed Feb 13, 2021
1 parent 856c843 commit 9bf6657
Show file tree
Hide file tree
Showing 11 changed files with 206 additions and 235 deletions.
126 changes: 0 additions & 126 deletions app/locales/base.pot

This file was deleted.

44 changes: 19 additions & 25 deletions app/locales/en/LC_MESSAGES/base.po
Original file line number Diff line number Diff line change
Expand Up @@ -7,7 +7,7 @@ msgid ""
msgstr ""
"Project-Id-Version: PROJECT VERSION\n"
"Report-Msgid-Bugs-To: EMAIL@ADDRESS\n"
"POT-Creation-Date: 2021-02-07 23:37+0000\n"
"POT-Creation-Date: 2021-02-07 21:31+0000\n"
"PO-Revision-Date: 2021-01-26 21:31+0200\n"
"Last-Translator: FULL NAME <EMAIL@ADDRESS>\n"
"Language: en\n"
Expand Down Expand Up @@ -54,30 +54,6 @@ msgstr ""
msgid "No events found..."
msgstr ""

#: app/templates/base.html:19
msgid "Calendar"
msgstr ""

#: app/templates/base.html:26
msgid "Home"
msgstr ""

#: app/templates/base.html:29
msgid "Profile"
msgstr ""

#: app/templates/base.html:32
msgid "Sign in"
msgstr ""

#: app/templates/base.html:35
msgid "Sign up"
msgstr ""

#: app/templates/base.html:40
msgid "Agenda"
msgstr ""

#: app/templates/profile.html:50
msgid "Update name"
msgstr ""
Expand Down Expand Up @@ -137,3 +113,21 @@ msgstr ""
#~ msgid "Your feature"
#~ msgstr ""

#~ msgid "Calendar"
#~ msgstr ""

#~ msgid "Home"
#~ msgstr ""

#~ msgid "Profile"
#~ msgstr ""

#~ msgid "Sign in"
#~ msgstr ""

#~ msgid "Sign up"
#~ msgstr ""

#~ msgid "Agenda"
#~ msgstr ""

44 changes: 19 additions & 25 deletions app/locales/he/LC_MESSAGES/base.po
Original file line number Diff line number Diff line change
Expand Up @@ -7,7 +7,7 @@ msgid ""
msgstr ""
"Project-Id-Version: PROJECT VERSION\n"
"Report-Msgid-Bugs-To: EMAIL@ADDRESS\n"
"POT-Creation-Date: 2021-02-07 23:37+0000\n"
"POT-Creation-Date: 2021-02-07 21:31+0000\n"
"PO-Revision-Date: 2021-01-26 21:31+0200\n"
"Last-Translator: FULL NAME <EMAIL@ADDRESS>\n"
"Language: he\n"
Expand Down Expand Up @@ -54,30 +54,6 @@ msgstr ""
msgid "No events found..."
msgstr ""

#: app/templates/base.html:19
msgid "Calendar"
msgstr ""

#: app/templates/base.html:26
msgid "Home"
msgstr ""

#: app/templates/base.html:29
msgid "Profile"
msgstr "פרופיל"

#: app/templates/base.html:32
msgid "Sign in"
msgstr ""

#: app/templates/base.html:35
msgid "Sign up"
msgstr ""

#: app/templates/base.html:40
msgid "Agenda"
msgstr ""

#: app/templates/profile.html:50
msgid "Update name"
msgstr ""
Expand Down Expand Up @@ -137,3 +113,21 @@ msgstr "בדיקת תרגום בפייתון"
#~ msgid "Your feature"
#~ msgstr ""

#~ msgid "Calendar"
#~ msgstr ""

#~ msgid "Home"
#~ msgstr ""

#~ msgid "Profile"
#~ msgstr "פרופיל"

#~ msgid "Sign in"
#~ msgstr ""

#~ msgid "Sign up"
#~ msgstr ""

#~ msgid "Agenda"
#~ msgstr ""

7 changes: 4 additions & 3 deletions app/main.py
Original file line number Diff line number Diff line change
Expand Up @@ -32,8 +32,8 @@ def create_tables(engine, psql_environment):
set_ui_language()

from app.routers import ( # noqa: E402
agenda, calendar, categories, celebrity, currency, dayview,
email, event, invitation, profile, search, telegram, whatsapp
agenda, calendar, categories, celebrity, currency, dayview, email,
event, four_o_four, invitation, profile, search, telegram, whatsapp
)

json_data_loader.load_to_db(next(get_db()))
Expand All @@ -47,6 +47,7 @@ def create_tables(engine, psql_environment):
dayview.router,
email.router,
event.router,
four_o_four.router,
invitation.router,
profile.router,
salary.router,
Expand All @@ -65,7 +66,7 @@ def create_tables(engine, psql_environment):
@logger.catch()
async def home(request: Request, db: Session = Depends(get_db)):
quote = daily_quotes.quote_per_day(db)
return templates.TemplateResponse("home.html", {
return templates.TemplateResponse("index.html", {
"request": request,
"quote": quote,
})
15 changes: 15 additions & 0 deletions app/routers/four_o_four.py
Original file line number Diff line number Diff line change
@@ -0,0 +1,15 @@
from app.dependencies import templates
from fastapi import APIRouter
from starlette.requests import Request

router = APIRouter(
prefix="/404",
tags=["404"],
responses={404: {"description": "Not found"}},
)


@router.get("/")
async def not_implemented(request: Request):
return templates.TemplateResponse("four_o_four.j2",
{"request": request})
Binary file added app/static/images/calendar.jpg
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
1 change: 1 addition & 0 deletions app/static/images/icons/calendar-outline.svg
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
44 changes: 38 additions & 6 deletions app/static/style.css
Original file line number Diff line number Diff line change
@@ -1,9 +1,3 @@
body {
background: #a1ffce;
background: -webkit-linear-gradient(to right, #faffd1, #a1ffce);
background: linear-gradient(to right, #faffd1, #a1ffce);
}

.profile-image {
width: 7em;
}
Expand All @@ -20,6 +14,44 @@ body {
transform: scale(1.02);
}

.top-line {
height: 0.25rem;
}

.bg-gradient2 {
background: linear-gradient(
135deg,
rgba(0, 97, 215, 1) 0%,
rgba(0, 200, 255, 1) 100%
);
}

h2,
p {
display: flex;
align-items: center;
justify-content: space-around;
}

#inner:hover {
cursor: pointer;
padding: 50px;
background-color: linear-gradient(
135deg,
rgba(0, 97, 215, 1) 0%,
rgba(0, 200, 255, 1) 100%
);
}

#inner {
transition: background 0.2s ease, padding 0.8s linear;
}

.landing-page-button {
border-radius: 9999px;
justify-content: center;
}

.event-posted-time {
font-size: 0.7rem;
}
Expand Down

0 comments on commit 9bf6657

Please sign in to comment.