@sellout/ui 0.0.201 → 0.0.202

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,3 +1,4 @@
1
+ import React from "react";
1
2
  interface IAddress {
2
3
  address1?: string;
3
4
  address2?: string;
@@ -19,5 +20,5 @@ export declare type AddressSearchDropdownProps = {
19
20
  label?: string;
20
21
  tip?: string;
21
22
  };
22
- export default function AddressSearchDropdown({ value, onChange, width, label, tip, }: AddressSearchDropdownProps): JSX.Element;
23
+ export default function AddressSearchDropdown({ value, onChange, width, label, tip, }: AddressSearchDropdownProps): React.JSX.Element;
23
24
  export {};
@@ -1,3 +1,4 @@
1
+ import React from "react";
1
2
  import { Colors } from '../Colors';
2
3
  export declare enum ButtonTypes {
3
4
  Next = "Next",
@@ -29,4 +30,4 @@ export declare type ButtonProps = {
29
30
  tip?: string;
30
31
  subLabel?: string;
31
32
  };
32
- export default function Button({ type, state, bgColor, textColor, text, onClick, icon, iconPosition, iconSize, margin, loading, }: ButtonProps): JSX.Element;
33
+ export default function Button({ type, state, bgColor, textColor, text, onClick, icon, iconPosition, iconSize, margin, loading, }: ButtonProps): React.JSX.Element;
@@ -41,6 +41,9 @@ var CodeInput = function (_a) {
41
41
  onComplete(currentValue.join(''));
42
42
  }
43
43
  };
44
+ useEffect(function () {
45
+ onChange && onChange(value);
46
+ }, [value]);
44
47
  var renderInput = function (index) {
45
48
  var curValue = value[index];
46
49
  return (React.createElement(Input, { key: index, autoFocus: index === 0, value: curValue, type: "number", pattern: "\\d*", ref: function (ref) { return inputs[index] = ref; }, onChange: function (event) {
@@ -1,3 +1,4 @@
1
+ import React from "react";
1
2
  export declare type CounterProps = {
2
3
  value: number;
3
4
  maxValue?: number;
@@ -5,4 +6,4 @@ export declare type CounterProps = {
5
6
  onIncrement: Function;
6
7
  onDecrement: Function;
7
8
  };
8
- export default function Counter({ value, maxValue, minValue, onIncrement, onDecrement, }: CounterProps): JSX.Element;
9
+ export default function Counter({ value, maxValue, minValue, onIncrement, onDecrement, }: CounterProps): React.JSX.Element;
@@ -30,4 +30,4 @@ export declare type InputProps = {
30
30
  disabled?: boolean;
31
31
  inputWidth?: boolean;
32
32
  };
33
- export default function Input({ inputRef, autoFocus, placeholder, value, defaultValue, format, type, onMouseEnter, onMouseLeave, onChange, onFocus, onBlur, onSubmit, canSubmit, loading, margin, width, inputWidth, onEnter, label, subLabel, tip, maxLength, validationError, disabled, }: InputProps): JSX.Element;
33
+ export default function Input({ inputRef, autoFocus, placeholder, value, defaultValue, format, type, onMouseEnter, onMouseLeave, onChange, onFocus, onBlur, onSubmit, canSubmit, loading, margin, width, inputWidth, onEnter, label, subLabel, tip, maxLength, validationError, disabled, }: InputProps): React.JSX.Element;
@@ -29,4 +29,4 @@ export declare type InputProps = {
29
29
  validationError?: string;
30
30
  disabled?: boolean;
31
31
  };
32
- export default function Input({ inputRef, autoFocus, placeholder, value, defaultValue, format, type, onMouseEnter, onMouseLeave, onChange, onFocus, onBlur, onSubmit, canSubmit, loading, margin, width, onEnter, label, subLabel, tip, maxLength, validationError, disabled, }: InputProps): JSX.Element;
32
+ export default function Input({ inputRef, autoFocus, placeholder, value, defaultValue, format, type, onMouseEnter, onMouseLeave, onChange, onFocus, onBlur, onSubmit, canSubmit, loading, margin, width, onEnter, label, subLabel, tip, maxLength, validationError, disabled, }: InputProps): React.JSX.Element;
@@ -1,3 +1,4 @@
1
+ import React from "react";
1
2
  import { Colors } from "../Colors";
2
3
  export declare const Icons: {
3
4
  Amex: import("@fortawesome/fontawesome-common-types").IconDefinition;
@@ -205,4 +206,4 @@ export declare type IconProps = {
205
206
  transitionDuration?: string;
206
207
  rotation?: number;
207
208
  };
208
- export default function Icon({ icon, color, hoverColor, onClick, size, top, left, right, position, zIndex, margin, tip, transitionDuration, rotation, }: IconProps): JSX.Element;
209
+ export default function Icon({ icon, color, hoverColor, onClick, size, top, left, right, position, zIndex, margin, tip, transitionDuration, rotation, }: IconProps): React.JSX.Element;
@@ -20,4 +20,4 @@ export declare type InputProps = {
20
20
  padding?: string;
21
21
  width?: string;
22
22
  };
23
- export default function Input({ inputRef, autoFocus, placeholder, value, defaultValue, icon, type, onMouseEnter, onMouseLeave, onChange, onFocus, onBlur, onSubmit, onClear, canSubmit, loading, margin, padding, width, }: InputProps): JSX.Element;
23
+ export default function Input({ inputRef, autoFocus, placeholder, value, defaultValue, icon, type, onMouseEnter, onMouseLeave, onChange, onFocus, onBlur, onSubmit, onClear, canSubmit, loading, margin, padding, width, }: InputProps): React.JSX.Element;
@@ -1,3 +1,4 @@
1
+ import React from "react";
1
2
  import { Colors } from "./../Colors";
2
3
  export declare enum LoaderSizes {
3
4
  FuckingTiny = "FuckingTiny",
@@ -10,4 +11,4 @@ export declare enum LoaderSizes {
10
11
  export default function Loader({ size, color, }: {
11
12
  size?: LoaderSizes | undefined;
12
13
  color?: Colors | undefined;
13
- }): JSX.Element;
14
+ }): React.JSX.Element;
@@ -1,3 +1,4 @@
1
+ import React from "react";
1
2
  import { CounterProps } from './Counter';
2
3
  export declare type ProductProps = {
3
4
  title: string;
@@ -11,4 +12,4 @@ export declare type ProductProps = {
11
12
  timeZone?: string;
12
13
  remainingQty?: number;
13
14
  } & CounterProps;
14
- export default function Product({ title, price, subtitle, description, isRSVP, value, minValue, maxValue, onIncrement, onDecrement, eventDays, isMultiDaysEvent, timeZone, remainingQty }: ProductProps): JSX.Element;
15
+ export default function Product({ title, price, subtitle, description, isRSVP, value, minValue, maxValue, onIncrement, onDecrement, eventDays, isMultiDaysEvent, timeZone, remainingQty }: ProductProps): React.JSX.Element;
@@ -29,5 +29,5 @@ export declare type SearchDropdownProps = {
29
29
  subLabel?: string;
30
30
  icon?: any;
31
31
  };
32
- export default function SearchDropdown({ type, value, onChange, placeholder, width, searchQuery, setSearchQuery, items, footer, onClear, label, tip, subLabel, icon, }: SearchDropdownProps): JSX.Element;
32
+ export default function SearchDropdown({ type, value, onChange, placeholder, width, searchQuery, setSearchQuery, items, footer, onClear, label, tip, subLabel, icon, }: SearchDropdownProps): React.JSX.Element;
33
33
  export {};
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@sellout/ui",
3
- "version": "0.0.201",
3
+ "version": "0.0.202",
4
4
  "main": "build/index.js",
5
5
  "module": "build/index.es.js",
6
6
  "files": [
@@ -70,7 +70,7 @@
70
70
  "shortid": "^2.2.16",
71
71
  "use-places-autocomplete": "^1.9.4"
72
72
  },
73
- "gitHead": "4172f8fb2ba3c22d5cae16599219e3e4ea7992bc",
73
+ "gitHead": "4ee53a3385c818a40c3fa7c253a0e839ad1f94ec",
74
74
  "peerDependencies": {
75
75
  "react": "^16.13.0",
76
76
  "react-dom": "^16.13.0",