@integrigo/integrigo-ui 1.6.1 → 1.6.4

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 (39) hide show
  1. package/.eslintignore +3 -0
  2. package/.eslintrc +59 -0
  3. package/jest.config.js +1 -1
  4. package/jest.setup.ts +1 -1
  5. package/lib/components/atoms/Avatar/Avatar.d.ts +8 -0
  6. package/lib/components/atoms/Avatar/Avatar.test.d.ts +1 -0
  7. package/lib/components/atoms/Avatar/index.d.ts +1 -0
  8. package/lib/components/atoms/Divider/Divider.d.ts +5 -0
  9. package/lib/components/atoms/Divider/index.d.ts +1 -0
  10. package/lib/components/atoms/Icon/Icon.d.ts +6 -0
  11. package/lib/components/atoms/Icon/icons/ChechSquare.d.ts +3 -0
  12. package/lib/components/atoms/Icon/icons/ClipboardNotes.d.ts +3 -0
  13. package/lib/components/atoms/Icon/icons/DiceFive.d.ts +3 -0
  14. package/lib/components/atoms/Icon/icons/Home.d.ts +3 -0
  15. package/lib/components/atoms/Icon/icons/Setting.d.ts +3 -0
  16. package/lib/components/atoms/Icon/icons/Users.d.ts +3 -0
  17. package/lib/components/atoms/Pill/Pill.d.ts +1 -2
  18. package/lib/components/atoms/index.d.ts +2 -0
  19. package/lib/components/molecules/Button/BasicButton.d.ts +1 -0
  20. package/lib/components/molecules/Button/Button.d.ts +1 -0
  21. package/lib/components/molecules/Button/Button.test.d.ts +1 -0
  22. package/lib/components/molecules/Button/Ghost.d.ts +1 -0
  23. package/lib/components/molecules/Button/Primary.d.ts +1 -0
  24. package/lib/components/molecules/Input/Input.d.ts +1 -1
  25. package/lib/components/molecules/Profile/Profile.d.ts +8 -0
  26. package/lib/components/molecules/Profile/Profile.test.d.ts +1 -0
  27. package/lib/components/molecules/Profile/index.d.ts +1 -0
  28. package/lib/components/molecules/index.d.ts +1 -0
  29. package/lib/components/organisms/Menu/Menu.d.ts +12 -0
  30. package/lib/components/organisms/Menu/MenuItem.d.ts +9 -0
  31. package/lib/components/organisms/Menu/index.d.ts +1 -0
  32. package/lib/components/organisms/index.d.ts +1 -0
  33. package/lib/index.d.ts +3 -2
  34. package/lib/index.esm.js +1 -1
  35. package/lib/index.esm.js.map +1 -1
  36. package/lib/index.js +1 -1
  37. package/lib/index.js.map +1 -1
  38. package/lib/jest.setup.d.ts +1 -0
  39. package/package.json +22 -9
package/.eslintignore ADDED
@@ -0,0 +1,3 @@
1
+ node_modules
2
+ lib
3
+ !.storybook
package/.eslintrc ADDED
@@ -0,0 +1,59 @@
1
+
2
+ {
3
+ "env": {
4
+ "browser": true,
5
+ "node": true,
6
+ "jest/globals": true,
7
+ "es6": true
8
+ },
9
+ "root": true,
10
+ "parser": "@typescript-eslint/parser",
11
+ "plugins": [
12
+ "jest",
13
+ "react",
14
+ "react-hooks",
15
+ "@typescript-eslint",
16
+ "import"
17
+ ],
18
+ "extends": [
19
+ "airbnb-typescript",
20
+ "plugin:jest/recommended",
21
+ "plugin:react/recommended",
22
+ "plugin:react-hooks/recommended",
23
+ "plugin:@typescript-eslint/recommended",
24
+ "plugin:storybook/recommended",
25
+ "plugin:import/recommended"
26
+ ],
27
+ "parserOptions": {
28
+ "project": "./tsconfig.json"
29
+ },
30
+ "overrides": [
31
+ {
32
+ "files": ["**/*.tsx", "**/*.ts"],
33
+ "rules": {
34
+ "react/require-default-props": "off",
35
+ "react/prop-types": "off", // we should use types
36
+ "react/forbid-prop-types": "off" // we should use types
37
+ }
38
+ },
39
+ {
40
+ "files": ["**/*.d.ts"],
41
+ "rules": {
42
+ "vars-on-top": "off",
43
+ "no-var": "off", // this is how typescript works
44
+ "spaced-comment": "off"
45
+ }
46
+ }
47
+ ],
48
+ "rules": {
49
+ "react/jsx-props-no-spreading": "off",
50
+ "@typescript-eslint/no-use-before-define": "off",
51
+ "import/prefer-default-export": "off",
52
+ "import/no-extraneous-dependencies": [
53
+ "error",
54
+ {
55
+ "devDependencies": true
56
+ }
57
+ ]
58
+ }
59
+ }
package/jest.config.js CHANGED
@@ -19,6 +19,6 @@ module.exports = {
19
19
  },
