VEGA-5235 Исправление отображения контента при поиске
This commit is contained in:
committed by
Речкина Елена Валерьевна
parent
9432e755e6
commit
4270668c7c
+1
-1
@@ -1,6 +1,6 @@
|
|||||||
{
|
{
|
||||||
"name": "docs",
|
"name": "docs",
|
||||||
"version": "0.6.4-vdi",
|
"version": "0.6.4-search3",
|
||||||
"description": "Beeline Cloud docs",
|
"description": "Beeline Cloud docs",
|
||||||
"main": "index.js",
|
"main": "index.js",
|
||||||
"scripts": {
|
"scripts": {
|
||||||
|
|||||||
@@ -80,14 +80,8 @@ export default defineConfig({
|
|||||||
buttonAriaLabel: 'Поиск'
|
buttonAriaLabel: 'Поиск'
|
||||||
},
|
},
|
||||||
modal: {
|
modal: {
|
||||||
noResultsText: 'Не удалось загрузить данные',
|
noResultsText: 'По вашему запросу ничего не найдено',
|
||||||
resetButtonTitle: 'Сбросить',
|
resetButtonTitle: 'Сбросить',
|
||||||
displayDetails: 'Показать расширенный список',
|
|
||||||
footer: {
|
|
||||||
selectText: 'Выбрать',
|
|
||||||
closeText: 'Закрыть',
|
|
||||||
navigateText: 'Перейти',
|
|
||||||
}
|
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|||||||
@@ -33,6 +33,8 @@ import { escapeRegExp } from 'vitepress/dist/client/shared'
|
|||||||
import { useData } from 'vitepress/dist/client/theme-default/composables/data'
|
import { useData } from 'vitepress/dist/client/theme-default/composables/data'
|
||||||
import { LRUCache } from 'vitepress/dist/client/theme-default/support/lru'
|
import { LRUCache } from 'vitepress/dist/client/theme-default/support/lru'
|
||||||
import { createSearchTranslate } from 'vitepress/dist/client/theme-default/support/translation'
|
import { createSearchTranslate } from 'vitepress/dist/client/theme-default/support/translation'
|
||||||
|
import CustomIcon from './CustomIcon.vue';
|
||||||
|
import { Icons } from '@beeline/design-tokens/js/iconfont/icons';
|
||||||
|
|
||||||
const emit = defineEmits<{
|
const emit = defineEmits<{
|
||||||
(e: 'close'): void
|
(e: 'close'): void
|
||||||
@@ -496,21 +498,7 @@ function formMarkRegex(terms: Set<string>) {
|
|||||||
:title="$t('modal.resetButtonTitle')"
|
:title="$t('modal.resetButtonTitle')"
|
||||||
@click="resetSearch"
|
@click="resetSearch"
|
||||||
>
|
>
|
||||||
<svg
|
<CustomIcon :icon="Icons.Close" size="large" style="padding: 12px 0;" />
|
||||||
width="18"
|
|
||||||
height="18"
|
|
||||||
viewBox="0 0 24 24"
|
|
||||||
aria-hidden="true"
|
|
||||||
>
|
|
||||||
<path
|
|
||||||
fill="none"
|
|
||||||
stroke="currentColor"
|
|
||||||
stroke-linecap="round"
|
|
||||||
stroke-linejoin="round"
|
|
||||||
stroke-width="2"
|
|
||||||
d="M20 5H9l-7 7l7 7h11a2 2 0 0 0 2-2V7a2 2 0 0 0-2-2Zm-2 4l-6 6m0-6l6 6"
|
|
||||||
/>
|
|
||||||
</svg>
|
|
||||||
</button>
|
</button>
|
||||||
</div>
|
</div>
|
||||||
</form>
|
</form>
|
||||||
@@ -576,12 +564,6 @@ function formMarkRegex(terms: Set<string>) {
|
|||||||
<p class="no-results-text">
|
<p class="no-results-text">
|
||||||
{{ $t('modal.noResultsText') }}
|
{{ $t('modal.noResultsText') }}
|
||||||
</p>
|
</p>
|
||||||
<button
|
|
||||||
class="no-results-button"
|
|
||||||
@click="retrySearch(searchIndex, filterText)"
|
|
||||||
>
|
|
||||||
Попробовать еще раз
|
|
||||||
</button>
|
|
||||||
</ul>
|
</ul>
|
||||||
</div>
|
</div>
|
||||||
</div>
|
</div>
|
||||||
@@ -610,7 +592,6 @@ function formMarkRegex(terms: Set<string>) {
|
|||||||
background: var(--vp-local-search-bg);
|
background: var(--vp-local-search-bg);
|
||||||
width: min(100vw - 60px, 900px);
|
width: min(100vw - 60px, 900px);
|
||||||
height: min-content;
|
height: min-content;
|
||||||
max-height: min(100vh - 128px, 900px);
|
|
||||||
border-radius: 12px;
|
border-radius: 12px;
|
||||||
}
|
}
|
||||||
|
|
||||||
@@ -679,7 +660,7 @@ function formMarkRegex(terms: Set<string>) {
|
|||||||
}
|
}
|
||||||
|
|
||||||
.search-actions button {
|
.search-actions button {
|
||||||
padding: 8px;
|
padding: 0px;
|
||||||
}
|
}
|
||||||
|
|
||||||
.search-actions button:not([disabled]):hover,
|
.search-actions button:not([disabled]):hover,
|
||||||
@@ -728,11 +709,11 @@ function formMarkRegex(terms: Set<string>) {
|
|||||||
overflow-x: hidden;
|
overflow-x: hidden;
|
||||||
overflow-y: auto;
|
overflow-y: auto;
|
||||||
overscroll-behavior: contain;
|
overscroll-behavior: contain;
|
||||||
box-shadow: var(--vp-c-shadow-3);
|
|
||||||
border-radius: 12px;
|
border-radius: 12px;
|
||||||
border: 1px solid rgba(25, 28, 52, 0.18);
|
border: 1px solid rgba(25, 28, 52, 0.18);
|
||||||
padding: 8px 0;
|
padding: 8px 0;
|
||||||
max-height: min(100vh - 214px, 900px);
|
max-height: min(100vh - 214px, 900px);
|
||||||
|
box-shadow: 0px 6px 38px rgba(0, 0, 0, 0.16), 0px 0px 10px rgba(0, 0, 0, 0.08);
|
||||||
|
|
||||||
li:hover {
|
li:hover {
|
||||||
background-color: rgba(25, 28, 52, 0.08);
|
background-color: rgba(25, 28, 52, 0.08);
|
||||||
@@ -745,7 +726,7 @@ function formMarkRegex(terms: Set<string>) {
|
|||||||
gap: 8px;
|
gap: 8px;
|
||||||
transition: none;
|
transition: none;
|
||||||
outline: none;
|
outline: none;
|
||||||
height: 66px;
|
min-height: 66px;
|
||||||
}
|
}
|
||||||
|
|
||||||
.result > div {
|
.result > div {
|
||||||
@@ -858,17 +839,18 @@ function formMarkRegex(terms: Set<string>) {
|
|||||||
gap: 24px;
|
gap: 24px;
|
||||||
align-items: center;
|
align-items: center;
|
||||||
z-index: 100;
|
z-index: 100;
|
||||||
box-shadow: 0 0 10 0 rgba(0, 0, 0, 0.16);
|
box-shadow: 0px 6px 38px rgba(0, 0, 0, 0.16), 0px 0px 10px rgba(0, 0, 0, 0.08);
|
||||||
border-radius: 12px;
|
border-radius: 12px;
|
||||||
border: 1px solid rgba(25, 28, 52, 0.18);
|
border: 1px solid rgba(25, 28, 52, 0.18);
|
||||||
background-color: rgb(255, 255, 255);
|
background-color: rgb(255, 255, 255);
|
||||||
}
|
}
|
||||||
|
|
||||||
.no-results-text {
|
.no-results-text {
|
||||||
font-weight: 700;
|
font-weight: 400;
|
||||||
font-size: 17px;
|
font-size: 17px;
|
||||||
line-height: 22px;
|
line-height: 22px;
|
||||||
letter-spacing: 0.2px;
|
letter-spacing: 0.2px;
|
||||||
|
color: rgba(25, 28, 52, 0.48);
|
||||||
}
|
}
|
||||||
|
|
||||||
.no-results-button {
|
.no-results-button {
|
||||||
@@ -879,6 +861,7 @@ function formMarkRegex(terms: Set<string>) {
|
|||||||
font-size: 17px;
|
font-size: 17px;
|
||||||
line-height: 22px;
|
line-height: 22px;
|
||||||
letter-spacing: 0.2px;
|
letter-spacing: 0.2px;
|
||||||
|
color: rgba(9, 11, 22, 0.94);
|
||||||
}
|
}
|
||||||
|
|
||||||
svg {
|
svg {
|
||||||
|
|||||||
Reference in New Issue
Block a user