@omniumretail/shared-resources 0.0.1

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 (77) hide show
  1. package/.eslintrc.json +32 -0
  2. package/README.md +45 -0
  3. package/dist/bundle.js +5496 -0
  4. package/dist/types/components/BottomDrawer/index.d.ts +2 -0
  5. package/dist/types/components/Button/index.d.ts +6 -0
  6. package/dist/types/components/Footer/index.d.ts +3 -0
  7. package/dist/types/components/Form/FormInputField/index.d.ts +8 -0
  8. package/dist/types/components/Form/FormSelectField/index.d.ts +9 -0
  9. package/dist/types/components/Form/index.d.ts +2 -0
  10. package/dist/types/components/Header/index.d.ts +4 -0
  11. package/dist/types/components/Link/index.d.ts +6 -0
  12. package/dist/types/components/Navigation/index.d.ts +8 -0
  13. package/dist/types/components/Page/index.d.ts +13 -0
  14. package/dist/types/components/SharedContextProvider/index.d.ts +7 -0
  15. package/dist/types/components/index.d.ts +9 -0
  16. package/dist/types/constants/Icons.d.ts +13 -0
  17. package/dist/types/constants/QueryClient.d.ts +2 -0
  18. package/dist/types/constants/index.d.ts +2 -0
  19. package/dist/types/contexts/useStore.d.ts +8 -0
  20. package/dist/types/hooks/index.d.ts +2 -0
  21. package/dist/types/hooks/useApplicationDataQuery.hook.d.ts +2 -0
  22. package/dist/types/hooks/useStoreQuery.d.ts +7 -0
  23. package/dist/types/index.d.ts +7 -0
  24. package/dist/types/interfaces/ApplicationsByCategory.d.ts +16 -0
  25. package/dist/types/interfaces/Configuration.d.ts +6 -0
  26. package/dist/types/interfaces/Customer.d.ts +21 -0
  27. package/dist/types/interfaces/Product.d.ts +33 -0
  28. package/dist/types/interfaces/ResponseList.d.ts +5 -0
  29. package/dist/types/interfaces/Store.d.ts +7 -0
  30. package/dist/types/interfaces/index.d.ts +6 -0
  31. package/dist/types/services/ApiService/index.d.ts +5 -0
  32. package/dist/types/services/InitService/index.d.ts +3 -0
  33. package/dist/types/services/index.d.ts +2 -0
  34. package/package.json +54 -0
  35. package/src/assets/omniu-retail_branco_s-fundo.png +0 -0
  36. package/src/assets/sitoo.svg +9 -0
  37. package/src/components/BottomDrawer/index.tsx +8 -0
  38. package/src/components/BottomDrawer/styles.module.scss +37 -0
  39. package/src/components/Button/index.tsx +22 -0
  40. package/src/components/Button/styles.module.scss +67 -0
  41. package/src/components/Footer/index.tsx +44 -0
  42. package/src/components/Footer/styles.module.scss +33 -0
  43. package/src/components/Form/FormInputField/index.tsx +18 -0
  44. package/src/components/Form/FormSelectField/index.tsx +16 -0
  45. package/src/components/Form/index.ts +2 -0
  46. package/src/components/Header/index.tsx +20 -0
  47. package/src/components/Header/styles.module.scss +16 -0
  48. package/src/components/Link/index.tsx +21 -0
  49. package/src/components/Link/styles.module.scss +24 -0
  50. package/src/components/Navigation/index.tsx +30 -0
  51. package/src/components/Navigation/styles.module.scss +34 -0
  52. package/src/components/Page/index.tsx +35 -0
  53. package/src/components/Page/styles.module.scss +26 -0
  54. package/src/components/SharedContextProvider/index.tsx +30 -0
  55. package/src/components/index.ts +9 -0
  56. package/src/constants/Icons.ts +19 -0
  57. package/src/constants/QueryClient.ts +3 -0
  58. package/src/constants/index.ts +2 -0
  59. package/src/contexts/useStore.tsx +20 -0
  60. package/src/global.scss +124 -0
  61. package/src/hooks/index.ts +2 -0
  62. package/src/hooks/useApplicationDataQuery.hook.ts +10 -0
  63. package/src/hooks/useStoreQuery.ts +13 -0
  64. package/src/index.ts +9 -0
  65. package/src/interfaces/ApplicationsByCategory.ts +19 -0
  66. package/src/interfaces/Configuration.ts +7 -0
  67. package/src/interfaces/Customer.ts +23 -0
  68. package/src/interfaces/Product.ts +36 -0
  69. package/src/interfaces/ResponseList.ts +6 -0
  70. package/src/interfaces/Store.ts +8 -0
  71. package/src/interfaces/index.ts +6 -0
  72. package/src/services/ApiService/index.ts +80 -0
  73. package/src/services/InitService/index.ts +7 -0
  74. package/src/services/index.ts +3 -0
  75. package/src/types/Global.d.ts +4 -0
  76. package/tsconfig.json +26 -0
  77. package/webpack.config.js +48 -0
