@kajoo-ai/sitecore-react 14.0.0 → 14.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 (74) hide show
  1. package/README.md +33 -33
  2. package/dist/cjs/components/button.d.ts +11 -11
  3. package/dist/cjs/components/check-box.d.ts +7 -7
  4. package/dist/cjs/components/container.d.ts +13 -13
  5. package/dist/cjs/components/drop-down/drop-down.d.ts +3 -3
  6. package/dist/cjs/components/drop-down/index.d.ts +1 -1
  7. package/dist/cjs/components/header.d.ts +3 -3
  8. package/dist/cjs/components/image.d.ts +17 -16
  9. package/dist/cjs/components/kajoo-component/index.d.ts +1 -1
  10. package/dist/cjs/components/kajoo-component/kajoo-component.d.ts +39 -33
  11. package/dist/cjs/components/kajoo-component/services.d.ts +8 -5
  12. package/dist/cjs/components/label.d.ts +3 -3
  13. package/dist/cjs/components/linebreak.d.ts +4 -4
  14. package/dist/cjs/components/link.d.ts +13 -13
  15. package/dist/cjs/components/list.d.ts +3 -3
  16. package/dist/cjs/components/paragraph.d.ts +3 -3
  17. package/dist/cjs/components/progress-bar.d.ts +6 -6
  18. package/dist/cjs/components/radio-button.d.ts +6 -6
  19. package/dist/cjs/components/repeater.d.ts +3 -3
  20. package/dist/cjs/components/rich-text.d.ts +3 -3
  21. package/dist/cjs/components/slider.d.ts +6 -6
  22. package/dist/cjs/components/text-area.d.ts +4 -4
  23. package/dist/cjs/components/text-input.d.ts +4 -4
  24. package/dist/cjs/components/text.d.ts +11 -11
  25. package/dist/cjs/components/toggle/index.d.ts +1 -1
  26. package/dist/cjs/components/toggle/toggle.d.ts +3 -3
  27. package/dist/cjs/components/type-form/index.d.ts +1 -1
  28. package/dist/cjs/components/type-form/type-form.d.ts +3 -3
  29. package/dist/cjs/components/video.d.ts +3 -3
  30. package/dist/cjs/factories/KajooLayoutFactory.d.ts +12 -12
  31. package/dist/cjs/index.d.ts +37 -37
  32. package/dist/cjs/index.js +1 -1
  33. package/dist/cjs/index.js.map +1 -1
  34. package/dist/cjs/toObject.d.ts +2 -2
  35. package/dist/cjs/types.d.ts +3 -3
  36. package/dist/cjs/utils.d.ts +6 -6
  37. package/dist/esm/components/button.d.ts +11 -11
  38. package/dist/esm/components/check-box.d.ts +7 -7
  39. package/dist/esm/components/container.d.ts +13 -13
  40. package/dist/esm/components/drop-down/drop-down.d.ts +3 -3
  41. package/dist/esm/components/drop-down/index.d.ts +1 -1
  42. package/dist/esm/components/header.d.ts +3 -3
  43. package/dist/esm/components/image.d.ts +17 -16
  44. package/dist/esm/components/kajoo-component/index.d.ts +1 -1
  45. package/dist/esm/components/kajoo-component/kajoo-component.d.ts +39 -33
  46. package/dist/esm/components/kajoo-component/services.d.ts +8 -5
  47. package/dist/esm/components/label.d.ts +3 -3
  48. package/dist/esm/components/linebreak.d.ts +4 -4
  49. package/dist/esm/components/link.d.ts +13 -13
  50. package/dist/esm/components/list.d.ts +3 -3
  51. package/dist/esm/components/paragraph.d.ts +3 -3
  52. package/dist/esm/components/progress-bar.d.ts +6 -6
  53. package/dist/esm/components/radio-button.d.ts +6 -6
  54. package/dist/esm/components/repeater.d.ts +3 -3
  55. package/dist/esm/components/rich-text.d.ts +3 -3
  56. package/dist/esm/components/slider.d.ts +6 -6
  57. package/dist/esm/components/text-area.d.ts +4 -4
  58. package/dist/esm/components/text-input.d.ts +4 -4
  59. package/dist/esm/components/text.d.ts +11 -11
  60. package/dist/esm/components/toggle/index.d.ts +1 -1
  61. package/dist/esm/components/toggle/toggle.d.ts +3 -3
  62. package/dist/esm/components/type-form/index.d.ts +1 -1
  63. package/dist/esm/components/type-form/type-form.d.ts +3 -3
  64. package/dist/esm/components/video.d.ts +3 -3
  65. package/dist/esm/factories/KajooLayoutFactory.d.ts +12 -12
  66. package/dist/esm/index.d.ts +37 -37
  67. package/dist/esm/index.js +1 -1
  68. package/dist/esm/index.js.map +1 -1
  69. package/dist/esm/toObject.d.ts +2 -2
  70. package/dist/esm/types.d.ts +3 -3
  71. package/dist/esm/utils.d.ts +6 -6
  72. package/dist/index.d.ts +109 -103
  73. package/dist/tsconfig.tsbuildinfo +1 -1
  74. package/package.json +57 -55
