From 3a00dd9206716eda00a3930be4725bd38d824597 Mon Sep 17 00:00:00 2001 From: Kateryna Berdnikova Date: Tue, 20 Aug 2024 18:05:16 +0300 Subject: [PATCH] add solution --- readme.md | 4 +-- src/index.html | 36 ++++++++++++++++------ src/style.css | 83 +++++++++++++++++++++++++++++++++++++++++++++++++- 3 files changed, 110 insertions(+), 13 deletions(-) diff --git a/readme.md b/readme.md index b635aa290b..2cfae3345d 100644 --- a/readme.md +++ b/readme.md @@ -25,8 +25,8 @@ ___ ❗️ Replace `` with your Github username and copy the links to `Pull Request` description: -- [DEMO LINK](https://.github.io/layout_search-bar-airbnb/) -- [TEST REPORT LINK](https://.github.io/layout_search-bar-airbnb/report/html_report/) +- [DEMO LINK](https://KateBerd.github.io/layout_search-bar-airbnb/) +- [TEST REPORT LINK](https://KateBerd.github.io/layout_search-bar-airbnb/report/html_report/) ❗️ Copy this `Checklist` to the `Pull Request` description after links, and put `- [x]` before each point after you checked it. diff --git a/src/index.html b/src/index.html index abe507e10c..acc881cedd 100644 --- a/src/index.html +++ b/src/index.html @@ -17,16 +17,32 @@ /> - +
+ +
- +
+ +
diff --git a/src/style.css b/src/style.css index a63fa10d43..fa53644739 100644 --- a/src/style.css +++ b/src/style.css @@ -1 +1,82 @@ -/* add styles here */ +@font-face { + font-family: Avenir; + src: url(./fonts/Avenir-Book.ttf); + font-weight: 300; +} + +@font-face { + font-family: Avenir; + src: url(./fonts/Avenir-Heavy.ttf); + font-weight: bold; +} + +.search-bar { + font-family: Avenir, sans-serif; + display: block; + width: 100%; + margin-top: 20px; + + box-sizing: border-box; + box-shadow: 0 1px 8px 0 #3d4e611a; + + border: 1px solid #e1e7ed; + border-radius: 5px; + + color: #3d4e61; +} + +.search-bar::placeholder { + color: #3d4e61; +} + +.search-bar__big { + height: 70px; + font-size: 16px; + + padding-left: 62px; + + background-image: url(/src/images/Search.svg); + background-repeat: no-repeat; + background-size: 19px; + background-position: left 26px center; + background-color: #ffff; +} + +.search-bar__big:hover { + box-shadow: 0 3px 8px 0 #3d4e6133; +} + +.search-bar__big:focus { + border: 1px solid #e1e7ed; + + box-shadow: 0 4px 4px 0 #00000040; + background: + url('./images/Search.svg') no-repeat 26px 25px/19px 19px, + linear-gradient(180deg, transparent, #f6f6f7); + + text-shadow: 0 4px 4px 0 #00000040; + font-weight: bold; +} + +.search-bar__small { + height: 42px; + font-size: 14px; + padding-left: 33px; + box-shadow: 0 1px 8px 0 #3d4e611a; + + background: url(/src/images/Search.svg) no-repeat 13px center/11px 11px; +} + +.search-bar__small:hover { + box-shadow: 0 3px 8px 0 #3d4e6133; + text-shadow: none; +} + +.search-bar__small:focus { + border: 1px solid #e1e7ed; + text-shadow: none; + + background: + url(/src/images/Search.svg) no-repeat 13px center/11px 11px, + linear-gradient(180deg, transparent, #f6f6f7); +}