@openlettermarketing/olc-react-sdk 0.0.39 → 0.0.40

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.
@@ -6,6 +6,7 @@ interface AppProps {
6
6
  templateBuilderRoute?: string | null;
7
7
  styles?: any;
8
8
  olcTemplate?: Record<string, any>;
9
+ defaultCategory?: string[];
9
10
  onReturnAndNavigate?: () => void;
10
11
  onGetOneTemplate?: (payload: any) => Promise<any>;
11
12
  onGetTemplates?: (payload: any) => Promise<any>;
@@ -4,6 +4,7 @@ interface Props {
4
4
  store: StoreType;
5
5
  currentTemplateType: string;
6
6
  platformName?: string | null;
7
+ defaultCategory?: string[];
7
8
  onGetOneTemplate?: (payload: any) => Promise<any>;
8
9
  onGetTemplates?: (payload: any) => Promise<any>;
9
10
  onGetCustomFields?: () => Promise<any>;
@@ -17,6 +17,7 @@ interface TemplateBuilderProps {
17
17
  platformName?: string | null;
18
18
  createTemplateRoute?: string | null;
19
19
  olcTemplate?: Record<string, any>;
20
+ defaultCategory?: string[];
20
21
  onReturnAndNavigate?: () => void;
21
22
  onGetCustomFields?: () => Promise<any>;
22
23
  onGetOneTemplate?: (payload: any) => Promise<any>;
@@ -13,6 +13,8 @@ interface TemplateBuilderProps {
13
13
  createTemplateRoute?: string | null;
14
14
  templateBuilderRoute?: string | null;
15
15
  olcTemplate?: Record<string, any>;
16
+ defaultCategory?: string[];
17
+ sandbox?: boolean;
16
18
  onReturnAndNavigate?: () => void;
17
19
  onGetOneTemplate?: (payload: any) => Promise<any>;
18
20
  onGetTemplates?: (payload: any) => Promise<any>;
@@ -22,5 +24,5 @@ interface TemplateBuilderProps {
22
24
  root?: CustomCSSProperties;
23
25
  };
24
26
  }
25
- declare const TemplateBuilder: ({ container, secretKey, basicAuthUsername, basicAuthPassword, platformName, createTemplateRoute, templateBuilderRoute, olcTemplate, onReturnAndNavigate, onGetOneTemplate, onGetTemplates, onGetCustomFields, onSubmit, styles, }: TemplateBuilderProps) => void;
27
+ declare const TemplateBuilder: ({ container, secretKey, basicAuthUsername, basicAuthPassword, platformName, createTemplateRoute, templateBuilderRoute, olcTemplate, defaultCategory, sandbox, onReturnAndNavigate, onGetOneTemplate, onGetTemplates, onGetCustomFields, onSubmit, styles, }: TemplateBuilderProps) => void;
26
28
  export default TemplateBuilder;
@@ -1,4 +1,5 @@
1
- export declare const API_BASE_URL = "https://api.openletterconnect.com/api/v1/sdk";
1
+ export declare const PROD_API_BASE_URL = "https://api.openletterconnect.com/api/v1/sdk";
2
+ export declare const DEMO_API_BASE_URL = "https://demoapi.openletterconnect.com/api/v1/sdk";
2
3
  export declare const DPI: number;
3
4
  export declare const Barcode: string;
4
5
  export declare const PRODUCT_LEARN_URL: string;
@@ -2,6 +2,7 @@ import React from 'react';
2
2
  export interface CustomCSSProperties extends React.CSSProperties {
3
3
  '--font-family'?: string;
4
4
  '--scrollbar-thumb-color'?: string;
5
+ '--scrollbar-track-color'?: string;
5
6
  '--primary-color'?: string;
6
7
  '--secondary-color'?: string;
7
8
  '--svg-color'?: string;
@@ -1,7 +1,10 @@
1
1
  export declare let basicAuthUsername: string;
2
2
  export declare let basicAuthPassword: string;
3
+ export declare let isSandbox: boolean;
3
4
  export declare const copyToClipboard: (text: string) => void;
4
5
  export declare const getAuthUserName: () => string;
5
6
  export declare const getAuthUserPassword: () => string;
7
+ export declare const getIsSandbox: () => boolean;
6
8
  export declare const setAuthUserName: (name: string) => void;
7
9
  export declare const setAuthUserPassword: (password: string) => void;
10
+ export declare const setIsSandbox: (sandbox: boolean) => void;
package/package.json CHANGED
@@ -1,7 +1,7 @@
1
1
  {
2
2
  "name": "@openlettermarketing/olc-react-sdk",
3
3
  "private": false,
4
- "version": "0.0.39",
4
+ "version": "0.0.40",
5
5
  "type": "module",
6
6
  "description": "Simplify template builder integration for any product.",
7
7
  "main": "build/index.js",
@@ -76,6 +76,7 @@
76
76
  "@typescript-eslint/eslint-plugin": "^6.17.0",
77
77
  "@typescript-eslint/parser": "^6.17.0",
78
78
  "@vitejs/plugin-react": "^4.3.0",
79
+ "ajv": "^7.2.4",
79
80
  "babel-loader": "^9.1.3",
80
81
  "css-loader": "^7.1.2",
81
82
  "eslint": "^8.56.0",