package/dist/index.d.ts CHANGED
@@ -2,93 +2,93 @@ import React, { FC, ReactNode } from 'react';
2
2
  import { Link as Link$1, RouteData, LayoutServiceData } from '@sitecore-jss/sitecore-jss-react';
3
3
  import { JsonObject } from 'type-fest';
4
4
 
5
- type ITextField$1 = {
6
- value?: string | number;
7
- editable?: string;
8
- };
9
- interface IButton {
10
- text: ITextField$1 | string;
11
- [key: string]: unknown;
12
- }
5
+ type ITextField$1 = {
6
+ value?: string | number;
7
+ editable?: string;
8
+ };
9
+ interface IButton {
10
+ text: ITextField$1 | string;
11
+ [key: string]: unknown;
12
+ }
13
13
  declare const Button: FC<IButton>;
14
14
 
15
- interface IProps$a {
16
- className: string;
17
- [key: string]: unknown;
18
- }
15
+ interface IProps$a {
16
+ className: string;
17
+ [key: string]: unknown;
18
+ }
19
19
  declare const CheckBox: FC<IProps$a>;
20
20
 
21
- interface IProps$9 {
22
- bgImage?: {
23
- value: {
24
- src: string;
25
- };
26
- };
27
- tag?: keyof JSX.IntrinsicElements;
28
- [key: string]: any;
29
- children: ReactNode | ReactNode[];
30
- }
21
+ interface IProps$9 {
22
+ bgImage?: {
23
+ value: {
24
+ src: string;
25
+ };
26
+ };
27
+ tag?: keyof JSX.IntrinsicElements;
28
+ [key: string]: any;
29
+ children: ReactNode | ReactNode[];
30
+ }
31
31
  declare const Container: FC<IProps$9>;
32
32
 
33
33
  declare const Dropdown: FC<any>;
34
34
 
35
35
  declare const Header: FC<any>;
36
36
 
37
- interface ImageFieldValue {
38
- [attributeName: string]: unknown;
39
- src?: string;
40
- alt?: string;
41
- }
42
- interface ImageField {
43
- value?: ImageFieldValue;
44
- editable?: string;
45
- }
46
- interface IProps$8 {
47
- src: ImageField | ImageFieldValue;
48
- alt?: string;
49
- srcSet?: string | any[];
50
- }
51
- declare const Image: ({ src, alt, srcSet: htmlSrcSet, ...rest }: IProps$8) => JSX.Element;
37
+ interface ImageFieldValue {
38
+ [attributeName: string]: unknown;
39
+ src?: string;
40
+ alt?: string;
41
+ }
42
+ interface ImageField {
43
+ value?: ImageFieldValue;
44
+ editable?: string;
45
+ }
46
+ interface IProps$8 {
47
+ src: ImageField | ImageFieldValue;
48
+ alt?: string;
49
+ srcSet?: string | any[];
50
+ }
51
+ declare const Image: FC<IProps$8>;
52
52
 
53
53
  declare const Label: FC<any>;
54
54
 
55
- type IProps$7 = JSX.IntrinsicElements["hr"];
55
+ type IProps$7 = JSX.IntrinsicElements["hr"];
56
56
  declare const Linebreak: FC<IProps$7>;
57
57
 
58
- type ISitecoreLink = Parameters<typeof Link$1>[0];
59
- type ITextField = {
60
- value?: string | number;
61
- editable?: string;
62
- };
63
- interface ILink extends Omit<ISitecoreLink, "field" | "href"> {
64
- text?: ITextField | string;
65
- href: ISitecoreLink["field"] | string;
66
- }
58
+ type ISitecoreLink = Parameters<typeof Link$1>[0];
59
+ type ITextField = {
60
+ value?: string | number;
61
+ editable?: string;
62
+ };
63
+ interface ILink extends Omit<ISitecoreLink, "field" | "href"> {
64
+ text?: ITextField | string;
65
+ href: ISitecoreLink["field"] | string;
66
+ }
67
67
  declare const Link: FC<ILink>;
68
68
 
69
69
  declare const List: FC<any>;
70
70
 
71
71
  declare const Paragraph: FC<any>;
72
72
 
73
- interface IProps$6 {
74
- className: string;
75
- }
73
+ interface IProps$6 {
74
+ className: string;
75
+ }
76
76
  declare const ProgressBar: FC<IProps$6>;
77
77
 
78
- interface IProps$5 {
79
- className: string;
80
- }
78
+ interface IProps$5 {
79
+ className: string;
80
+ }
81
81
  declare const Radiobutton: FC<IProps$5>;
82
82
 
83
- interface IProps$4 {
84
- className: string;
85
- }
83
+ interface IProps$4 {
84
+ className: string;
85
+ }
86
86
  declare const Slider: FC<IProps$4>;
87
87
 