20
20
  testEnvironment: 'jsdom',
21
21
  setupFilesAfterEnv: [
22
- './jest.setup.ts'
22
+ './jest.setup'
23
23
  ]
24
24
  }
package/jest.setup.ts CHANGED
@@ -1 +1 @@
1
- import '@testing-library/jest-dom'
1
+ import '@testing-library/jest-dom';
@@ -0,0 +1,8 @@
1
+ import React from "react";
2
+ declare type AvatarProps = {
3
+ src: string;
4
+ alt: string;
5
+ size?: "s" | "m" | "l" | "xl" | "xxl";
6
+ };
7
+ export declare const Avatar: React.FC<AvatarProps>;
8
+ export {};
@@ -0,0 +1 @@
1
+ export {};
@@ -0,0 +1 @@
1
+ export { Avatar } from './Avatar';
@@ -0,0 +1,5 @@
1
+ declare type DividerProps = {
2
+ variant?: "orange" | "navy" | "white";
3
+ };
4
+ export declare const Divider: import("styled-components").StyledComponent<"div", any, DividerProps, never>;
5
+ export {};
@@ -0,0 +1 @@
1
+ export { Divider } from "./Divider";
@@ -3,11 +3,15 @@ export declare const iconHashMap: {
3
3
  "angle-down": React.FCS<{}>;
4
4
  bars: React.FCS<{}>;
5
5
  "check-circle": React.FCS<{}>;
6
+ "check-square": React.FCS<{}>;
7
+ "clipboad-notes": React.FCS<{}>;
6
8
  close: React.FCS<{}>;
9
+ "dice-five": React.FCS<{}>;
7
10
  envelope: React.FCS<{}>;
8
11
  "exclamation-circle": React.FCS<{}>;
9
12
  "exclamation-triangle": React.FCS<{}>;
10
13
  facebook: React.FCS<{}>;
14
+ home: React.FCS<{}>;
11
15
  instagram: React.FCS<{}>;
12
16
  linkedin: React.FCS<{}>;
13
17
  minus: React.FCS<{}>;
@@ -15,7 +19,9 @@ export declare const iconHashMap: {
15
19
  plus: React.FCS<{}>;
16
20
  process: React.FCS<{}>;
17
21
  redo: React.FCS<{}>;
22
+ setting: React.FCS<{}>;
18
23
  "user-circle": React.FCS<{}>;
24
+ users: React.FCS<{}>;
19
25
  };
20
26
  export declare type IconType = keyof typeof iconHashMap;
21
27
  declare type IconProps = React.SVGProps<SVGSVGElement> & {
@@ -0,0 +1,3 @@
1
+ import React from "react";
2
+ declare const CheckSquare: React.FCS;
3
+ export default CheckSquare;
@@ -0,0 +1,3 @@
1
+ import React from "react";
2
+ declare const ClipboardNotes: React.FCS;
3
+ export default ClipboardNotes;
@@ -0,0 +1,3 @@
1
+ import React from "react";
2
+ declare const DiceFive: React.FCS;
3
+ export default DiceFive;
@@ -0,0 +1,3 @@
1
+ import React from "react";
2
+ declare const Home: React.FCS;
3
+ export default Home;
@@ -0,0 +1,3 @@
1
+ import React from "react";
2
+ declare const Setting: React.FCS;
3
+ export default Setting;
@@ -0,0 +1,3 @@
1
+ import React from "react";
2
+ declare const Users: React.FCS;
3
+ export default Users;
@@ -1,5 +1,4 @@
1
- interface PillProps {
1
+ export interface PillProps {
2
2
  variant: 'orange' | 'green' | 'red';
3
3
  }
4
4
  export declare const Pill: import("styled-components").StyledComponent<"div", any, PillProps, never>;
5
- export {};
@@ -1,5 +1,7 @@
1
1
  export { Alert } from './Alert';
2
+ export { Avatar } from './Avatar';
2
3
  export { Card } from './Card';
4
+ export { Divider } from './Divider';
3
5
  export { Icon } from './Icon';
4
6
  export { Pill } from './Pill';
5
7
  export { Typography } from './Typography';
@@ -30,5 +30,6 @@ export declare const BasicButton: import("styled-components").StyledComponent<"d
30
30
  direction?: "rtl" | "ltr" | undefined;
31
31
  ghost?: boolean | undefined;
32
32
  disabled?: boolean | undefined;
33
+ loading?: boolean | undefined;
33
34
  sizeVariant: "xl" | "l" | "m" | "s";
34
35
  }, never>;
@@ -6,6 +6,7 @@ export interface ButtonProps extends React.ButtonHTMLAttributes<HTMLButtonElemen
6
6
  icon?: IconType;
7
7
  direction?: "rtl" | "ltr";
8
8
  size?: "xl" | "l" | "m" | "s";
9
+ loading?: boolean;
9
10
  onIconClick?: () => void;
10
11
  }
11
12
  export declare const Button: React.ForwardRefExoticComponent<ButtonProps & React.RefAttributes<HTMLButtonElement>>;
@@ -0,0 +1 @@
1
+ export {};
@@ -8,6 +8,7 @@ export declare const Ghost: import("styled-components").StyledComponent<"div", a
8
8
  direction?: "ltr" | "rtl" | undefined;
9
9
  ghost?: boolean | undefined;
10
10
  disabled?: boolean | undefined;
11
+ loading?: boolean | undefined;
11
12
  sizeVariant: "s" | "xl" | "l" | "m";
12
13
  } & {
13
14
  direction?: "ltr" | "rtl" | undefined;
@@ -2,5 +2,6 @@ export declare const Primary: import("styled-components").StyledComponent<"div",
2
2
  direction?: "ltr" | "rtl" | undefined;
3
3
  ghost?: boolean | undefined;
4
4
  disabled?: boolean | undefined;
5
+ loading?: boolean | undefined;
5
6
  sizeVariant: "s" | "xl" | "l" | "m";
6
7
  }, never>;
