ui-beyable 1.0.15 → 1.0.17

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.
Files changed (35) hide show
  1. package/lib/cjs/components/Btn/types.d.ts +4 -4
  2. package/lib/cjs/components/Confirm/Confirm.d.ts +4 -0
  3. package/lib/cjs/components/Confirm/types.d.ts +17 -0
  4. package/lib/cjs/components/Fieldset/Fieldset.d.ts +4 -0
  5. package/lib/cjs/components/Fieldset/types.d.ts +13 -0
  6. package/lib/cjs/components/Listbox/Listbox.d.ts +6 -0
  7. package/lib/cjs/components/Listbox/types.d.ts +29 -0
  8. package/lib/cjs/components/Modal/Modal.d.ts +5 -2
  9. package/lib/cjs/components/Modal/types.d.ts +33 -4
  10. package/lib/cjs/components/Panel/types.d.ts +3 -3
  11. package/lib/cjs/components/Textfield/Textfield.d.ts +9 -0
  12. package/lib/cjs/components/Textfield/types.d.ts +52 -0
  13. package/lib/cjs/components/Tooltip/Tooltip.d.ts +4 -0
  14. package/lib/cjs/components/Tooltip/types.d.ts +6 -0
  15. package/lib/cjs/index.d.ts +7 -3
  16. package/lib/cjs/index.js +881 -236
  17. package/lib/cjs/index.js.map +1 -1
  18. package/lib/esm/components/Btn/types.d.ts +4 -4
  19. package/lib/esm/components/Confirm/Confirm.d.ts +4 -0
  20. package/lib/esm/components/Confirm/types.d.ts +17 -0
  21. package/lib/esm/components/Fieldset/Fieldset.d.ts +4 -0
  22. package/lib/esm/components/Fieldset/types.d.ts +13 -0
  23. package/lib/esm/components/Listbox/Listbox.d.ts +6 -0
  24. package/lib/esm/components/Listbox/types.d.ts +29 -0
  25. package/lib/esm/components/Modal/Modal.d.ts +5 -2
  26. package/lib/esm/components/Modal/types.d.ts +33 -4
  27. package/lib/esm/components/Panel/types.d.ts +3 -3
  28. package/lib/esm/components/Textfield/Textfield.d.ts +9 -0
  29. package/lib/esm/components/Textfield/types.d.ts +52 -0
  30. package/lib/esm/components/Tooltip/Tooltip.d.ts +4 -0
  31. package/lib/esm/components/Tooltip/types.d.ts +6 -0
  32. package/lib/esm/index.d.ts +7 -3
  33. package/lib/esm/index.js +871 -237
  34. package/lib/esm/index.js.map +1 -1
  35. package/package.json +1 -3
@@ -1,6 +1,6 @@
1
1
  import React from 'react';
