Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

rename props to clear search on leave #320

Merged
merged 1 commit into from
Oct 11, 2023
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
4 changes: 2 additions & 2 deletions src/BIMDataComponents/BIMDataSelect/BIMDataSelectMulti.vue
Original file line number Diff line number Diff line change
Expand Up @@ -116,7 +116,7 @@ export default {
type: String,
default: "Search",
},
isResetSearch: {
resetOnLeave: {
type: Boolean,
default: false,
},
Expand Down Expand Up @@ -192,7 +192,7 @@ export default {
this.$emit("update:modelValue", options);
},
resetSearch() {
if (this.isResetSearch) {
if (this.clearSearchOnLeave) {
this.searchText = "";
}
},
Expand Down
4 changes: 2 additions & 2 deletions src/BIMDataComponents/BIMDataSelect/BIMDataSelectSingle.vue
Original file line number Diff line number Diff line change
Expand Up @@ -117,7 +117,7 @@ export default {
type: String,
default: "Search",
},
isResetSearch: {
clearSearchOnLeave: {
type: Boolean,
default: false,
},
Expand Down Expand Up @@ -180,7 +180,7 @@ export default {
return this.optionKey && option && option.optionGroup;
},
resetSearch() {
if (this.isResetSearch) {
if (this.clearSearchOnLeave) {
this.searchText = "";
}
},
Expand Down
4 changes: 2 additions & 2 deletions src/web/views/Components/Select/Select.vue
Original file line number Diff line number Diff line change
Expand Up @@ -18,7 +18,7 @@
:optionLabelKey="optionLabelKey"
:nullValue="hasNullValue"
v-model="selection"
:isResetSearch="clearSearch"
:clearSearchOnLeave="clearSearch"
>
<template #empty v-if="isEmpty">
<span class="p-x-6 color-granite">No result</span>
Expand Down Expand Up @@ -104,7 +104,7 @@
{{ isDisabled ? "disabled" : "" }}
{{ isMulti ? ':multi="true"' : "" }}
{{ search ? ':search="true"' : "" }}
{{ clearSearch ? ':isResetSearch="true"' : "" }}
{{ clearSearch ? ':clearSearchOnLeave="true"' : "" }}
width="200px"
label="Selector label"
:options="options"
Expand Down
2 changes: 1 addition & 1 deletion src/web/views/Components/Select/props-data.js
Original file line number Diff line number Diff line change
Expand Up @@ -3,7 +3,7 @@ export default [
["Name", "Type", "Default value", "Description"],
["disabled", "Boolean", "false", "When true the selector will be disabled."],
[
"isResetSearch",
"clearSearchOnLeave",
"Boolean",
"false",
"In multi-selection mode: clear search bar on click away. In single selection: clear search bar on select element or click away.",
Expand Down