indicator-ui 0.0.46 → 0.0.48

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/dist/index.js CHANGED
@@ -9795,7 +9795,7 @@ __webpack_require__.r(__webpack_exports__);
9795
9795
 
9796
9796
 
9797
9797
 
9798
- function TextareaField({ value, name, placeholder, onChange, required = false, disabled = false, isError = false, offFocus = false, className = _styles__WEBPACK_IMPORTED_MODULE_2__.TextareaFieldStyle, }) {
9798
+ function TextareaField({ value, name, placeholder, onChange, required = false, disabled = false, isError = false, offFocus = false, additionStyles, className = _styles__WEBPACK_IMPORTED_MODULE_2__.TextareaFieldStyle, }) {
9799
9799
  const handleOnChange = (e) => {
9800
9800
  e.preventDefault();
9801
9801
  onChange && onChange(e.target.value);
@@ -9803,7 +9803,7 @@ function TextareaField({ value, name, placeholder, onChange, required = false, d
9803
9803
  return ((0,react_jsx_runtime__WEBPACK_IMPORTED_MODULE_0__.jsx)("textarea", { name: name, placeholder: placeholder, value: value || '', onChange: handleOnChange, required: required, disabled: disabled, className: (0,clsx__WEBPACK_IMPORTED_MODULE_1__["default"])(className?.textareaField, {
9804
9804
  [className?.isError]: isError,
9805
9805
  [className?.offFocus]: offFocus,
9806
- }) }));
9806
+ }, additionStyles) }));
9807
9807
  }
9808
9808
 
9809
9809
 
@@ -10148,60 +10148,68 @@ function SlideTransition({ children, animation, additionStyles, animationOptions
10148
10148
  };
10149
10149
  const animateExitDown = () => {
10150
10150
  const animateConfig = getConfig('exit-down');
10151
- animateDropWrapperRef.current.style.display = 'block';
10152
- const animateDropWrapper = animateDropWrapperRef.current.animate([
10153
- { transform: 'scaleY(1)', transformOrigin: 'bottom' },
10154
- { transform: 'scaleY(0)', transformOrigin: 'bottom' },
10155
- ], animateConfig);
10156
- mainRef.current.animate([
10157
- { transform: 'translateY(0)' },
10158
- { transform: 'translateY(100%)' },
10159
- ], animateConfig);
10160
- animateDropWrapper.finished.then(() => {
10161
- animateDropWrapperRef.current.style.display = `none`;
10162
- });
10151
+ if (animateDropWrapperRef.current && mainRef.current) {
10152
+ animateDropWrapperRef.current.style.display = 'block';
10153
+ const animateDropWrapper = animateDropWrapperRef.current.animate([
10154
+ { transform: 'scaleY(1)', transformOrigin: 'bottom' },
10155
+ { transform: 'scaleY(0)', transformOrigin: 'bottom' },
10156
+ ], animateConfig);
10157
+ mainRef.current.animate([
10158
+ { transform: 'translateY(0)' },
10159
+ { transform: 'translateY(100%)' },
10160
+ ], animateConfig);
10161
+ animateDropWrapper.finished.then(() => {
10162
+ animateDropWrapperRef.current.style.display = `none`;
10163
+ });
10164
+ }
10163
10165
  };
10164
10166
  const animateExitUp = () => {
10165
- const mainHeight = mainRef.current.clientHeight;
10166
- animateDropWrapperRef.current.style.display = 'block';
10167
- lastClientHeight.current = mainHeight;
10168
10167
  const animateConfig = getConfig('exit-up');
10169
- const animateDropWrapper = animateDropWrapperRef.current.animate([
10170
- { height: `${mainHeight}px` },
10171
- { height: `0` },
10172
- ], animateConfig);
10173
- mainRef.current.animate([
10174
- { transform: 'translateY(0)' },
10175
- { transform: 'translateY(-100%)' },
10176
- ], animateConfig);
10177
- animateDropWrapper.finished.then(() => {
10178
- animateDropWrapperRef.current.style.display = `none`;
10179
- });
10168
+ if (animateDropWrapperRef.current && mainRef.current) {
10169
+ const mainHeight = mainRef.current.clientHeight;
10170
+ animateDropWrapperRef.current.style.display = 'block';
10171
+ lastClientHeight.current = mainHeight;
10172
+ const animateDropWrapper = animateDropWrapperRef.current.animate([
10173
+ { height: `${mainHeight}px` },
10174
+ { height: `0` },
10175
+ ], animateConfig);
10176
+ mainRef.current.animate([
10177
+ { transform: 'translateY(0)' },
10178
+ { transform: 'translateY(-100%)' },
10179
+ ], animateConfig);
10180
+ animateDropWrapper.finished.then(() => {
10181
+ animateDropWrapperRef.current.style.display = `none`;
10182
+ });
10183
+ }
10180
10184
  };
10181
10185
  const animateEnterDown = () => {
10182
10186
  const animateConfig = getConfig('enter-down');
10183
- animateDropWrapperRef.current.style.display = 'block';
10184
- animateDropWrapperRef.current.animate([
10185
- { transform: 'scaleY(0)', transformOrigin: 'bottom', display: 'block' },
10186
- { transform: 'scaleY(1)', transformOrigin: 'bottom' },
10187
- ], animateConfig);
10188
- mainRef.current.animate([
10189
- { transform: 'translateY(100%)' },
10190
- { transform: 'translateY(0)' },
10191
- ], animateConfig);
10187
+ if (animateDropWrapperRef.current && mainRef.current) {
10188
+ animateDropWrapperRef.current.style.display = 'block';
10189
+ animateDropWrapperRef.current.animate([
10190
+ { transform: 'scaleY(0)', transformOrigin: 'bottom', display: 'block' },
10191
+ { transform: 'scaleY(1)', transformOrigin: 'bottom' },
10192
+ ], animateConfig);
10193
+ mainRef.current.animate([
10194
+ { transform: 'translateY(100%)' },
10195
+ { transform: 'translateY(0)' },
10196
+ ], animateConfig);
10197
+ }
10192
10198
  };
10193
10199
  const animateEnterUp = () => {
10194
10200
  const animateConfig = getConfig('enter-up');
10195
- animateDropWrapperRef.current.style.display = 'block';
10196
- const mainHeight = mainRef.current.clientHeight || lastClientHeight.current;
10197
- animateDropWrapperRef.current.animate([
10198
- { height: `0` },
10199
- { height: `${mainHeight}px` },
10200
- ], animateConfig);
10201
- mainRef.current.animate([
10202
- { transform: 'translateY(-100%)' },
10203
- { transform: 'translateY(0)' },
10204
- ], animateConfig);
10201
+ if (animateDropWrapperRef.current && mainRef.current) {
10202
+ animateDropWrapperRef.current.style.display = 'block';
10203
+ const mainHeight = mainRef.current.clientHeight || lastClientHeight.current;
10204
+ animateDropWrapperRef.current.animate([
10205
+ { height: `0` },
10206
+ { height: `${mainHeight}px` },
10207
+ ], animateConfig);
10208
+ mainRef.current.animate([
10209
+ { transform: 'translateY(-100%)' },
10210
+ { transform: 'translateY(0)' },
10211
+ ], animateConfig);
10212
+ }
10205
10213
  };
10206
10214
  (0,react__WEBPACK_IMPORTED_MODULE_1__.useEffect)(() => {
10207
10215
  switch (animation) {