@@ -13,7 +13,7 @@ export declare type InputProps = Omit<React.InputHTMLAttributes<HTMLInputElement
13
13
  export declare const Input: React.ForwardRefExoticComponent<Omit<React.InputHTMLAttributes<HTMLInputElement>, "size"> & FieldProps<any, any> & {
14
14
  label?: string | undefined;
15
15
  validationType?: ValidationType | undefined;
16
- icon?: "angle-down" | "bars" | "check-circle" | "close" | "envelope" | "exclamation-circle" | "exclamation-triangle" | "facebook" | "instagram" | "linkedin" | "minus" | "phone" | "plus" | "process" | "redo" | "user-circle" | undefined;
16
+ icon?: "angle-down" | "bars" | "check-circle" | "check-square" | "clipboad-notes" | "close" | "dice-five" | "envelope" | "exclamation-circle" | "exclamation-triangle" | "facebook" | "home" | "instagram" | "linkedin" | "minus" | "phone" | "plus" | "process" | "redo" | "setting" | "user-circle" | "users" | undefined;
17
17
  size?: "xl" | "l" | "m" | "s" | undefined;
18
18
  direction?: "ltr" | "rtl" | undefined;
19
19
  onIconClick?: (() => void) | undefined;
@@ -0,0 +1,8 @@
1
+ import React from "react";
2
+ import { Avatar } from "../../atoms";
3
+ declare type ProfileProps = React.ComponentProps<typeof Avatar> & {
4
+ name: string;
5
+ children?: React.ReactNode;
6
+ };
7
+ export declare const Profile: React.FC<ProfileProps>;
8
+ export {};
@@ -0,0 +1 @@
1
+ export {};
@@ -0,0 +1 @@
1
+ export { Profile } from './Profile';
@@ -5,3 +5,4 @@ export { Button } from "./Button";
5
5
  export { Checkbox } from "./Checkbox";
6
6
  export { Dropdown } from "./Dropdown";
7
7
  export { Radio } from "./Radio";
8
+ export { Profile } from "./Profile";
@@ -0,0 +1,12 @@
1
+ import React from 'react';
2
+ import { MenuItem } from './MenuItem';
3
+ export interface MenuStaticProps {
4
+ Item: typeof MenuItem;
5
+ }
6
+ export interface MenuProps {
7
+ children: React.ReactNode;
8
+ }
9
+ declare const MenuWithStatic: React.FC<MenuProps> & {
10
+ Item: React.FC<import("./MenuItem").MenuItemProps>;
11
+ };
12
+ export { MenuWithStatic as Menu };
@@ -0,0 +1,9 @@
1
+ import React from "react";
2
+ import { IconType } from "../../atoms/Icon";
3
+ export interface MenuItemProps {
4
+ active?: boolean;
5
+ label: string;
6
+ icon: IconType;
7
+ }
8
+ export declare const MenuItem: React.FC<MenuItemProps>;
9
+ export declare const Root: import("styled-components").StyledComponent<"div", any, Pick<MenuItemProps, "active">, never>;
@@ -0,0 +1 @@
1
+ export { Menu } from './Menu';
@@ -0,0 +1 @@
1
+ export { Menu } from './Menu';
package/lib/index.d.ts CHANGED
@@ -1,3 +1,4 @@
1
- export { Alert, Card, Icon, Nav, Pill, Typography, Spinner, } from "./components/atoms";
2
- export { InfoCard, Input, TextArea, Button, Checkbox, Dropdown, Radio } from "./components/molecules";
1
+ export { Alert, Avatar, Card, Divider, Icon, Nav, Pill, Typography, Spinner, } from "./components/atoms";
2
+ export { InfoCard, Input, TextArea, Button, Checkbox, Dropdown, Profile, Radio, } from "./components/molecules";
3
+ export { Menu } from "./components/organisms";
3
4
  export { GlobalStyles as IntegrigoUI, Color } from "./styles";