2
2
  interface IBtn {
3
- children: React.ReactNode;
3
+ children?: React.ReactNode;
4
4
  type?: "button" | "submit" | "reset" | undefined;
5
5
  htmlTag?: string;
6
6
  onClick?: any;
@@ -18,9 +18,9 @@ interface IBtn {
18
18
  light?: boolean;
19
19
  isActive?: boolean;
20
20
  isLoading?: boolean;
21
- size?: string;
22
- horizontalSize?: string;
23
- fontSize?: string;
21
+ size?: 'xxs' | 'xs' | 's' | 'm' | 'l' | 'xl' | 'xxl';
22
+ horizontalSize?: 'xs' | 's' | 'm' | 'l';
23
+ fontSize?: 'l' | 'm';
24
24
  fullWidth?: boolean;
25
25
  fullHeight?: boolean;
26
26
  icon?: string;
@@ -0,0 +1,4 @@
1
+ /// <reference types="react" />
2
+ import { IConfirm } from './types';
3
+ declare function Confirm({ children, title, text, isOpen, onClose, confirmCallback, cancelCallback, confirmText, cancelText, confirmColor, confirmInput, confirmInputLabel, width }: IConfirm): JSX.Element;
4
+ export { Confirm };
@@ -0,0 +1,17 @@
1
+ import React from "react";
2
+ interface IConfirm {
3
+ children?: React.ReactNode;
4
+ title?: React.ReactNode | string;
5
+ text?: React.ReactNode | string;
6
+ isOpen: boolean;
7
+ onClose?: () => any;
8
+ confirmCallback?: () => any;
9
+ cancelCallback?: () => any;
10
+ confirmText?: string;
11
+ cancelText?: string;
12
+ confirmColor?: 'primary' | 'secondary' | 'alert' | 'warning' | 'success' | 'black';
13
+ confirmInput?: string;
14
+ confirmInputLabel?: React.ReactNode | string;
15
+ width?: number;
16
+ }
17
+ export { IConfirm };
@@ -0,0 +1,4 @@
1
+ /// <reference types="react" />
2
+ import { IFieldset } from './types';
3
+ declare function Fieldset({ children, label, description, labelClassName, blockClassName, tooltip, tooltipHTML, inputID, append }: IFieldset): JSX.Element;
4
+ export { Fieldset };
@@ -0,0 +1,13 @@
1
+ import React from "react";
2
+ interface IFieldset {
3
+ children: React.ReactNode;
4
+ label: React.ReactNode | string;
5
+ description?: React.ReactNode | string;
6
+ labelClassName?: string;
7
+ blockClassName?: string;
8
+ tooltip?: string;
9
+ tooltipHTML?: any;
10
+ inputID?: string | number;
11
+ append?: React.ReactNode;
12
+ }
13
+ export { IFieldset };
@@ -0,0 +1,6 @@
1
+ /// <reference types="react" />
2
+ import { IListbox, IListboxItem } from './types';
3
+ declare function Listbox({ children, hasBorder, className }: IListbox): JSX.Element;
4
+ declare function ListboxItem({ children, message, description, imageUrl, tooltip, tooltipHTML, onClick, onMouseEnter, href, target, rel, selected, hasSelectedIcon, hasCheckbox, disabled, size, className, icon, iconCustom, capitalize }: IListboxItem): JSX.Element;
5
+ declare function ListboxSep(): JSX.Element;
6
+ export { Listbox, ListboxItem, ListboxSep };
@@ -0,0 +1,29 @@
1
+ import React from 'react';
2
+ interface IListbox {
3
+ children: React.ReactNode;
4
+ hasBorder?: boolean;
5
+ className?: string;
6
+ }
7
+ interface IListboxItem {
8
+ children?: React.ReactNode;
9
+ message?: React.ReactNode | string;
10
+ description?: React.ReactNode | string;
11
+ imageUrl?: string;
12
+ tooltip?: string | null;
13
+ tooltipHTML?: any;
14
+ onClick?: any;
15
+ onMouseEnter?: any;
16
+ href?: string;
17
+ target?: string;
18
+ rel?: string;
19
+ selected?: boolean;
20
+ hasSelectedIcon?: boolean;
21
+ hasCheckbox?: boolean;
22
+ disabled?: boolean;
23
+ capitalize?: boolean;
24
+ size?: 'm' | 'l' | 'xl';
25
+ className?: string;
26
+ icon?: string;
27
+ iconCustom?: React.ReactNode;
28
+ }
29
+ export { IListbox, IListboxItem };
@@ -1,4 +1,7 @@
1
1
  /// <reference types="react" />
2
- import { IModal } from './types';
2
+ import { IModal, IModalHeader, IModalBody, IModalFooter } from './types';
3
3
  declare function Modal({ children, isOpen, onClose, noClose, width, height, minHeight, fullScreen, animation }: IModal): JSX.Element;
4
- export default Modal;
4
+ declare function ModalHeader({ children, className, title, intro, desc, hasBorder, hasBottomPadding }: IModalHeader): JSX.Element;
5
+ declare function ModalBody({ children, className, style, backgroundColor, position, hasVerticalPadding, hasHorizontalPadding }: IModalBody): JSX.Element;
6
+ declare function ModalFooter({ children, className, align, primaryAction, secondaryAction, hasBorder, }: IModalFooter): JSX.Element;
7
+ export { Modal, ModalHeader, ModalBody, ModalFooter };
@@ -4,10 +4,39 @@ interface IModal {
4
4
  isOpen: boolean;
5
5
  onClose?: (e: any) => any;
6
6
  noClose?: boolean;
7
- width?: string;
8
- height?: string;
9
- minHeight?: string;
7
+ width?: number;
8
+ height?: number;
9
+ minHeight?: number;
10
10
  fullScreen?: boolean;
11
11
  animation?: string;
12
12
  }
13
- export { IModal };
13
+ interface IModalHeader {
14
+ children?: React.ReactNode;
15
+ className?: string;
16
+ title?: React.ReactNode | string;
17
+ intro?: React.ReactNode | string;
18
+ desc?: React.ReactNode | string;
19
+ hasBorder?: boolean;
20
+ hasBottomPadding?: boolean;
21
+ }
22
+ interface IModalBody {
23
+ children?: React.ReactNode;
24
+ className?: string;
25
+ style?: object;
26
+ backgroundColor?: 'grey' | 'white';
27
+ position?: 'static' | 'relative';
28
+ hasVerticalPadding?: boolean;
29
+ hasHorizontalPadding?: boolean;
30
+ }
31
+ interface IModalFooter {
32
+ children?: React.ReactNode;
33
+ className?: string;
34
+ align?: 'left' | 'right';
35
+ primaryAction?: React.ReactNode;
36
+ secondaryAction?: React.ReactNode;
37
+ hasBorder?: boolean;
38
+ }
39
+ interface IModalClose {
40
+ onClick?: (e: any) => any;
41
+ }
42
+ export { IModal, IModalHeader, IModalBody, IModalFooter, IModalClose };
@@ -18,9 +18,9 @@ interface IPanelClose {
18
18
  interface IPanelHeader {
19
19
  children?: React.ReactNode;
20
20
  className?: string;
21
- title?: string;
22
- intro?: string;
23
- desc?: string;
21
+ title?: React.ReactNode | string;
22
+ intro?: React.ReactNode | string;
23
+ desc?: React.ReactNode | string;
24
24
  hasClose?: boolean;
25
25
  hasBorder?: boolean;
26
26
  hasBottomPadding?: boolean;
@@ -0,0 +1,9 @@
1
+ /// <reference types="react" />
2
+ import { ITextfield, ITextfieldIcon } from './types';
3
+ declare function Textfield({ value, name, type, placeholder, rows, // For textarea
4
+ min, max, onChange, onEnter, onFocus, onBlur, disabled, readonly, clearable, selectOnFocus, autoFocus, autoComplete, forceFocus, spellCheck, autogrow, // Vertical for textarea, Horizontal for text
5
+ label, labelTooltip, labelTooltipHTML, description, descriptionBottom, errorMessage, unit, append, prepend, icon, iconPosition, className, labelClassName, blockClassName, size, horizontalSize, color, style, doBtnHug, textAlign, fullWidth, width, // 'Full' || 'xl' || 'l' || 's' || 'xs' || 'xxs'
6
+ maxHeight, // For textarea autogrow
7
+ maxWidth, }: ITextfield): JSX.Element;
8
+ declare function TextfieldIcon({ icon, position }: ITextfieldIcon): JSX.Element;
9
+ export { Textfield, TextfieldIcon };
@@ -0,0 +1,52 @@
1
+ import React from "react";
2
+ interface ITextfield {
3
+ value?: string | number;
4
+ name?: string;
5
+ type?: string;
6
+ placeholder?: string;
7
+ rows?: number;
8
+ min?: number;
9
+ max?: number;
10
+ onChange?: any;
11
+ onEnter?: any;
12
+ onFocus?: any;
13
+ onBlur?: any;
14
+ disabled?: boolean;
15
+ readonly?: boolean;
16
+ clearable?: boolean;
17
+ selectOnFocus?: boolean;
18
+ autoFocus?: boolean;
19
+ autoComplete?: boolean;
20
+ forceFocus?: boolean;
21
+ spellCheck?: boolean;
22
+ autogrow?: boolean;
23
+ label?: React.ReactNode | string;
24
+ labelTooltip?: string;
25
+ labelTooltipHTML?: any;
26
+ description?: React.ReactNode | string;
27
+ descriptionBottom?: React.ReactNode | string;
28
+ errorMessage?: React.ReactNode | string;
29
+ unit?: string;
30
+ append?: React.ReactNode;
31
+ prepend?: React.ReactNode;
32
+ icon?: string;
33
+ iconPosition?: 'before' | 'after';
34
+ className?: string;
35
+ labelClassName?: string;
36
+ blockClassName?: string;
37
+ size?: 'xs' | 's' | 'm' | 'l' | 'xl' | 'xxl';
38
+ horizontalSize?: 'm' | 's';
39
+ color?: 'white' | 'grey';
40
+ style?: 'ghost' | 'ghost_underline' | 'highlighted';
41
+ doBtnHug?: boolean;
42
+ textAlign?: 'left' | 'center' | 'right';
43
+ fullWidth?: boolean;
44
+ width?: 'auto' | 'full' | 'xl' | 'l' | 's' | 'xs' | 'xxs';
45
+ maxHeight?: number;
46
+ maxWidth?: number;
47
+ }
48
+ interface ITextfieldIcon {
49
+ icon?: string;
50
+ position?: 'before' | 'after';
51
+ }
52
+ export { ITextfield, ITextfieldIcon };
@@ -0,0 +1,4 @@
1
+ /// <reference types="react" />
2
+ import { ITooltip } from './types';
3
+ declare function Tooltip({ text, html, id }: ITooltip): JSX.Element;
4
+ export { Tooltip };
@@ -0,0 +1,6 @@
1
+ interface ITooltip {
2
+ text?: string | null;
3
+ html?: any;
4
+ id?: string;
5
+ }
6
+ export { ITooltip };
@@ -3,16 +3,20 @@ import { Article } from './components/Article/Article';
3
3
  import { Btn } from './components/Btn/Btn';
4
4
  import { Checkbox, Radio, Switch, CheckboxList } from './components/Checkbox/Checkbox';
5
5
  import Collapse from './components/Collapse/Collapse';
6
+ import { Confirm } from './components/Confirm/Confirm';
7
+ import { Dropdown } from './components/Dropdown/Dropdown';
8
+ import { Fieldset } from './components/Fieldset/Fieldset';
6
9
  import { IconBtn } from './components/IconBtn/IconBtn';
7
10
  import { List, ListItem } from './components/List/List';
11
+ import { Listbox, ListboxItem, ListboxSep } from './components/Listbox/Listbox';
8
12
  import { Mask } from './components/Mask/Mask';
9
- import Modal from './components/Modal/Modal';
13
+ import { Modal, ModalHeader, ModalBody, ModalFooter } from './components/Modal/Modal';
10
14
  import { Panel, PanelClose, PanelHeader, PanelBody } from './components/Panel/Panel';
11
15
  import { Picto } from './components/Picto/Picto';
12
16
  import { Portal } from './components/Portal/Portal';
13
17
  import { Section } from './components/Section/Section';
14
18
  import { Spinner } from './components/Spinner/Spinner';
19
+ import { Textfield, TextfieldIcon } from './components/Textfield/Textfield';
15
20
  declare const Theme: any;
16
21
  export { Theme, AppRoot, AppHeader, AppLinkWrapper, AppLogo, Article, Btn, Checkbox, CheckboxList, Collapse, // Not OK
17
- IconBtn, List, ListItem, Mask, Modal, // Not OK
18
- Panel, PanelClose, PanelHeader, PanelBody, Picto, Portal, Radio, Section, Spinner, Switch, };
22
+ Confirm, Dropdown, Fieldset, IconBtn, List, ListItem, Listbox, ListboxItem, ListboxSep, Mask, Modal, ModalHeader, ModalBody, ModalFooter, Panel, PanelClose, PanelHeader, PanelBody, Picto, Portal, Radio, Section, Spinner, Switch, Textfield, TextfieldIcon };