Fix code
This commit is contained in:
@@ -66,20 +66,23 @@ const showSearch = ref(false)
|
|||||||
@use "@beeline/design-tokens/scss/tokens/themes";
|
@use "@beeline/design-tokens/scss/tokens/themes";
|
||||||
@use "@beeline/design-tokens/scss/tokens/globals/sizes";
|
@use "@beeline/design-tokens/scss/tokens/globals/sizes";
|
||||||
@use "@beeline/design-tokens/scss/mixin";
|
@use "@beeline/design-tokens/scss/mixin";
|
||||||
|
|
||||||
|
$topSpacing: 40px;
|
||||||
|
|
||||||
.VPHero {
|
.VPHero {
|
||||||
margin-top: calc((var(--vp-nav-height) + var(--vp-layout-top-height, 0px)) * -1);
|
margin-top: calc((var(--vp-nav-height) + var(--vp-layout-top-height, 0px)) * -1);
|
||||||
padding: calc(var(--vp-nav-height) + var(--vp-layout-top-height, 0px) + 48px) 24px 48px;
|
padding: calc(var(--vp-nav-height) + var(--vp-layout-top-height, 0px) + $topSpacing) 24px 48px;
|
||||||
}
|
}
|
||||||
|
|
||||||
@media (min-width: 640px) {
|
@media (min-width: 640px) {
|
||||||
.VPHero {
|
.VPHero {
|
||||||
padding: calc(var(--vp-nav-height) + var(--vp-layout-top-height, 0px) + 80px) 48px 64px;
|
padding: calc(var(--vp-nav-height) + var(--vp-layout-top-height, 0px) + $topSpacing) 48px 64px;
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
@media (min-width: 960px) {
|
@media (min-width: 960px) {
|
||||||
.VPHero {
|
.VPHero {
|
||||||
padding: calc(var(--vp-nav-height) + var(--vp-layout-top-height, 0px) + 80px) 64px 64px;
|
padding: calc(var(--vp-nav-height) + var(--vp-layout-top-height, 0px) + $topSpacing) 64px 64px;
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|||||||
@@ -2,7 +2,6 @@
|
|||||||
import type { ButtonTranslations } from 'vitepress/types/local-search'
|
import type { ButtonTranslations } from 'vitepress/types/local-search'
|
||||||
import { createSearchTranslate } from 'vitepress/dist/client/theme-default/support/translation'
|
import { createSearchTranslate } from 'vitepress/dist/client/theme-default/support/translation'
|
||||||
|
|
||||||
// Button-Translations
|
|
||||||
const defaultTranslations: { button: ButtonTranslations } = {
|
const defaultTranslations: { button: ButtonTranslations } = {
|
||||||
button: {
|
button: {
|
||||||
buttonText: 'Поиск',
|
buttonText: 'Поиск',
|
||||||
@@ -16,22 +15,9 @@ const $t = createSearchTranslate(defaultTranslations)
|
|||||||
<template>
|
<template>
|
||||||
<button type="button" :class="$style.HomeHeroSearchButton" :aria-label="$t('button.buttonAriaLabel')">
|
<button type="button" :class="$style.HomeHeroSearchButton" :aria-label="$t('button.buttonAriaLabel')">
|
||||||
<span :class="$style.HomeHeroSearchButtonContainer">
|
<span :class="$style.HomeHeroSearchButtonContainer">
|
||||||
<!--
|
|
||||||
<svg :class="$style.HomeHeroSearchButtonIcon" width="24" height="24" viewBox="0 0 24 24" aria-label="search icon">
|
|
||||||
<path
|
|
||||||
d="M14.386 14.386l4.0877 4.0877-4.0877-4.0877c-2.9418 2.9419-7.7115 2.9419-10.6533 0-2.9419-2.9418-2.9419-7.7115 0-10.6533 2.9418-2.9419 7.7115-2.9419 10.6533 0 2.9419 2.9418 2.9419 7.7115 0 10.6533z"
|
|
||||||
stroke="currentColor" fill="none" fill-rule="evenodd" stroke-linecap="round" stroke-linejoin="round" />
|
|
||||||
</svg>
|
|
||||||
-->
|
|
||||||
<img :class="$style.HomeHeroSearchButtonIcon" src="/icons/search.svg" alt="Поиск">
|
<img :class="$style.HomeHeroSearchButtonIcon" src="/icons/search.svg" alt="Поиск">
|
||||||
<span :class="$style.HomeHeroSearchButtonPlaceholder">{{ $t('button.buttonText') }}</span>
|
<span :class="$style.HomeHeroSearchButtonPlaceholder">{{ $t('button.buttonText') }}</span>
|
||||||
</span>
|
</span>
|
||||||
<!--
|
|
||||||
<span class="DocSearch-Button-Keys">
|
|
||||||
<kbd class="DocSearch-Button-Key"></kbd>
|
|
||||||
<kbd class="DocSearch-Button-Key">K</kbd>
|
|
||||||
</span>
|
|
||||||
-->
|
|
||||||
</button>
|
</button>
|
||||||
</template>
|
</template>
|
||||||
|
|
||||||
@@ -64,165 +50,4 @@ const $t = createSearchTranslate(defaultTranslations)
|
|||||||
color: themes.$color-text-disabled;
|
color: themes.$color-text-disabled;
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
/*
|
|
||||||
[class*='DocSearch'] {
|
|
||||||
--docsearch-primary-color: var(--vp-c-brand-1);
|
|
||||||
--docsearch-highlight-color: var(--docsearch-primary-color);
|
|
||||||
--docsearch-text-color: var(--vp-c-text-1);
|
|
||||||
--docsearch-muted-color: var(--vp-c-text-2);
|
|
||||||
--docsearch-searchbox-shadow: none;
|
|
||||||
--docsearch-searchbox-background: transparent;
|
|
||||||
--docsearch-searchbox-focus-background: transparent;
|
|
||||||
--docsearch-key-gradient: transparent;
|
|
||||||
--docsearch-key-shadow: none;
|
|
||||||
--docsearch-modal-background: var(--vp-c-bg-soft);
|
|
||||||
--docsearch-footer-background: var(--vp-c-bg);
|
|
||||||
}
|
|
||||||
|
|
||||||
.dark [class*='DocSearch'] {
|
|
||||||
--docsearch-modal-shadow: none;
|
|
||||||
--docsearch-footer-shadow: none;
|
|
||||||
--docsearch-logo-color: var(--vp-c-text-2);
|
|
||||||
--docsearch-hit-background: var(--vp-c-default-soft);
|
|
||||||
--docsearch-hit-color: var(--vp-c-text-2);
|
|
||||||
--docsearch-hit-shadow: none;
|
|
||||||
}
|
|
||||||
*/
|
|
||||||
|
|
||||||
|
|
||||||
.DocSearch-Button {
|
|
||||||
display: flex;
|
|
||||||
justify-content: center;
|
|
||||||
align-items: center;
|
|
||||||
border-radius: 12px;
|
|
||||||
margin: 0;
|
|
||||||
padding: 0;
|
|
||||||
width: 48px;
|
|
||||||
height: 55px;
|
|
||||||
background: transparent;
|
|
||||||
transition: border-color 0.25s;
|
|
||||||
}
|
|
||||||
|
|
||||||
/*
|
|
||||||
.DocSearch-Button:hover {
|
|
||||||
// background: transparent;
|
|
||||||
}
|
|
||||||
|
|
||||||
.DocSearch-Button:focus {
|
|
||||||
outline: 1px dotted;
|
|
||||||
outline: 5px auto -webkit-focus-ring-color;
|
|
||||||
}
|
|
||||||
|
|
||||||
.DocSearch-Button:focus:not(:focus-visible) {
|
|
||||||
outline: none !important;
|
|
||||||
}
|
|
||||||
|
|
||||||
.DocSearch-Button .DocSearch-Button-Container {
|
|
||||||
display: flex;
|
|
||||||
align-items: center;
|
|
||||||
}
|
|
||||||
|
|
||||||
.DocSearch-Button .DocSearch-Search-Icon {
|
|
||||||
position: relative;
|
|
||||||
width: 16px;
|
|
||||||
height: 16px;
|
|
||||||
color: var(--vp-c-text-1);
|
|
||||||
fill: currentColor;
|
|
||||||
transition: color 0.5s;
|
|
||||||
}
|
|
||||||
|
|
||||||
.DocSearch-Button:hover .DocSearch-Search-Icon {
|
|
||||||
color: var(--vp-c-text-1);
|
|
||||||
}
|
|
||||||
|
|
||||||
@media (min-width: 768px) {
|
|
||||||
.DocSearch-Button .DocSearch-Search-Icon {
|
|
||||||
top: 1px;
|
|
||||||
margin-right: 8px;
|
|
||||||
width: 14px;
|
|
||||||
height: 14px;
|
|
||||||
color: var(--vp-c-text-2);
|
|
||||||
}
|
|
||||||
}
|
|
||||||
|
|
||||||
.DocSearch-Button .DocSearch-Button-Placeholder {
|
|
||||||
display: none;
|
|
||||||
margin-top: 2px;
|
|
||||||
padding: 0 16px 0 0;
|
|
||||||
font-size: 13px;
|
|
||||||
font-weight: 500;
|
|
||||||
color: var(--vp-c-text-2);
|
|
||||||
transition: color 0.5s;
|
|
||||||
}
|
|
||||||
|
|
||||||
.DocSearch-Button:hover .DocSearch-Button-Placeholder {
|
|
||||||
color: var(--vp-c-text-1);
|
|
||||||
}
|
|
||||||
|
|
||||||
@media (min-width: 768px) {
|
|
||||||
.DocSearch-Button .DocSearch-Button-Placeholder {
|
|
||||||
display: inline-block;
|
|
||||||
}
|
|
||||||
}
|
|
||||||
|
|
||||||
*/
|
|
||||||
|
|
||||||
/*
|
|
||||||
.DocSearch-Button .DocSearch-Button-Keys {
|
|
||||||
direction: ltr;
|
|
||||||
display: none;
|
|
||||||
min-width: auto;
|
|
||||||
}
|
|
||||||
|
|
||||||
@media (min-width: 768px) {
|
|
||||||
.DocSearch-Button .DocSearch-Button-Keys {
|
|
||||||
display: flex;
|
|
||||||
align-items: center;
|
|
||||||
}
|
|
||||||
}
|
|
||||||
|
|
||||||
.DocSearch-Button .DocSearch-Button-Key {
|
|
||||||
display: block;
|
|
||||||
margin: 2px 0 0 0;
|
|
||||||
border: 1px solid var(--vp-c-divider);
|
|
||||||
border-right: none;
|
|
||||||
border-radius: 4px 0 0 4px;
|
|
||||||
padding-left: 6px;
|
|
||||||
min-width: 0;
|
|
||||||
width: auto;
|
|
||||||
height: 22px;
|
|
||||||
line-height: 22px;
|
|
||||||
font-family: var(--vp-font-family-base);
|
|
||||||
font-size: 12px;
|
|
||||||
font-weight: 500;
|
|
||||||
transition: color 0.5s, border-color 0.5s;
|
|
||||||
}
|
|
||||||
|
|
||||||
.DocSearch-Button .DocSearch-Button-Key+.DocSearch-Button-Key {
|
|
||||||
border-right: 1px solid var(--vp-c-divider);
|
|
||||||
border-left: none;
|
|
||||||
border-radius: 0 4px 4px 0;
|
|
||||||
padding-left: 2px;
|
|
||||||
padding-right: 6px;
|
|
||||||
}
|
|
||||||
|
|
||||||
.DocSearch-Button .DocSearch-Button-Key:first-child {
|
|
||||||
font-size: 0 !important;
|
|
||||||
}
|
|
||||||
|
|
||||||
.DocSearch-Button .DocSearch-Button-Key:first-child:after {
|
|
||||||
content: 'Ctrl';
|
|
||||||
font-size: 12px;
|
|
||||||
letter-spacing: normal;
|
|
||||||
color: var(--docsearch-muted-color);
|
|
||||||
}
|
|
||||||
|
|
||||||
.mac .DocSearch-Button .DocSearch-Button-Key:first-child:after {
|
|
||||||
content: '\2318';
|
|
||||||
}
|
|
||||||
|
|
||||||
.DocSearch-Button .DocSearch-Button-Key:first-child>* {
|
|
||||||
display: none;
|
|
||||||
}
|
|
||||||
*/
|
|
||||||
</style>
|
</style>
|
||||||
|
|||||||
Reference in New Issue
Block a user