mirror of
https://github.com/open-metadata/OpenMetadata.git
synced 2025-12-29 08:29:09 +00:00
fix(ui): restore defaults and add term boosts for search ranking settings (#20442)
* fix: restore defaults and add term boosts * fixed glossary term reject button hover effect
This commit is contained in:
parent
a9961302df
commit
17e0b126e4
@ -436,13 +436,18 @@ const EntitySearchSettings = () => {
|
||||
|
||||
const updatedSearchConfig = data as SearchSettings;
|
||||
|
||||
const updatedAssetSearchSettings =
|
||||
updatedSearchConfig.assetTypeConfigurations?.find(
|
||||
(config) => config.assetType === entityType
|
||||
);
|
||||
|
||||
setAppPreferences({
|
||||
...appPreferences,
|
||||
searchConfig: updatedSearchConfig,
|
||||
});
|
||||
|
||||
setSearchSettings({
|
||||
...updatedSearchConfig,
|
||||
...updatedAssetSearchSettings,
|
||||
isUpdated: false,
|
||||
});
|
||||
|
||||
|
||||
@ -45,7 +45,7 @@
|
||||
background-color: @blue-17;
|
||||
color: @white;
|
||||
border: 1px solid @blue-18;
|
||||
width: 100px;
|
||||
width: 90px;
|
||||
padding: 4px 12px;
|
||||
|
||||
&.icon-only {
|
||||
@ -84,7 +84,7 @@
|
||||
}
|
||||
|
||||
&.show-text {
|
||||
width: 80px;
|
||||
width: 90px;
|
||||
padding: 4px 12px;
|
||||
|
||||
.btn-text {
|
||||
|
||||
@ -168,7 +168,8 @@ const SearchSettingsPage = () => {
|
||||
};
|
||||
|
||||
// Term Boost
|
||||
const handleAddNewTermBoost = () => {
|
||||
const handleAddNewTermBoost = (e: React.MouseEvent<HTMLButtonElement>) => {
|
||||
e.stopPropagation();
|
||||
setShowNewTermBoost(true);
|
||||
};
|
||||
|
||||
@ -236,7 +237,8 @@ const SearchSettingsPage = () => {
|
||||
|
||||
// Field Value Boost
|
||||
|
||||
const handleAddFieldValueBoost = () => {
|
||||
const handleAddFieldValueBoost = (e: React.MouseEvent<HTMLButtonElement>) => {
|
||||
e.stopPropagation();
|
||||
setSelectedFieldValueBoost(undefined);
|
||||
setShowFieldValueBoostModal(true);
|
||||
};
|
||||
@ -383,6 +385,7 @@ const SearchSettingsPage = () => {
|
||||
<Button
|
||||
className="term-boost-add-btn"
|
||||
data-testid="term-boost-add-btn"
|
||||
disabled={isUpdating || showNewTermBoost}
|
||||
icon={
|
||||
<Icon className="text-sm" component={PlusOutlined} />
|
||||
}
|
||||
@ -421,6 +424,7 @@ const SearchSettingsPage = () => {
|
||||
<Button
|
||||
className="field-value-boost-add-btn"
|
||||
data-testid="add-field-value-boost-btn"
|
||||
disabled={isUpdating || showFieldValueBoostModal}
|
||||
icon={
|
||||
<Icon className="text-sm" component={PlusOutlined} />
|
||||
}
|
||||
|
||||
@ -79,6 +79,9 @@
|
||||
}
|
||||
}
|
||||
}
|
||||
.ant-collapse-borderless > .ant-collapse-item > .ant-collapse-content {
|
||||
background-color: @grey-10;
|
||||
}
|
||||
}
|
||||
|
||||
.field-value-boost-add-btn,
|
||||
|
||||
Loading…
x
Reference in New Issue
Block a user