88
- type IProps$3 = JSX.IntrinsicElements["textarea"];
88
+ type IProps$3 = JSX.IntrinsicElements["textarea"];
89
89
  declare const Textarea: FC<IProps$3>;
90
90
 
91
- type IProps$2 = Omit<JSX.IntrinsicElements["input"], "type">;
91
+ type IProps$2 = Omit<JSX.IntrinsicElements["input"], "type">;
92
92
  declare const Textinput: FC<IProps$2>;
93
93
 
94
94
  declare const Toggle: FC<any>;
@@ -97,59 +97,65 @@ declare const TypeForm: FC<any>;
97
97
 
98
98
  declare const Video: FC<any>;
99
99
 
100
- interface IProps$1 {
101
- text?: {
102
- value?: string | number;
103
- editable?: string;
104
- } | string;
105
- tag?: keyof JSX.IntrinsicElements;
106
- [key: string]: any;
107
- }
100
+ interface IProps$1 {
101
+ text?: {
102
+ value?: string | number;
103
+ editable?: string;
104
+ } | string;
105
+ tag?: keyof JSX.IntrinsicElements;
106
+ [key: string]: any;
107
+ }
108
108
  declare const Text: FC<IProps$1>;
109
109
 
110
110
  declare const RichText: FC<any>;
111
111
 
112
112
  declare const Repeater: FC<any>;
113
113
 
114
- interface IProps {
115
- component: ({ fields, children }: React.PropsWithChildren<{
116
- fields: JsonObject;
117
- }>) => JSX.Element;
118
- datasource: IConsciaIntegration | IContentstackIntegration;
119
- loadingComponent?: JSX.Element;
120
- errorComponent?: JSX.Element;
121
- emptyComponent?: JSX.Element;
122
- children?: JSX.Element[];
123
- }
124
- interface IContentstackIntegration {
125
- provider: 'contentstack';
126
- hostUrl?: string;
127
- apiKey: string;
128
- deliveryToken: string;
129
- language?: string;
130
- branch?: string;
131
- environment: string;
132
- contentTypeUid: string;
133
- entryUid: string;
134
- }
135
- interface IConsciaIntegration {
136
- provider: 'conscia.ai';
137
- hostUrl: string;
138
- customerCode: string;
139
- apiToken: string;
140
- environment: string;
141
- componentCode: string;
142
- }
114
+ interface IProps {
115
+ component: ({ fields, children, }: React.PropsWithChildren<{
116
+ fields: JsonObject;
117
+ }>) => JSX.Element;
118
+ datasource: IConsciaIntegration | IContentstackIntegration | IKontentAiIntegration;
119
+ loadingComponent?: JSX.Element;
120
+ errorComponent?: JSX.Element;
121
+ emptyComponent?: JSX.Element;
122
+ children?: JSX.Element[];
123
+ }
124
+ interface IContentstackIntegration {
125
+ provider: "contentstack";
126
+ hostUrl?: string;
127
+ apiKey: string;
128
+ deliveryToken: string;
129
+ language?: string;
130
+ branch?: string;
131
+ environment: string;
132
+ contentTypeUid: string;
133
+ entryUid: string;
134
+ }
135
+ interface IConsciaIntegration {
136
+ provider: "conscia.ai";
137
+ hostUrl: string;
138
+ customerCode: string;
139
+ apiToken: string;
140
+ environment: string;
141
+ componentCode: string;
142
+ }
143
+ interface IKontentAiIntegration {
144
+ provider: "kontent.ai";
145
+ environmentId: string;
146
+ deliveryApiToken: string;
147
+ contentItemCodename: string;
148
+ }
143
149
  declare const KajooComponent: (props: IProps) => JSX.Element;
144
150
 
145
- interface ILayoutProps extends RouteData {
146
- layoutData: LayoutServiceData;
147
- }
148
- type ILayout = React.FC<ILayoutProps>;
149
- declare class KajooLayoutFactory {
150
- private static readonly layoutsByName;
151
- static getLayout: (route: RouteData) => ILayout;
152
- static registerLayout: (name: string, layout: ILayout) => void;
151
+ interface ILayoutProps extends RouteData {
152
+ layoutData: LayoutServiceData;
153
+ }
154
+ type ILayout = React.FC<ILayoutProps>;
155
+ declare class KajooLayoutFactory {
156
+ private static readonly layoutsByName;
157
+ static getLayout: (route: RouteData) => ILayout;
158
+ static registerLayout: (name: string, layout: ILayout) => void;
153
159
  }
154
160
 
155
161
  export { Button, CheckBox as Checkbox, IProps$a as CheckboxProps, Container, Dropdown, Header, Image, KajooComponent, IProps as KajooComponentProps, KajooLayoutFactory, Label, Linebreak, IProps$7 as LinebreakProps, Link, List, Paragraph, ProgressBar, Radiobutton, IProps$5 as RadiobuttonProps, Repeater, RichText, Slider, IProps$4 as SliderProps, Text, Textarea, IProps$3 as TextareaProps, Textinput, IProps$2 as TextinputProps, Toggle, TypeForm, Video };