@rh-support/cases 2.1.28 → 2.1.29
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"AdvanceSearch.d.ts","sourceRoot":"","sources":["../../../../../src/components/case-list/case-search/AdvanceSearch.tsx"],"names":[],"mappings":"
|
|
1
|
+
{"version":3,"file":"AdvanceSearch.d.ts","sourceRoot":"","sources":["../../../../../src/components/case-list/case-search/AdvanceSearch.tsx"],"names":[],"mappings":"AAgBA,OAAO,EAAE,mBAAmB,EAAE,MAAM,2BAA2B,CAAC;AAIhE,UAAU,MAAM;IACZ,iBAAiB,CAAC,EAAE,CAAC,MAAM,EAAE,MAAM,KAAK,IAAI,CAAC;IAC7C,kBAAkB,CAAC,EAAE,CAAC,OAAO,EAAE,mBAAmB,KAAK,IAAI,CAAC;IAC5D,aAAa,CAAC,EAAE,MAAM,IAAI,CAAC;IAC3B,cAAc,EAAE,CAAC,IAAI,EAAE,mBAAmB,EAAE,WAAW,EAAE,MAAM,KAAK,IAAI,CAAC;IACzE,0BAA0B,EAAE,CAAC,UAAU,EAAE,OAAO,KAAK,IAAI,CAAC;IAC1D,gBAAgB,CAAC,EAAE,OAAO,CAAC;CAC9B;AAED,wBAAgB,aAAa,CAAC,KAAK,EAAE,MAAM,eA4T1C"}
|
|
@@ -1,4 +1,5 @@
|
|
|
1
|
-
import { Button } from '@patternfly/react-core';
|
|
1
|
+
import { Button, Flex, FlexItem, Icon, TextInputGroup, TextInputGroupMain, TextInputGroupUtilities, } from '@patternfly/react-core';
|
|
2
|
+
import CheckCircleIcon from '@patternfly/react-icons/dist/js/icons/check-circle-icon';
|
|
2
3
|
import InfoIcon from '@patternfly/react-icons/dist/js/icons/info-circle-icon';
|
|
3
4
|
import TimesCircleIcon from '@patternfly/react-icons/dist/js/icons/times-circle-icon';
|
|
4
5
|
import isEmpty from 'lodash/isEmpty';
|
|
@@ -83,8 +84,8 @@ export function AdvanceSearch(props) {
|
|
|
83
84
|
document.removeEventListener('mousedown', handleClickOutside);
|
|
84
85
|
};
|
|
85
86
|
}, [isAutoCompleteListVisible]);
|
|
86
|
-
const onQueryStringChange = (
|
|
87
|
-
const query =
|
|
87
|
+
const onQueryStringChange = (value) => {
|
|
88
|
+
const query = value;
|
|
88
89
|
setInputString(query);
|
|
89
90
|
};
|
|
90
91
|
const autoCompleteSetup = (expectedArray = null, phrase = '') => {
|
|
@@ -212,11 +213,15 @@ export function AdvanceSearch(props) {
|
|
|
212
213
|
const isQueryInValid = inputString && !isParsingSuccessful;
|
|
213
214
|
return (React.createElement(React.Fragment, null,
|
|
214
215
|
React.createElement("div", { className: "pf-v5-c-select pf-m-expanded", ref: dropdownWrapperRef },
|
|
215
|
-
React.createElement(
|
|
216
|
-
React.createElement("
|
|
217
|
-
|
|
218
|
-
|
|
219
|
-
|
|
216
|
+
React.createElement(TextInputGroup, null,
|
|
217
|
+
React.createElement(TextInputGroupMain, { value: inputString, onChange: (event, value) => onQueryStringChange(value), onFocus: onInputFocus, ref: searchInputRef, onKeyDown: onKeyDown, placeholder: t('i18nEnterSolrQuery', 'Enter SOLR query, for example: severity:"1 (Urgent)" and status:"Waiting on Customer"'), className: "pf-v5-u-pr-2xl", type: "text", "aria-invalid": isQueryInValid ? true : false, autoComplete: "off", id: "advance-search-typeahead", "aria-label": t('Enter search query'), "aria-describedby": "advance-query-error-helper" }),
|
|
218
|
+
inputString && (React.createElement(TextInputGroupUtilities, null,
|
|
219
|
+
React.createElement(Button, { onClick: onClear, variant: "plain", "data-tracking-id": "clear-search", "aria-label": t('Clear this search') }, inputString && isParsingSuccessful ? (React.createElement(Flex, { justifyContent: { default: 'justifyContentSpaceBetween' } },
|
|
220
|
+
React.createElement(FlexItem, null,
|
|
221
|
+
React.createElement(Icon, { size: "md" },
|
|
222
|
+
React.createElement(CheckCircleIcon, { color: "#3E8635" }))),
|
|
223
|
+
React.createElement(FlexItem, null,
|
|
224
|
+
React.createElement(TimesCircleIcon, null)))) : (React.createElement(TimesCircleIcon, null)))))),
|
|
220
225
|
isAutoCompleteListVisible && (React.createElement("ul", { className: "pf-v5-c-select__menu", "aria-labelledby": "advance-search-typeahead-label", role: "listbox" }, autoCompleteList.map((item, index) => (React.createElement("li", { key: index, role: "presentation", className: `pf-v5-c-select__menu-wrapper ${selectedItemIndex === index ? 'pf-m-focus' : ''}` },
|
|
221
226
|
React.createElement("button", { type: "button", onClick: (e) => onItemClick(item.value), className: "pf-v5-c-select__menu-item", "aria-selected": selectedItemIndex === index ? true : false, role: "option" }, item.display))))))),
|
|
222
227
|
React.createElement(Button, { type: "button", variant: "primary", "data-tracking-id": "case-list-adv-search-button", className: "pf-v5-u-ml-sm", onClick: onSearchSubmit, isDisabled: isAdvancedSearchButtonDisabled },
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@rh-support/cases",
|
|
3
|
-
"version": "2.1.
|
|
3
|
+
"version": "2.1.29",
|
|
4
4
|
"publishConfig": {
|
|
5
5
|
"access": "public",
|
|
6
6
|
"registry": "https://registry.npmjs.org"
|
|
@@ -93,5 +93,5 @@
|
|
|
93
93
|
"defaults and supports es6-module",
|
|
94
94
|
"maintained node versions"
|
|
95
95
|
],
|
|
96
|
-
"gitHead": "
|
|
96
|
+
"gitHead": "672a8f5024aded7ed6ce4edb5c0991bc3f5570bb"
|
|
97
97
|
}
|