diff --git a/static/css/mobile_styles.css b/static/css/mobile_styles.css index 02247c7..295b63d 100644 --- a/static/css/mobile_styles.css +++ b/static/css/mobile_styles.css @@ -23,6 +23,14 @@ .header_logo, .header_btn_mover{ margin-right: 20px; } + .dropbtn_lang{ + padding: 2px 0.5px; + border-radius: 12px; + + } + #ru_lang,#en_lang{ + padding: unset; + } #customer_service{ margin-right: 10px; @@ -283,6 +291,7 @@ } .button_profile_header_mobile{ display: inline-block ; + margin-left: 5px; } .header_logo_mobile { margin-right: 37px; diff --git a/static/css/styles.css b/static/css/styles.css index f41fd8b..2383d13 100644 --- a/static/css/styles.css +++ b/static/css/styles.css @@ -646,6 +646,14 @@ header .header-second { aspect-ratio: 4/3; } +.from_address_point_txt.red_text{ + color: #ff0000; +} +.to_address_point_txt.red_text{ + color: #ff0000; + +} + .header-second-item, .cont_header_btn_profile, @@ -680,8 +688,9 @@ span.btn_profile_name { /*Language select*/ .dropbtn_lang { - padding: 7px 0 7px 0; + padding: 8px 6.5px; cursor: pointer; + border-radius: 23px; } /* The container
- needed to position the dropdown content */ @@ -700,9 +709,9 @@ span.btn_profile_name { .dropbtn_lang { - background: url('/static/img/png/ru.png') no-repeat left center; - padding-left: 25px; - width: 40px; + background: url('/static/img/svg/ru.svg') no-repeat left center; + /*padding-left: 25px;*/ + /*width: 40px;*/ color: transparent; } @@ -718,16 +727,19 @@ span.btn_profile_name { #ru_lang { - background: url('/static/img/png/ru.png') no-repeat left center; + background: url('/static/img/svg/ru.svg') no-repeat center; color: transparent; - padding: 10px; + padding: 6px; + margin: 5px 0; + border-radius: 5px; } #en_lang { - background: url('/static/img/png/en.png') no-repeat left center; + background: url('/static/img/svg/gb.svg') no-repeat center; color: transparent; - padding: 10px; + padding: 6px; + border-radius: 5px; } /* Links inside the dropdown */ @@ -754,6 +766,7 @@ span.btn_profile_name { .header-second>div>img{ margin-right: 5px; + margin-left: 10px; } #customer_service{ margin-right: 35px; diff --git a/static/img/svg/gb.svg b/static/img/svg/gb.svg new file mode 100644 index 0000000..ef048dc --- /dev/null +++ b/static/img/svg/gb.svg @@ -0,0 +1,7 @@ + + + + + + + diff --git a/static/img/svg/ru.svg b/static/img/svg/ru.svg new file mode 100644 index 0000000..d643087 --- /dev/null +++ b/static/img/svg/ru.svg @@ -0,0 +1,7 @@ + + + + + + + diff --git a/static/js/global_js.js b/static/js/global_js.js index 5d0f8a5..782217a 100644 --- a/static/js/global_js.js +++ b/static/js/global_js.js @@ -49,14 +49,16 @@ function getInfoAboutUser (){ document.addEventListener('DOMContentLoaded', function() { let img = document.getElementById('dropbtn_lang') if (window.location.href.indexOf("ru") > -1){ - img.style.background = "url('/static/img/png/ru.png')" + img.style.background = "url('/static/img/svg/ru.svg')" img.style.backgroundRepeat = "no-repeat" - img.style.backgroundPosition = "left center" + img.style.backgroundPosition = "center" + // img.style.backgroundSize = '50%' }else if(window.location.href.indexOf("en") > -1){ - img.style.background = "url('/static/img/png/en.png')" + img.style.background = "url('/static/img/svg/gb.svg')" img.style.backgroundRepeat = "no-repeat" - img.style.backgroundPosition = "left center" + img.style.backgroundPosition = "center" + // img.style.backgroundSize = '50%' } }); diff --git a/static/js/user_profile.js b/static/js/user_profile.js index f534219..5f465ca 100644 --- a/static/js/user_profile.js +++ b/static/js/user_profile.js @@ -351,6 +351,10 @@ function selectItemAddrPoint(id, name, ctrl_name,){ tap_txt_cont.setAttribute('title',name) let tap_cont = document.querySelector("#id_" + ctrl_name.slice(0, -4)); tap_cont.value = id; + if (tap_txt_cont.classList.contains('red_text')){ + tap_txt_cont.classList.remove('red_text') + } + if (!window.location.href.includes("profile")){ changeWidthEL(tap_txt_cont) } @@ -413,17 +417,16 @@ function onblurInputField(event,el){ function clearID(el) { - el.select(); - if(el.id === 'id_from_address_point_txt'){ + if(el.value !== "" && el.id === 'id_from_address_point_txt' ){ document.getElementById('id_from_address_point').value = '' - } else if(el.id === 'id_to_address_point_txt'){ + el.classList.add('red_text') + } else if(el.value !== "" && el.id === 'id_to_address_point_txt'){ document.getElementById('id_to_address_point').value = '' + el.classList.add('red_text') } - - } diff --git a/templates/tb_base.html b/templates/tb_base.html index c58cb51..1acdb86 100644 --- a/templates/tb_base.html +++ b/templates/tb_base.html @@ -5,7 +5,8 @@ - +{# #} + {% include "inter/meta_names.html" %} {# #}