fix(core): 🐛 do not make search create and exist link into a card

Sometimes it might only have a whitespace in it, which creates an empty card
This commit is contained in:
alistair3149 2022-12-13 15:01:54 -05:00
parent c4bd384235
commit 80a35ea571
No known key found for this signature in database

View file

@ -16,12 +16,8 @@
display: none;
}
// Sticky header
.mw-search-form-wrapper {
padding-top: var( --space-md );
margin-top: ~'calc( var( --space-md ) * -1 )'; // counteract padding
background-color: transparent;
.citizen-sticky-header;
border-bottom: 1px solid var( --border-color-base );
// Wrapper has a border bottom already
.mw-search-profile-tabs:last-child {
@ -81,7 +77,7 @@
.results-info {
color: var( --color-base--subtle );
font-size: 0.8125rem;
font-size: 0.875rem;
white-space: nowrap;
}
@ -112,10 +108,12 @@
.mw-search-createlink,
.mw-search-exists {
padding: var( --space-sm ) var( --space-md );
border-radius: var( --border-radius--small );
// These can generate a empty card when there are no text content
// FIXME: re-enable when this is addressed in core
// padding: var( --space-sm ) var( --space-md );
// background: var( --color-surface-2 );
// border-radius: var( --border-radius--small );
margin-top: 0 !important;
background: var( --color-surface-2 );
color: var( --color-base--emphasized );
}
@ -151,6 +149,11 @@
.searchmatch {
color: var( --color-base--emphasized );
font-weight: var( --font-weight-semibold );
a & {
// If searchmatch is part of the link (usually title), use link color
color: inherit;
}
}
.searchresults {