Skip to content

Commit

Permalink
Merge pull request #42032 from nextcloud/backport/unified-search-head…
Browse files Browse the repository at this point in the history
…ings

[stable28] fix(UnifiedSearch): Move headings out of list element (invalid HTML)
  • Loading branch information
susnux committed Dec 5, 2023
2 parents 52aadb5 + fd580e5 commit 4ece2f2
Show file tree
Hide file tree
Showing 4 changed files with 14 additions and 13 deletions.
16 changes: 7 additions & 9 deletions core/src/views/UnifiedSearch.vue
Expand Up @@ -36,10 +36,10 @@
<!-- Search form & filters wrapper -->
<div class="unified-search__input-wrapper">
<div class="unified-search__input-row">
<NcTextField :value.sync="query"
<NcTextField ref="input"
:value.sync="query"
trailing-button-icon="close"
:label="ariaLabel"
ref="input"
:trailing-button-label="t('core','Reset search')"
:show-trailing-button="query !== ''"
aria-describedby="unified-search-desc"
Expand Down Expand Up @@ -90,16 +90,14 @@
</template>

<!-- Grouped search results -->
<template v-else>
<ul v-for="({list, type}, typesIndex) in orderedResults"
:key="type"
<template v-for="({list, type}, typesIndex) in orderedResults" v-else>
<h2 :key="type" class="unified-search__results-header">
{{ typesMap[type] }}
</h2>
<ul :key="type"
class="unified-search__results"
:class="`unified-search__results-${type}`"
:aria-label="typesMap[type]">
<h2 class="unified-search__results-header">
{{ typesMap[type] }}
</h2>

<!-- Search results -->
<li v-for="(result, index) in limitIfAny(list, type)" :key="result.resourceUrl">
<SearchResult v-bind="result"
Expand Down
4 changes: 2 additions & 2 deletions dist/core-unified-search.js

Large diffs are not rendered by default.

2 changes: 1 addition & 1 deletion dist/core-unified-search.js.map

Large diffs are not rendered by default.

5 changes: 4 additions & 1 deletion tsconfig.json
@@ -1,6 +1,6 @@
{
"extends": "@vue/tsconfig/tsconfig.json",
"include": ["./apps/**/*.ts", "./apps/**/*.vue", "./core/**/*.ts", "./*.d.ts"],
"include": ["./apps/**/*.ts", "./apps/**/*.vue", "./core/**/*.ts", "./core/**/*.vue", "./*.d.ts"],
"compilerOptions": {
"types": ["jest", "node", "vue", "vue-router"],
"outDir": "./dist/",
Expand All @@ -18,6 +18,9 @@
"resolveJsonModule": true,
"strict": true,
},
"vueCompilerOptions": {
"target": 2.7
},
"ts-node": {
// these options are overrides used only by ts-node
// same as our --compilerOptions flag and our TS_NODE_COMPILER_OPTIONS environment variable
Expand Down

0 comments on commit 4ece2f2

Please sign in to comment.