@@ -0,0 +1,16 @@
1
+ import { Form, FormItemProps, Select } from 'antd';
2
+ import { LabeledValue, SelectProps } from 'antd/lib/select';
3
+
4
+ interface FormSelectFieldProps extends Omit<FormItemProps, "name"> {
5
+ name: string;
6
+ options: LabeledValue[];
7
+ selectProps?: SelectProps<LabeledValue>
8
+ }
9
+
10
+ export const FormSelectField = ({ options, selectProps, ...itemProps }: FormSelectFieldProps) => {
11
+ return (
12
+ <Form.Item { ...itemProps }>
13
+ <Select { ...selectProps } options={ options } />
14
+ </Form.Item>
15
+ )
16
+ };
@@ -0,0 +1,2 @@
1
+ export * from './FormInputField';
2
+ export * from './FormSelectField';
@@ -0,0 +1,20 @@
1
+ import { FontAwesomeIcon } from '@fortawesome/react-fontawesome'
2
+ import { icons, } from '../../constants/Icons';
3
+ import sitooIcon from '../../assets/sitoo.svg';
4
+ import styles from './styles.module.scss';
5
+
6
+ export interface HeaderProps {
7
+ onOpenMenu: () => void;
8
+ }
9
+
10
+ export const Header = ({ onOpenMenu }: HeaderProps) => (
11
+ <div className={ styles.header }>
12
+ <FontAwesomeIcon icon={ icons.faBars } onClick={ onOpenMenu } />
13
+
14
+ <div className={ styles.logoContainer }>
15
+ <img src={ sitooIcon } />
16
+ </div>
17
+
18
+ <FontAwesomeIcon icon={ icons.faUserTie } />
19
+ </div>
20
+ );
@@ -0,0 +1,16 @@
1
+
2
+ .header {
3
+ height: 88px;
4
+ display: flex;
5
+ align-items: flex-end;
6
+ padding: 13px 20px;
7
+ border-bottom: 2px solid #E5E5E5;
8
+ box-sizing: border-box;
9
+ }
10
+
11
+ .logoContainer {
12
+ display: flex;
13
+ flex-grow: 1;
14
+ align-items: flex-end;
15
+ justify-content: center;
16
+ }
@@ -0,0 +1,21 @@
1
+ import { Button as AntButton, ButtonProps } from 'antd';
2
+ import styles from './styles.module.scss';
3
+ import classNames from 'classnames';
4
+
5
+ export interface CustomLinkProps extends ButtonProps {
6
+ iconAlignRight?: boolean;
7
+ linkSecondary?: boolean;
8
+ }
9
+
10
+ export const Link = (props: CustomLinkProps) => {
11
+ const { iconAlignRight, linkSecondary } = props;
12
+
13
+ const linkClasses = classNames({
14
+ [styles.iconAlignRight]: iconAlignRight,
15
+ [styles.linkSecondary]: linkSecondary,
16
+ }, [styles.link])
17
+
18
+ return (
19
+ <AntButton { ...props } className={ linkClasses } type={'link'} />
20
+ );
21
+ };
@@ -0,0 +1,24 @@
1
+ .link {
2
+ display: inline-flex;
3
+ text-decoration: none;
4
+ height: auto;
5
+
6
+ color: var(--color-black);
7
+ font-size: var(--font-size-body-3);
8
+ line-height: 100%;
9
+ font-weight: 300;
10
+ font-style: var(--font-style-italic);
11
+ }
12
+
13
+ .linkSecondary {
14
+ color: var(--color-orange);
15
+ font-style: var(--font-style-normal);
16
+ }
17
+
18
+ .iconAlignRight {
19
+ span:nth-child(2) {
20
+ margin-inline-end: 8px;
21
+ margin-inline-start: 0;
22
+ order: -1;
23
+ }
24
+ }
@@ -0,0 +1,30 @@
1
+ import styles from './styles.module.scss';
2
+ import { Link } from '../Link/index';
3
+ import { ArrowLeftOutlined, HomeOutlined, LogoutOutlined } from '@ant-design/icons';
4
+
5
+ export interface NavigationProps {
6
+ backLink?: boolean;
7
+ title: string;
8
+ homeLink?: boolean;
9
+ loginLink?: boolean;
10
+ onClickFunction?: () => void;
11
+ }
12
+
13
+ export const Navigation = (props: NavigationProps) => {
14
+ const { backLink, title, homeLink, onClickFunction, loginLink } = props;
15
+
16
+ return (
17
+ <div className={styles.navigation}>
18
+ <div className={styles.columnLeft}>
19
+ { backLink && <Link href="#" icon={<ArrowLeftOutlined />} linkSecondary> Voltar </Link> }
20
+ </div>
21
+ <div className={styles.columnCenter}>
22
+ <h1 className={styles.title}>{title}</h1>
23
+ </div>
24
+ <div className={styles.columnRight}>
25
+ {homeLink && <Link href="" icon={<HomeOutlined />} linkSecondary iconAlignRight> Home </Link>}
26
+ {loginLink && <Link href="#" onClick={onClickFunction} icon={<LogoutOutlined />} linkSecondary iconAlignRight> Log Out</Link>}
27
+ </div>
28
+ </div>
29
+ )
30
+ };
@@ -0,0 +1,34 @@
1
+ .navigation {
2
+ display: flex;
3
+ align-items: center;
4
+ justify-content: space-between;
5
+ padding: 0 24px;
6
+ height: 75px;
7
+ gap: 0 24px;
8
+ position: relative;
9
+
10
+ @media(max-width: 767px) {
11
+ padding-top: 32px;
12
+ }
13
+
14
+ @media(min-width: 767px) {
15
+ padding: 0 40px;
16
+ }
17
+
18
+ .title {
19
+ font-size: var(--font-size-body-4);
20
+ font-weight: var(--font-weight-semibold);
21
+ text-transform: uppercase;
22
+ }
23
+
24
+ .columnCenter {
25
+ @media(max-width: 767px) {
26
+ position: absolute;
27
+ top: 12px;
28
+ margin: 0 auto;
29
+ left: 0;
30
+ right: 0;
31
+ text-align: center;
32
+ }
33
+ }
34
+ }
@@ -0,0 +1,35 @@
1
+
2
+ import { Spin } from 'antd';
3
+ import classNames from 'classnames';
4
+ import styles from './styles.module.scss';
5
+
6
+ interface PageContentProps extends PageBaseProps {
7
+ isLoading?: boolean;
8
+ }
9
+
10
+ interface PageBaseProps {
11
+ children?: React.ReactNode | React.ReactNode[];
12
+ }
13
+
14
+ export const Page = ({ children }: PageBaseProps) => {
15
+ return (
16
+ <div className={ styles.pageContainer }>
17
+ { children }
18
+ </div>
19
+ )
20
+ };
21
+
22
+ const PageHeader = ({ children }: PageBaseProps) => (
23
+ <div className={ styles.header }>
24
+ { children }
25
+ </div>
26
+ );
27
+
28
+ const PageContent = ({ children, isLoading }: PageContentProps) => (
29
+ <div className={ classNames(styles.pageContent, { [styles.pageContentLoading]: isLoading }) }>
30
+ { isLoading ? <Spin /> : children }
31
+ </div>
32
+ );
33
+
34
+ Page.Header = PageHeader;
35
+ Page.Content = PageContent;
@@ -0,0 +1,26 @@
1
+ $padding: 8.5px 20px;
2
+
3
+ .header {
4
+ background: var(--white-color);
5
+ height: 37px;
6
+ border-bottom: 2px solid var(--disabled-input);
7
+ color: var(--app-footer-bg-color);
8
+ display: flex;
9
+ gap: 21px;
10
+ align-items: center;
11
+ }
12
+
13
+ .pageContent, .header {
14
+ padding: $padding;
15
+ }
16
+
17
+ .pageContainer {
18
+ height: 100%;
19
+ }
20
+
21
+ .pageContentLoading {
22
+ min-height: 50%;
23
+ display: flex;
24
+ align-items: center;
25
+ justify-content: center;
26
+ }
@@ -0,0 +1,30 @@
1
+ import React from 'react';
2
+ import { QueryClientProvider } from "@tanstack/react-query";
3
+ import { queryClient } from '../../constants';
4
+ import { StoreProvider } from '../../contexts/useStore';
5
+
6
+ export interface SharedContextProviderProps {
7
+ providers?: React.JSXElementConstructor<unknown>[];
8
+ children?: React.ReactElement | React.ReactElement[];
9
+ disableInitialStoreRequest?: boolean;
10
+ }
11
+
12
+ const DefaultProviders = [
13
+ StoreProvider,
14
+ [QueryClientProvider, { client: queryClient }],
15
+ ] as React.JSXElementConstructor<unknown>[];
16
+
17
+ const ContextProvider = ({ providers, children }) => providers.reduceRight(
18
+ (children, parent) => React.cloneElement(parent, { children: children }),
19
+ children
20
+ );
21
+
22
+ export const SharedContextProvider = ({ children, disableInitialStoreRequest }: SharedContextProviderProps) => {
23
+ return (
24
+ <QueryClientProvider client={ queryClient }>
25
+ <StoreProvider disableInitialStoreRequest={disableInitialStoreRequest}>
26
+ { children }
27
+ </StoreProvider>
28
+ </QueryClientProvider>
29
+ );
30
+ };
@@ -0,0 +1,9 @@
1
+ export * from './SharedContextProvider';
2
+ export * from './Header';
3
+ export * from './Footer';
4
+ export * from './Page';
5
+ export * from './Button';
6
+ export * from './BottomDrawer';
7
+ export * from './Form';
8
+ export * from './Link';
9
+ export * from './Navigation';
@@ -0,0 +1,19 @@
1
+
2
+ import {
3
+ faBars, faUserTie, faPlus, faXmark, faUser, faUserPlus,
4
+ faCartShopping, faChevronDown, faFilter, faSearch, faQrcode,
5
+ } from '@fortawesome/free-solid-svg-icons'
6
+
7
+ export const icons = {
8
+ faBars,
9
+ faUser,
10
+ faUserTie,
11
+ faPlus,
12
+ faUserPlus,
13
+ faXmark,
14
+ faCartShopping,
15
+ faChevronDown,
16
+ faFilter,
17
+ faSearch,
18
+ faQrcode,
19
+ };
@@ -0,0 +1,3 @@
1
+ import { QueryClient } from "@tanstack/react-query";
2
+
3
+ export const queryClient = new QueryClient();
@@ -0,0 +1,2 @@
1
+ export * from './QueryClient'
2
+ export * from './Icons';
@@ -0,0 +1,20 @@
1
+
2
+ import React from 'react';
3
+ import { useSearchParams } from 'react-router-dom';
4
+ import { useStoreQuery } from '../hooks/useStoreQuery';
5
+ import { Store } from '../interfaces/Store';
6
+
7
+ const StoreContext = React.createContext<Store | null>(null);
8
+
9
+ const StoreProvider = ({ children, disableInitialStoreRequest }: { disableInitialStoreRequest?: boolean, children: React.ReactElement | React.ReactElement[] }) => {
10
+ const [params] = useSearchParams();
11
+ const { data: store } = useStoreQuery({ id: params.get('storeId') as string, enabled: !disableInitialStoreRequest });
12
+
13
+ return <StoreContext.Provider value={ store }> { children } </StoreContext.Provider>;
14
+ };
15
+
16
+ const useStoreContext = (): Store => {
17
+ return React.useContext(StoreContext) as Store;
18
+ };
19
+
20
+ export { StoreProvider, useStoreContext };
@@ -0,0 +1,124 @@
1
+ :root {
2
+ /* TODO: Update this code */
3
+ --primary-color: red;
4
+ --white-color: white;
5
+ --grad-bg-button-color: #DADADA;
6
+ --button-border-color: #707070;
7
+ --button-color: #37383A;
8
+ --customer-icon-color: #63B299;
9
+ --default-background-image-color: #D9D9D9;
10
+ --field-border-color: #D5D8D7;
11
+ --page-bg-color: #F9F9F9;
12
+ --page-border-color: #CECECE;
13
+ --page-footer-bg-color: #DEDEDE;
14
+ --app-footer-bg-color: #2C2D2E;
15
+ --app-footer-color: #F5F6F7;
16
+ --app-header-bg-1-color: #F7F7F7;
17
+ --app-header-bg-2-color: #E3E3E3;
18
+ --app-header-bg-3-color: #797979;
19
+ --app-header-bt-border-color: #090909;
20
+ --page-header-bg-color: #282c34;
21
+ --success-color: #64B298;
22
+ --error-color: #E05151;
23
+ --disabled-input: #E8E8E8;
24
+ --job-title-bg: #A83D3D;
25
+ --job-date-info-bg: #E0F0EA;
26
+ --job-date-edit-bg: #F0F0F0;
27
+ --header-border-color: #C7CAC9;
28
+ --grey: #E6E6E6;
29
+ --active-button-color: #35779D;
30
+ --sf-pro: normal normal bold 12px/14px SF Pro Text;
31
+ --delete-bg: #E15151;
32
+
33
+ /* New Code */
34
+ /*** Colors ***/
35
+ // Primary Colors
36
+ --color-black: #2c2d2e;
37
+ --color-black-rgb: 44, 45, 46;
38
+ --color-white: #FFFFFF;
39
+ --color-white-rgb: 255, 255, 255;
40
+
41
+ --color-orange: #FF674C;
42
+ --color-orange-rgb: 255, 103, 76;
43
+
44
+ --color-blue: #09168B;
45
+ --color-blue-rgb: 9, 22, 139;
46
+
47
+ --color-grey-light: #D9D9D9;
48
+ --color-grey-light-rgb: 217, 217, 217;
49
+ --color-grey: #C7CAC9;
50
+ --color-grey-rgb: 199, 202, 201;
51
+ --color-grey-dark: #797979;
52
+ --color-grey-dark-rgb: 121, 121, 121;
53
+
54
+ // Helper Colors
55
+ --color-warning-400: #E36262;
56
+ --color-warning-500: #E05151;
57
+
58
+ --color-confirmation-400: #73b9a2;
59
+ --color-confirmation-600: #64B298;
60
+
61
+ /*** Font Styles ***/
62
+ // Font Family
63
+ --font-family-primary: SF Pro;
64
+
65
+ // Font Weight
66
+ --font-weight-light: 300;
67
+ --font-weight-regular: 400;
68
+ --font-weight-medium: 500;
69
+ --font-weight-semibold: 600;
70
+ --font-weight-bold: 700;
71
+
72
+ // Font Styles
73
+ --font-style-normal: normal;
74
+ --font-style-italic: italic;
75
+
76
+ // Font Sizes
77
+ --font-size-body-1: 10px;
78
+ --font-size-body-2: 12px;
79
+ --font-size-body-3: 14px;
80
+ --font-size-body-4: 16px;
81
+ --font-size-body-5: 18px;
82
+ --font-size-body-6: 20px;
83
+
84
+ --font-size-h1: 46px;
85
+ --font-size-h2: 40px;
86
+ --font-size-h3: 36px;
87
+ --font-size-h4: 30px;
88
+ --font-size-h5: 24px;
89
+
90
+ --font-size-body-base: var(--font-size-body-4);
91
+ --font-size-label: var(--font-size-body-3);
92
+
93
+ /*** CTAs ***/
94
+ // Button Default
95
+ --button-default-background: var(--color-orange);
96
+ --button-default-text-color: var(--color-white);
97
+ --button-default-background-hover-color: rgba(var(--color-orange-rgb), .9);
98
+ --button-default-text-hover-color: var(--color-white);
99
+ --button-default-background-focus-color: var(--color-grey-dark);
100
+ --button-default-text-focus-color: rgba(var(--color-white-rgb), .8);
101
+
102
+ // Button Style 1
103
+ --button-style-1-background: var(--color-black);
104
+ --button-style-1-text-color: var(--color-white);
105
+ --button-style-1-background-hover-color: rgba(var(--color-black-rgb), .9);
106
+ --button-style-1-text-hover-color: var(--color-white);
107
+ --button-style-1-background-focus-color: var(--color-grey-dark);
108
+ --button-style-1-text-focus-color: rgba(var(--color-white-rgb), .8);
109
+
110
+ // Button Disabled
111
+ --button-disabled-background-color: var(--color-grey-dark);
112
+ --button-disabled-default-text-color: var(--color-white);
113
+
114
+ // Link
115
+ --link-color: var(--color-orange);
116
+ --link-hover-color: var(--color-black);
117
+ --link-focus-color: rgba(var(--color-orange), .9);
118
+ --link-disabled-color: rgba(var(--color-grey), .2);
119
+
120
+ // Transition Speed
121
+ --transition-slow: .2s;
122
+ --transition: .6s;
123
+ --transition-fast: 1s;
124
+ }
@@ -0,0 +1,2 @@
1
+ export * from './useApplicationDataQuery.hook';
2
+ export * from './useStoreQuery';
@@ -0,0 +1,10 @@
1
+ import { useQuery } from "@tanstack/react-query";
2
+ import { ApplicationsByCategory, ResponseList } from "../interfaces";
3
+ import { getAuth0 } from "../services/ApiService";
4
+
5
+ export function useApplicationDataQueryHook() {
6
+ return useQuery(
7
+ ['APPLICATIONS_QUERY'],
8
+ () => getAuth0<ResponseList<"Categories", ApplicationsByCategory>>('/Applications/groupByCategory')
9
+ );
10
+ }
@@ -0,0 +1,13 @@
1
+ import { useQuery, UseQueryOptions } from "@tanstack/react-query";
2
+ import { Store } from "../interfaces/Store";
3
+ import { get } from "../services";
4
+
5
+ interface StoreQueryProps extends UseQueryOptions<Store> {
6
+ id: string;
7
+ }
8
+
9
+ const FixedStore = "C62A59C7-DE0C-4EF7-9A5F-1929A4F93F46";
10
+
11
+ export const useStoreQuery = ({ id, ...options }: StoreQueryProps) => {
12
+ return useQuery(['STORE_QUERY', id], () => get(`/Stores/${id || FixedStore}`), options);
13
+ }
package/src/index.ts ADDED
@@ -0,0 +1,9 @@
1
+
2
+ // Hacky way because of the hooks and the npm link
3
+ export { Form } from 'antd';
4
+ export * from './interfaces';
5
+ export * from './services';
6
+ export * from './components';
7
+ export * from './constants';
8
+ export * from './hooks';
9
+ import './global.scss';
@@ -0,0 +1,19 @@
1
+
2
+ export interface ApplicationsByCategory {
3
+ Id: string;
4
+ Name: string;
5
+ Applications: ApplicationAttribute[];
6
+ }
7
+
8
+ export interface ApplicationAttribute {
9
+ Id: string;
10
+ Key: string;
11
+ Name: string;
12
+ Description: string;
13
+ URL: string;
14
+ ImageURL: string;
15
+ Status: string;
16
+ CreateDate: number;
17
+ UpdateDate: number;
18
+ }
19
+
@@ -0,0 +1,7 @@
1
+
2
+ export interface Configuration {
3
+ ApiHost: string;
4
+ ApiPath: string;
5
+ token?: string;
6
+ tokenAuth0?: string;
7
+ }
@@ -0,0 +1,23 @@
1
+
2
+ export interface Customer {
3
+ Name: string;
4
+ CustomerId: string;
5
+ MemberNumber: string;
6
+ Email: string;
7
+ FirstName: string;
8
+ LastName: string;
9
+ Gender: string;
10
+ Birthday: string;
11
+ Jobtitle: string;
12
+ Address: CustomerAddress;
13
+ DoNotPhone: boolean;
14
+ DoNotEmail: boolean;
15
+ Mobilephone: string;
16
+ }
17
+
18
+ export interface CustomerAddress {
19
+ Address: string;
20
+ Zip: string;
21
+ City: string;
22
+ Country: string;
23
+ }
@@ -0,0 +1,36 @@
1
+
2
+ export interface Product {
3
+ Id: string;
4
+ Reference: string;
5
+ CompanyId: string;
6
+ Name: string;
7
+ PriceSRP: number;
8
+ PriceCost: number;
9
+ VATId: string;
10
+ HierarchyId: string;
11
+ SupplierId: string;
12
+ IsStockCountEnabled: boolean;
13
+ MinOnlineStockQuantity: number;
14
+ IsNewArrival: boolean;
15
+ IsVerified: boolean;
16
+ Status: string;
17
+ Type: number;
18
+ Attributes: ProductAttribute[];
19
+ Items: ProductItem[];
20
+ CreateDate: number;
21
+ UpdateDate: number;
22
+ Recommendations: string[];
23
+ SimilarProducts: string[];
24
+ Images: string[];
25
+ }
26
+
27
+ export interface ProductItem {
28
+ SKU: string;
29
+ Barcodes: string[];
30
+ Attributes: ProductAttribute[];
31
+ }
32
+
33
+ export interface ProductAttribute {
34
+ Name: string;
35
+ Value: string;
36
+ }
@@ -0,0 +1,6 @@
1
+
2
+ export type ResponseList<K extends string, T> = {
3
+ [key in K]: T[];
4
+ } & {
5
+ Count: number;
6
+ };
@@ -0,0 +1,8 @@
1
+
2
+ export interface Store {
3
+ Id: string;
4
+ Name: string;
5
+ Address: string;
6
+ City: string;
7
+ ZipCode: string;
8
+ }
@@ -0,0 +1,6 @@
1
+ export * from './ResponseList';
2
+ export * from './Configuration';
3
+ export * from './Store';
4
+ export * from './Product';
5
+ export * from './Customer';
6
+ export * from './ApplicationsByCategory';