Skip to content

Commit

Permalink
fix(styling): add a better search filter magnify glass icon as placeh…
Browse files Browse the repository at this point in the history
…older

- by using directly the unicode character we can make it monochrome instead of having a completely different styling between browsers (chrome was gray while firefox was previously colored, now they both look exactly the same monochrome icon)
  • Loading branch information
ghiscoding committed Apr 30, 2021
1 parent f6cf14c commit 5464824
Show file tree
Hide file tree
Showing 4 changed files with 13 additions and 2 deletions.
2 changes: 1 addition & 1 deletion packages/common/src/global-grid-options.ts
Expand Up @@ -97,7 +97,7 @@ export const GlobalGridOptions: GridOption = {
defaultFilter: Filters.input,
defaultBackendServiceFilterTypingDebounce: 500,
enableFilterTrimWhiteSpace: false, // do we want to trim white spaces on all Filters?
defaultFilterPlaceholder: '🔍',
defaultFilterPlaceholder: '🔎︎',
defaultFilterRangeOperator: OperatorType.rangeInclusive,
defaultColumnSortFieldId: 'id',
defaultComponentEventPrefix: '',
Expand Down
1 change: 1 addition & 0 deletions packages/common/src/styles/_variables.scss
Expand Up @@ -499,6 +499,7 @@ $checkbox-selector-opacity: 0.15 !default;
$checkbox-selector-opacity-hover: 0.35 !default;

/* Editors */
$editor-placeholder-color: #c9c9c9 !default;
$editor-input-border-radius: 3px !default;
$editor-input-disabled-color: #ececec !default;
$editor-input-height: 24px !default;
Expand Down
11 changes: 11 additions & 0 deletions packages/common/src/styles/slick-plugins.scss
Expand Up @@ -573,6 +573,7 @@
.placeholder {
font-family: $multiselect-placeholder-font-family;
font-size: $header-font-size;
color: $editor-placeholder-color !important;
}
}
.ms-filter.search-filter {
Expand Down Expand Up @@ -741,6 +742,9 @@ input.search-filter {
&.compound-input {
border-radius: $compound-filter-border-radius !important;
border-left: none;
&::placeholder {
color: $editor-placeholder-color;
}
}
}
input.compound-slider {
Expand Down Expand Up @@ -769,6 +773,9 @@ input.search-filter {
.search-filter .flatpickr {
input.form-control {
border-left: none;
&::placeholder {
color: $editor-placeholder-color;
}
}
}
.search-filter.flatpickr,
Expand Down Expand Up @@ -1000,6 +1007,10 @@ input.slider-filter-input[type=range] {
.search-filter {
height: $header-input-height;

&::placeholder {
color: $editor-placeholder-color;
}

.slider-value {
padding: 0;
height: 100%;
Expand Down
Expand Up @@ -14,7 +14,6 @@ export const SalesforceGlobalGridOptions = {
resetFormButtonIconCssClass: 'mdi mdi-refresh mdi-16px mdi-flip-h mdi-v-align-text-top'
},
datasetIdPropertyName: 'Id',
defaultFilterPlaceholder: '',
emptyDataWarning: {
message: `<span class="mdi mdi-alert color-warning"></span> No data to display.`,
},
Expand Down

0 comments on commit 5464824

Please sign in to comment.