@wavelengthusaf/components 4.0.1 → 4.1.0
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.
- package/README.md +10 -0
- package/dist/cjs/index.cjs +44 -1
- package/dist/cjs/index.d.cts +46 -3
- package/dist/esm/index.d.ts +46 -3
- package/dist/esm/index.js +43 -0
- package/package.json +1 -1
package/README.md
CHANGED
|
@@ -14,6 +14,16 @@ npm install @wavelengthusaf/components
|
|
|
14
14
|
|
|
15
15
|
## Release Notes
|
|
16
16
|
|
|
17
|
+
### 4.1.0
|
|
18
|
+
|
|
19
|
+
- 10/22/2025
|
|
20
|
+
- Added WavelengthMultiSelectAutocomplete
|
|
21
|
+
|
|
22
|
+
### 4.0.1
|
|
23
|
+
|
|
24
|
+
- 10/16/2025
|
|
25
|
+
- Fixed issue where WavelengthAutoComplete won't trigger onChange callback
|
|
26
|
+
|
|
17
27
|
### 4.0.0
|
|
18
28
|
|
|
19
29
|
-9/24/2025
|
package/dist/cjs/index.cjs
CHANGED
|
@@ -6784,6 +6784,7 @@ var WavelengthInput = _react.forwardRef.call(void 0,
|
|
|
6784
6784
|
el.removeAttribute(attr);
|
|
6785
6785
|
}
|
|
6786
6786
|
};
|
|
6787
|
+
if (style3) el.customStyles = style3;
|
|
6787
6788
|
set("id", id);
|
|
6788
6789
|
set("name", name);
|
|
6789
6790
|
set("value", value);
|
|
@@ -8121,6 +8122,48 @@ SampleComponent.displayName = "SampleComponent";
|
|
|
8121
8122
|
// src/index.ts
|
|
8122
8123
|
|
|
8123
8124
|
|
|
8125
|
+
// src/components/MultiSelect/WavelengthMultiSelectAutocomplete.tsx
|
|
8126
|
+
|
|
8127
|
+
|
|
8128
|
+
|
|
8129
|
+
var WavelengthMultiSelectAutocomplete = ({ options, placeholder = "Select Options", label, name, style: style3, onChange, value, ...rest }) => {
|
|
8130
|
+
const componentRef = _react.useRef.call(void 0, null);
|
|
8131
|
+
_react.useEffect.call(void 0, () => {
|
|
8132
|
+
const component = componentRef.current;
|
|
8133
|
+
if (!component) return;
|
|
8134
|
+
const handleValueChange = (event) => {
|
|
8135
|
+
if (onChange) {
|
|
8136
|
+
onChange(event.detail.value);
|
|
8137
|
+
}
|
|
8138
|
+
};
|
|
8139
|
+
component.addEventListener("change", handleValueChange);
|
|
8140
|
+
return () => {
|
|
8141
|
+
component.removeEventListener("change", handleValueChange);
|
|
8142
|
+
};
|
|
8143
|
+
}, [onChange]);
|
|
8144
|
+
_react.useEffect.call(void 0, () => {
|
|
8145
|
+
const component = componentRef.current;
|
|
8146
|
+
if (!component) return;
|
|
8147
|
+
if (placeholder) component.setAttribute("placeholder", placeholder);
|
|
8148
|
+
if (label) component.setAttribute("label", label);
|
|
8149
|
+
if (name) component.setAttribute("name", name);
|
|
8150
|
+
if (options) component.autocompleteOptions = options;
|
|
8151
|
+
if (style3) component.customStyles = style3;
|
|
8152
|
+
}, [options, placeholder, name, label, style3]);
|
|
8153
|
+
_react.useEffect.call(void 0, () => {
|
|
8154
|
+
const component = componentRef.current;
|
|
8155
|
+
if (component && value) {
|
|
8156
|
+
component.value = value;
|
|
8157
|
+
}
|
|
8158
|
+
}, [value]);
|
|
8159
|
+
return /* @__PURE__ */ _jsxruntime.jsx.call(void 0, "wavelength-multi-select-autocomplete", { ref: componentRef, ...rest });
|
|
8160
|
+
};
|
|
8161
|
+
|
|
8162
|
+
// src/index.ts
|
|
8163
|
+
|
|
8164
|
+
|
|
8165
|
+
|
|
8166
|
+
|
|
8124
8167
|
|
|
8125
8168
|
|
|
8126
8169
|
|
|
@@ -8185,7 +8228,7 @@ SampleComponent.displayName = "SampleComponent";
|
|
|
8185
8228
|
|
|
8186
8229
|
|
|
8187
8230
|
|
|
8188
|
-
exports.ButtonIcon = ButtonIcon; exports.ButtonMenu = ButtonMenu; exports.ChildDataTable = ChildDataTable; exports.DefaultCarousel = DefaultCarousel; exports.DefaultPagination = DefaultPagination; exports.NestedDataTable = NestedDataTable; exports.SampleComponent = SampleComponent; exports.SampleComponentElement = _webcomponents.SampleComponent; exports.SliderCardCarousel = SliderCardCarousel; exports.WavelengthAccessAlert = WavelengthAccessAlert; exports.WavelengthAlert = WavelengthAlert; exports.WavelengthAppLogo = WavelengthAppLogo; exports.WavelengthAppTheme = WavelengthAppTheme; exports.WavelengthAutoComplete = WavelengthAutoComplete; exports.WavelengthAutocomplete = WavelengthAutocomplete; exports.WavelengthBanner = WavelengthBanner; exports.WavelengthBannerElement = _webcomponents.WavelengthBanner; exports.WavelengthBox = WavelengthBox; exports.WavelengthButton = WavelengthButton; exports.WavelengthButtonElement = _webcomponents.WavelengthButton; exports.WavelengthCommentDisplay = WavelengthCommentDisplay; exports.WavelengthConfirmationModal = WavelengthConfirmationModal; exports.WavelengthContentModal = WavelengthContentModal; exports.WavelengthContentPlaceholder = WavelengthContentPlaceholder; exports.WavelengthDataTable = WavelengthDataTable; exports.WavelengthDatePicker = WavelengthDatePicker; exports.WavelengthDatePickerElement = _webcomponents.WavelengthDatePicker; exports.WavelengthDefaultIcon = WavelengthDefaultIcon; exports.WavelengthDragAndDrop = WavelengthDragAndDrop; exports.WavelengthDropdown = WavelengthDropdown; exports.WavelengthDropdownButton = WavelengthDropdownButton; exports.WavelengthExampleComponent = WavelengthExampleComponent; exports.WavelengthFileDownloader = WavelengthFileDownloader; exports.WavelengthFooter = WavelengthFooter; exports.WavelengthForm = WavelengthForm; exports.WavelengthFormElement = _webcomponents.WavelengthForm; exports.WavelengthInput = WavelengthInput; exports.WavelengthInputElement = _webcomponents.WavelengthInput; exports.WavelengthManyPlanes = WavelengthManyPlanes; exports.WavelengthNotAvailablePage = WavelengthNotAvailablePage; exports.WavelengthPermissionAlert = WavelengthPermissionAlert; exports.WavelengthPlaneTrail = WavelengthPlaneTrail; exports.WavelengthPopUpMenu = WavelengthPopUpMenu; exports.WavelengthProgressBar = WavelengthProgressBar; exports.WavelengthProgressBarElement = _webcomponents.WavelengthProgressBar; exports.WavelengthSearch = WavelengthSearch; exports.WavelengthSearchTextField = WavelengthSearchTextField; exports.WavelengthSideBar = WavelengthSideBar; exports.WavelengthSlider = WavelengthSlider; exports.WavelengthSnackbar = WavelengthSnackbar; exports.WavelengthSpinningLogo = WavelengthSpinningLogo; exports.WavelengthSpinningOuterCircle = WavelengthSpinningOuterCircle; exports.WavelengthStandardSnackbar = WavelengthStandardSnackbar; exports.WavelengthStyledButton = WavelengthStyledButton; exports.WavelengthTestSnackbar = WavelengthTestSnackbar; exports.WavelengthTitleBar = WavelengthTitleBar; exports.WavelengthTitleBarElement = _webcomponents.WavelengthTitleBar; exports.add = add; exports.ascendingRange = ascendingRange; exports.concat = concat; exports.findBestStringMatch = findBestStringMatch; exports.range = range; exports.useOutsideClick = useOutsideClick; exports.useThemeContext = useThemeContext;
|
|
8231
|
+
exports.ButtonIcon = ButtonIcon; exports.ButtonMenu = ButtonMenu; exports.ChildDataTable = ChildDataTable; exports.DefaultCarousel = DefaultCarousel; exports.DefaultPagination = DefaultPagination; exports.NestedDataTable = NestedDataTable; exports.SampleComponent = SampleComponent; exports.SampleComponentElement = _webcomponents.SampleComponent; exports.SliderCardCarousel = SliderCardCarousel; exports.WavelengthAccessAlert = WavelengthAccessAlert; exports.WavelengthAlert = WavelengthAlert; exports.WavelengthAppLogo = WavelengthAppLogo; exports.WavelengthAppTheme = WavelengthAppTheme; exports.WavelengthAutoComplete = WavelengthAutoComplete; exports.WavelengthAutocomplete = WavelengthAutocomplete; exports.WavelengthBanner = WavelengthBanner; exports.WavelengthBannerElement = _webcomponents.WavelengthBanner; exports.WavelengthBox = WavelengthBox; exports.WavelengthButton = WavelengthButton; exports.WavelengthButtonElement = _webcomponents.WavelengthButton; exports.WavelengthCommentDisplay = WavelengthCommentDisplay; exports.WavelengthConfirmationModal = WavelengthConfirmationModal; exports.WavelengthContentModal = WavelengthContentModal; exports.WavelengthContentPlaceholder = WavelengthContentPlaceholder; exports.WavelengthDataTable = WavelengthDataTable; exports.WavelengthDatePicker = WavelengthDatePicker; exports.WavelengthDatePickerElement = _webcomponents.WavelengthDatePicker; exports.WavelengthDefaultIcon = WavelengthDefaultIcon; exports.WavelengthDragAndDrop = WavelengthDragAndDrop; exports.WavelengthDropdown = WavelengthDropdown; exports.WavelengthDropdownButton = WavelengthDropdownButton; exports.WavelengthExampleComponent = WavelengthExampleComponent; exports.WavelengthFileDownloader = WavelengthFileDownloader; exports.WavelengthFooter = WavelengthFooter; exports.WavelengthForm = WavelengthForm; exports.WavelengthFormElement = _webcomponents.WavelengthForm; exports.WavelengthInput = WavelengthInput; exports.WavelengthInputElement = _webcomponents.WavelengthInput; exports.WavelengthManyPlanes = WavelengthManyPlanes; exports.WavelengthMultiSelectAutocomplete = WavelengthMultiSelectAutocomplete; exports.WavelengthMultiSelectAutocompleteElement = _webcomponents.WavelengthMultiSelectAutocomplete; exports.WavelengthNotAvailablePage = WavelengthNotAvailablePage; exports.WavelengthPermissionAlert = WavelengthPermissionAlert; exports.WavelengthPlaneTrail = WavelengthPlaneTrail; exports.WavelengthPopUpMenu = WavelengthPopUpMenu; exports.WavelengthProgressBar = WavelengthProgressBar; exports.WavelengthProgressBarElement = _webcomponents.WavelengthProgressBar; exports.WavelengthSearch = WavelengthSearch; exports.WavelengthSearchTextField = WavelengthSearchTextField; exports.WavelengthSideBar = WavelengthSideBar; exports.WavelengthSlider = WavelengthSlider; exports.WavelengthSnackbar = WavelengthSnackbar; exports.WavelengthSpinningLogo = WavelengthSpinningLogo; exports.WavelengthSpinningOuterCircle = WavelengthSpinningOuterCircle; exports.WavelengthStandardSnackbar = WavelengthStandardSnackbar; exports.WavelengthStyledButton = WavelengthStyledButton; exports.WavelengthTestSnackbar = WavelengthTestSnackbar; exports.WavelengthTitleBar = WavelengthTitleBar; exports.WavelengthTitleBarElement = _webcomponents.WavelengthTitleBar; exports.add = add; exports.ascendingRange = ascendingRange; exports.concat = concat; exports.findBestStringMatch = findBestStringMatch; exports.range = range; exports.useOutsideClick = useOutsideClick; exports.useThemeContext = useThemeContext;
|
|
8189
8232
|
/*! Bundled license information:
|
|
8190
8233
|
|
|
8191
8234
|
react-is/cjs/react-is.production.min.js:
|
package/dist/cjs/index.d.cts
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
import * as React$1 from 'react';
|
|
2
|
-
import React__default, { ReactNode, ChangeEvent, ReactElement } from 'react';
|
|
3
|
-
export { SampleComponent as SampleComponentElement, WavelengthBanner as WavelengthBannerElement, WavelengthButton as WavelengthButtonElement, WavelengthDatePicker as WavelengthDatePickerElement, WavelengthForm as WavelengthFormElement, WavelengthInput as WavelengthInputElement, WavelengthProgressBar as WavelengthProgressBarElement, WavelengthTitleBar as WavelengthTitleBarElement } from '@wavelengthusaf/web-components';
|
|
2
|
+
import React__default, { ReactNode, ChangeEvent, ReactElement, CSSProperties } from 'react';
|
|
3
|
+
export { SampleComponent as SampleComponentElement, WavelengthBanner as WavelengthBannerElement, WavelengthButton as WavelengthButtonElement, WavelengthDatePicker as WavelengthDatePickerElement, WavelengthForm as WavelengthFormElement, WavelengthInput as WavelengthInputElement, WavelengthMultiSelectAutocomplete as WavelengthMultiSelectAutocompleteElement, WavelengthProgressBar as WavelengthProgressBarElement, WavelengthTitleBar as WavelengthTitleBarElement } from '@wavelengthusaf/web-components';
|
|
4
4
|
import * as react_jsx_runtime from 'react/jsx-runtime';
|
|
5
5
|
import { TextFieldVariants, SxProps, Theme } from '@mui/material';
|
|
6
6
|
import { z } from 'zod';
|
|
@@ -712,6 +712,10 @@ declare namespace DefaultPagination {
|
|
|
712
712
|
var displayName: string;
|
|
713
713
|
}
|
|
714
714
|
|
|
715
|
+
type StyleProp = {
|
|
716
|
+
[selector: string]: any;
|
|
717
|
+
};
|
|
718
|
+
|
|
715
719
|
interface WavelengthInputProps extends React__default.HTMLAttributes<HTMLElement> {
|
|
716
720
|
id?: string;
|
|
717
721
|
name?: string;
|
|
@@ -743,6 +747,7 @@ interface WavelengthInputProps extends React__default.HTMLAttributes<HTMLElement
|
|
|
743
747
|
helperColor?: string;
|
|
744
748
|
label?: string;
|
|
745
749
|
onChange?: (event: ChangeEvent<HTMLInputElement>) => void;
|
|
750
|
+
style?: StyleProp;
|
|
746
751
|
}
|
|
747
752
|
declare const WavelengthInput: React__default.ForwardRefExoticComponent<WavelengthInputProps & React__default.RefAttributes<HTMLElement & {
|
|
748
753
|
validate?: () => boolean;
|
|
@@ -873,4 +878,42 @@ interface SampleComponentProps extends React__default.HTMLAttributes<HTMLElement
|
|
|
873
878
|
}
|
|
874
879
|
declare const SampleComponent: React__default.FC<SampleComponentProps>;
|
|
875
880
|
|
|
876
|
-
|
|
881
|
+
interface Option {
|
|
882
|
+
label: string;
|
|
883
|
+
value: string;
|
|
884
|
+
}
|
|
885
|
+
interface CustomSelectors {
|
|
886
|
+
"&:hover"?: CSSProperties;
|
|
887
|
+
"&:focus"?: CSSProperties;
|
|
888
|
+
/**Styles the container which holds the input and label*/
|
|
889
|
+
"& .multi-select-input-wrapper"?: CSSProperties;
|
|
890
|
+
/**Styles the input*/
|
|
891
|
+
"& .multi-select-input"?: CSSProperties;
|
|
892
|
+
/**Styles the label*/
|
|
893
|
+
"& .multi-select-label"?: CSSProperties;
|
|
894
|
+
/**Styles the dropdown*/
|
|
895
|
+
"& .multi-select-dropdown"?: CSSProperties;
|
|
896
|
+
/** Styles the container that holds the options and checkbox*/
|
|
897
|
+
"& .multi-select-option-container"?: CSSProperties;
|
|
898
|
+
/**Styles the individual options*/
|
|
899
|
+
"& .multi-select-option"?: CSSProperties;
|
|
900
|
+
/**Styles the clear button*/
|
|
901
|
+
"& .multi-select-clear"?: CSSProperties;
|
|
902
|
+
/**Styles the dropdown arrow*/
|
|
903
|
+
"& .multi-select-arrow"?: CSSProperties;
|
|
904
|
+
/**Styles the chip*/
|
|
905
|
+
"& .multi-select-chip"?: CSSProperties;
|
|
906
|
+
}
|
|
907
|
+
type CustomStyleProp = CustomSelectors & StyleProp;
|
|
908
|
+
interface MultiSelectAutocompleteProps {
|
|
909
|
+
options: Option[];
|
|
910
|
+
placeholder?: string;
|
|
911
|
+
label?: string;
|
|
912
|
+
name?: string;
|
|
913
|
+
style?: CustomStyleProp;
|
|
914
|
+
onChange?: (selectedOptions: Option[]) => void;
|
|
915
|
+
value?: Option[];
|
|
916
|
+
}
|
|
917
|
+
declare const WavelengthMultiSelectAutocomplete: React__default.FC<MultiSelectAutocompleteProps>;
|
|
918
|
+
|
|
919
|
+
export { ButtonIcon, ButtonMenu, ChildDataTable, DefaultCarousel, DefaultPagination, NestedDataTable, SampleComponent, type SearchProps, type SearchResult, SliderCardCarousel, type StyledButtonPropsTwo, type ThemeProperties, WavelengthAccessAlert, WavelengthAlert, WavelengthAppLogo, WavelengthAppTheme, WavelengthAutoComplete, WavelengthAutocomplete, WavelengthBanner, WavelengthBox, WavelengthButton, WavelengthCommentDisplay, WavelengthConfirmationModal, WavelengthContentModal, WavelengthContentPlaceholder, WavelengthDataTable, WavelengthDatePicker, WavelengthDefaultIcon, WavelengthDragAndDrop, WavelengthDropdown, WavelengthDropdownButton, WavelengthExampleComponent, WavelengthFileDownloader, WavelengthFooter, WavelengthForm, WavelengthInput, WavelengthManyPlanes, WavelengthMultiSelectAutocomplete, WavelengthNotAvailablePage, WavelengthPermissionAlert, WavelengthPlaneTrail, WavelengthPopUpMenu, WavelengthProgressBar, WavelengthSearch, WavelengthSearchTextField, WavelengthSideBar, WavelengthSlider, WavelengthSnackbar, WavelengthSpinningLogo, WavelengthSpinningOuterCircle, WavelengthStandardSnackbar, WavelengthStyledButton, WavelengthTestSnackbar, WavelengthTitleBar, add, ascendingRange, concat, findBestStringMatch, type menuItemProps, range, useOutsideClick, useThemeContext };
|
package/dist/esm/index.d.ts
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
import * as React$1 from 'react';
|
|
2
|
-
import React__default, { ReactNode, ChangeEvent, ReactElement } from 'react';
|
|
3
|
-
export { SampleComponent as SampleComponentElement, WavelengthBanner as WavelengthBannerElement, WavelengthButton as WavelengthButtonElement, WavelengthDatePicker as WavelengthDatePickerElement, WavelengthForm as WavelengthFormElement, WavelengthInput as WavelengthInputElement, WavelengthProgressBar as WavelengthProgressBarElement, WavelengthTitleBar as WavelengthTitleBarElement } from '@wavelengthusaf/web-components';
|
|
2
|
+
import React__default, { ReactNode, ChangeEvent, ReactElement, CSSProperties } from 'react';
|
|
3
|
+
export { SampleComponent as SampleComponentElement, WavelengthBanner as WavelengthBannerElement, WavelengthButton as WavelengthButtonElement, WavelengthDatePicker as WavelengthDatePickerElement, WavelengthForm as WavelengthFormElement, WavelengthInput as WavelengthInputElement, WavelengthMultiSelectAutocomplete as WavelengthMultiSelectAutocompleteElement, WavelengthProgressBar as WavelengthProgressBarElement, WavelengthTitleBar as WavelengthTitleBarElement } from '@wavelengthusaf/web-components';
|
|
4
4
|
import * as react_jsx_runtime from 'react/jsx-runtime';
|
|
5
5
|
import { TextFieldVariants, SxProps, Theme } from '@mui/material';
|
|
6
6
|
import { z } from 'zod';
|
|
@@ -712,6 +712,10 @@ declare namespace DefaultPagination {
|
|
|
712
712
|
var displayName: string;
|
|
713
713
|
}
|
|
714
714
|
|
|
715
|
+
type StyleProp = {
|
|
716
|
+
[selector: string]: any;
|
|
717
|
+
};
|
|
718
|
+
|
|
715
719
|
interface WavelengthInputProps extends React__default.HTMLAttributes<HTMLElement> {
|
|
716
720
|
id?: string;
|
|
717
721
|
name?: string;
|
|
@@ -743,6 +747,7 @@ interface WavelengthInputProps extends React__default.HTMLAttributes<HTMLElement
|
|
|
743
747
|
helperColor?: string;
|
|
744
748
|
label?: string;
|
|
745
749
|
onChange?: (event: ChangeEvent<HTMLInputElement>) => void;
|
|
750
|
+
style?: StyleProp;
|
|
746
751
|
}
|
|
747
752
|
declare const WavelengthInput: React__default.ForwardRefExoticComponent<WavelengthInputProps & React__default.RefAttributes<HTMLElement & {
|
|
748
753
|
validate?: () => boolean;
|
|
@@ -873,4 +878,42 @@ interface SampleComponentProps extends React__default.HTMLAttributes<HTMLElement
|
|
|
873
878
|
}
|
|
874
879
|
declare const SampleComponent: React__default.FC<SampleComponentProps>;
|
|
875
880
|
|
|
876
|
-
|
|
881
|
+
interface Option {
|
|
882
|
+
label: string;
|
|
883
|
+
value: string;
|
|
884
|
+
}
|
|
885
|
+
interface CustomSelectors {
|
|
886
|
+
"&:hover"?: CSSProperties;
|
|
887
|
+
"&:focus"?: CSSProperties;
|
|
888
|
+
/**Styles the container which holds the input and label*/
|
|
889
|
+
"& .multi-select-input-wrapper"?: CSSProperties;
|
|
890
|
+
/**Styles the input*/
|
|
891
|
+
"& .multi-select-input"?: CSSProperties;
|
|
892
|
+
/**Styles the label*/
|
|
893
|
+
"& .multi-select-label"?: CSSProperties;
|
|
894
|
+
/**Styles the dropdown*/
|
|
895
|
+
"& .multi-select-dropdown"?: CSSProperties;
|
|
896
|
+
/** Styles the container that holds the options and checkbox*/
|
|
897
|
+
"& .multi-select-option-container"?: CSSProperties;
|
|
898
|
+
/**Styles the individual options*/
|
|
899
|
+
"& .multi-select-option"?: CSSProperties;
|
|
900
|
+
/**Styles the clear button*/
|
|
901
|
+
"& .multi-select-clear"?: CSSProperties;
|
|
902
|
+
/**Styles the dropdown arrow*/
|
|
903
|
+
"& .multi-select-arrow"?: CSSProperties;
|
|
904
|
+
/**Styles the chip*/
|
|
905
|
+
"& .multi-select-chip"?: CSSProperties;
|
|
906
|
+
}
|
|
907
|
+
type CustomStyleProp = CustomSelectors & StyleProp;
|
|
908
|
+
interface MultiSelectAutocompleteProps {
|
|
909
|
+
options: Option[];
|
|
910
|
+
placeholder?: string;
|
|
911
|
+
label?: string;
|
|
912
|
+
name?: string;
|
|
913
|
+
style?: CustomStyleProp;
|
|
914
|
+
onChange?: (selectedOptions: Option[]) => void;
|
|
915
|
+
value?: Option[];
|
|
916
|
+
}
|
|
917
|
+
declare const WavelengthMultiSelectAutocomplete: React__default.FC<MultiSelectAutocompleteProps>;
|
|
918
|
+
|
|
919
|
+
export { ButtonIcon, ButtonMenu, ChildDataTable, DefaultCarousel, DefaultPagination, NestedDataTable, SampleComponent, type SearchProps, type SearchResult, SliderCardCarousel, type StyledButtonPropsTwo, type ThemeProperties, WavelengthAccessAlert, WavelengthAlert, WavelengthAppLogo, WavelengthAppTheme, WavelengthAutoComplete, WavelengthAutocomplete, WavelengthBanner, WavelengthBox, WavelengthButton, WavelengthCommentDisplay, WavelengthConfirmationModal, WavelengthContentModal, WavelengthContentPlaceholder, WavelengthDataTable, WavelengthDatePicker, WavelengthDefaultIcon, WavelengthDragAndDrop, WavelengthDropdown, WavelengthDropdownButton, WavelengthExampleComponent, WavelengthFileDownloader, WavelengthFooter, WavelengthForm, WavelengthInput, WavelengthManyPlanes, WavelengthMultiSelectAutocomplete, WavelengthNotAvailablePage, WavelengthPermissionAlert, WavelengthPlaneTrail, WavelengthPopUpMenu, WavelengthProgressBar, WavelengthSearch, WavelengthSearchTextField, WavelengthSideBar, WavelengthSlider, WavelengthSnackbar, WavelengthSpinningLogo, WavelengthSpinningOuterCircle, WavelengthStandardSnackbar, WavelengthStyledButton, WavelengthTestSnackbar, WavelengthTitleBar, add, ascendingRange, concat, findBestStringMatch, type menuItemProps, range, useOutsideClick, useThemeContext };
|
package/dist/esm/index.js
CHANGED
|
@@ -6784,6 +6784,7 @@ var WavelengthInput = forwardRef(
|
|
|
6784
6784
|
el.removeAttribute(attr);
|
|
6785
6785
|
}
|
|
6786
6786
|
};
|
|
6787
|
+
if (style3) el.customStyles = style3;
|
|
6787
6788
|
set("id", id);
|
|
6788
6789
|
set("name", name);
|
|
6789
6790
|
set("value", value);
|
|
@@ -8120,6 +8121,46 @@ SampleComponent.displayName = "SampleComponent";
|
|
|
8120
8121
|
|
|
8121
8122
|
// src/index.ts
|
|
8122
8123
|
import { SampleComponent as SampleComponent2 } from "@wavelengthusaf/web-components";
|
|
8124
|
+
|
|
8125
|
+
// src/components/MultiSelect/WavelengthMultiSelectAutocomplete.tsx
|
|
8126
|
+
import { useEffect as useEffect14, useRef as useRef13 } from "react";
|
|
8127
|
+
import "@wavelengthusaf/web-components";
|
|
8128
|
+
import { jsx as jsx48 } from "react/jsx-runtime";
|
|
8129
|
+
var WavelengthMultiSelectAutocomplete = ({ options, placeholder = "Select Options", label, name, style: style3, onChange, value, ...rest }) => {
|
|
8130
|
+
const componentRef = useRef13(null);
|
|
8131
|
+
useEffect14(() => {
|
|
8132
|
+
const component = componentRef.current;
|
|
8133
|
+
if (!component) return;
|
|
8134
|
+
const handleValueChange = (event) => {
|
|
8135
|
+
if (onChange) {
|
|
8136
|
+
onChange(event.detail.value);
|
|
8137
|
+
}
|
|
8138
|
+
};
|
|
8139
|
+
component.addEventListener("change", handleValueChange);
|
|
8140
|
+
return () => {
|
|
8141
|
+
component.removeEventListener("change", handleValueChange);
|
|
8142
|
+
};
|
|
8143
|
+
}, [onChange]);
|
|
8144
|
+
useEffect14(() => {
|
|
8145
|
+
const component = componentRef.current;
|
|
8146
|
+
if (!component) return;
|
|
8147
|
+
if (placeholder) component.setAttribute("placeholder", placeholder);
|
|
8148
|
+
if (label) component.setAttribute("label", label);
|
|
8149
|
+
if (name) component.setAttribute("name", name);
|
|
8150
|
+
if (options) component.autocompleteOptions = options;
|
|
8151
|
+
if (style3) component.customStyles = style3;
|
|
8152
|
+
}, [options, placeholder, name, label, style3]);
|
|
8153
|
+
useEffect14(() => {
|
|
8154
|
+
const component = componentRef.current;
|
|
8155
|
+
if (component && value) {
|
|
8156
|
+
component.value = value;
|
|
8157
|
+
}
|
|
8158
|
+
}, [value]);
|
|
8159
|
+
return /* @__PURE__ */ jsx48("wavelength-multi-select-autocomplete", { ref: componentRef, ...rest });
|
|
8160
|
+
};
|
|
8161
|
+
|
|
8162
|
+
// src/index.ts
|
|
8163
|
+
import { WavelengthMultiSelectAutocomplete as WavelengthMultiSelectAutocomplete2 } from "@wavelengthusaf/web-components";
|
|
8123
8164
|
export {
|
|
8124
8165
|
ButtonIcon,
|
|
8125
8166
|
ButtonMenu,
|
|
@@ -8160,6 +8201,8 @@ export {
|
|
|
8160
8201
|
WavelengthInput,
|
|
8161
8202
|
WavelengthInput2 as WavelengthInputElement,
|
|
8162
8203
|
WavelengthManyPlanes,
|
|
8204
|
+
WavelengthMultiSelectAutocomplete,
|
|
8205
|
+
WavelengthMultiSelectAutocomplete2 as WavelengthMultiSelectAutocompleteElement,
|
|
8163
8206
|
WavelengthNotAvailablePage,
|
|
8164
8207
|
WavelengthPermissionAlert,
|
|
8165
8208
|
WavelengthPlaneTrail,
|
package/package.json
CHANGED
|
@@ -2,7 +2,7 @@
|
|
|
2
2
|
"name": "@wavelengthusaf/components",
|
|
3
3
|
"author": "563 EWS - Wavelength",
|
|
4
4
|
"license": "MIT",
|
|
5
|
-
"version": "4.0
|
|
5
|
+
"version": "4.1.0",
|
|
6
6
|
"description": "Common component library used by Wavelength developers",
|
|
7
7
|
"main": "/dist/cjs/index.cjs",
|
|
8
8
|
"module": "/dist/esm/index.js",
|