@bigbinary/neeto-molecules 1.0.48 → 1.0.49

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.
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@bigbinary/neeto-molecules",
3
- "version": "1.0.48",
3
+ "version": "1.0.49",
4
4
  "description": "A package of reusable molecular components for neeto products.",
5
5
  "repository": "git@github.com:bigbinary/neeto-molecules.git",
6
6
  "author": "Amaljith K <amaljith.k@bigbinary.com>",
@@ -8,38 +8,6 @@ import { CheckboxProps, DropdownProps, InputProps } from "@bigbinary/neetoui";
8
8
  *
9
9
  * ![image](https://user-images.githubusercontent.com/32426070/195069324-3cbb4c70-f62b-4080-b4ae-bdeabb449b23.png|height=200|width=300)
10
10
  *
11
- * Props:
12
- *
13
- * This is the data structure for the columnData prop:
14
- *
15
- * @example
16
- *
17
- * const columnData = [
18
- * {
19
- * title: "ID",
20
- * dataIndex: "id",
21
- * key: "id",
22
- * ...
23
- * },
24
- * {
25
- * title: "GUID",
26
- * dataIndex: "guid",
27
- * key: "guid",
28
- * ...
29
- * },
30
- * ...
31
- * ];
32
- * @endexample
33
- * It is similar to the columnsData prop of the neetoUI table component
34
- *
35
- * (reference).
36
- *
37
- * These 3 props are required for the Columns as well as the neetoUI Table
38
- *
39
- * component to work.
40
- *
41
- * Simple:
42
- *
43
11
  * @example
44
12
  *
45
13
  * import React, { useState } from "react";
@@ -7,12 +7,6 @@ import React from "react";
7
7
  *
8
8
  * @example
9
9
  *
10
- * ["oliver@example.com", "eve@example.com"]
11
- * @endexample
12
- * Simple:
13
- *
14
- * @example
15
- *
16
10
  * import React from "react";
17
11
  * import { useFormikContext } from "formik";
18
12
  * import EmailPreview from "@bigbinary/neeto-molecules/EmailPreview";
@@ -3,15 +3,9 @@ import React from "react";
3
3
  *
4
4
  * A fallback page for handling 404, 403 and 500 errors.
5
5
  *
6
- * This component accepts two optional props status and homeUrl. status is
6
+ * The component also has a "contact us" link that opens the chat widget for
7
7
  *
8
- * the status code of the error. 404 is the default value for status. homeUrl
9
- *
10
- * is the URL to which the user will be taken to when user clicks on back to home
11
- *
12
- * button. / is the default value for homeUrl. The component also has a
13
- *
14
- * "contact us" link that opens the chat widget for further communication.
8
+ * further communication.
15
9
  *
16
10
  */
17
11
  const ErrorPage: React.FC<{
@@ -4,6 +4,8 @@ import React, { ReactElement } from "react";
4
4
  *
5
5
  * A common component used for integrations across neeto products.
6
6
  *
7
+ * ![Integrations](https://user-images.githubusercontent.com/49012815/237155224-582fe3b3-2b63-484b-bc08-6898fb8c1ce2.png|height=200|width=300)
8
+ *
7
9
  * @example
8
10
  *
9
11
  * import IntegrationCard from "@bigbinary/neeto-molecules/IntegrationCard";
@@ -3,6 +3,8 @@ import React from "react";
3
3
  *
4
4
  * A common component used for disconnect UI of integrations across neeto products.
5
5
  *
6
+ * ![Integration](https://github.com/bigbinary/neeto-molecules/assets/49012815/864c1407-a6c8-4b53-ab01-364db42d2a80|height=200|width=300)
7
+ *
6
8
  * @example
7
9
  *
8
10
  * import IntegrationDisconnectAlert from "@bigbinary/neeto-molecules/IntegrationDisconnectAlert";
@@ -3,6 +3,8 @@ import React from "react";
3
3
  *
4
4
  * A component used to display walkthrough video of integration.
5
5
  *
6
+ * ![IntegrationWalkthroughModal](https://user-images.githubusercontent.com/89389135/243562250-9cdd99cf-ee7e-42b5-b578-ca57db5fc94a.png|height=200|width=300)
7
+ *
6
8
  * @example
7
9
  *
8
10
  * import React, { useState } from "react";
@@ -19,6 +19,8 @@ interface ProductShortcuts {
19
19
  *
20
20
  * defined hotkey (shift+/).
21
21
  *
22
+ * ![image](https://user-images.githubusercontent.com/29166133/223832668-2b92ff28-6565-434c-8a76-cf587c9dbc99.png|height=200|width=300)
23
+ *
22
24
  * All the global shortcuts like open pane, close modal etc will be rendered by
23
25
  *
24
26
  * default by the component. It provides a single prop called productShortcuts
@@ -77,6 +79,8 @@ interface ProductShortcuts {
77
79
  * @endexample
78
80
  * This hook can be used to manage the behavior of KeyboardShortcuts pane.
79
81
  *
82
+ * This hook will return an array with exactly 2 values just like useState hook.
83
+ *
80
84
  * @example
81
85
  *
82
86
  * import KeyboardShortcuts from "@bigbinary/neeto-molecules/KeyboardShortcuts";
@@ -7,8 +7,6 @@ import React from "react";
7
7
  *
8
8
  * undefined
9
9
  *
10
- * Usage:
11
- *
12
10
  * @example
13
11
  *
14
12
  * import LoginPage from "@bigbinary/neeto-molecules/LoginPage";
@@ -62,7 +62,15 @@ type AddNewProps = {
62
62
  * );
63
63
  * };
64
64
  * @endexample
65
- * MenuBar with child components
65
+ * Props for MenuBar.Block:
66
+ *
67
+ * Props for MenuBar.AddNew:
68
+ *
69
+ * Props for MenuBar.SubTitle:
70
+ *
71
+ * Props for MenuBar.Search:
72
+ *
73
+ * Props for MenuBar.Item:
66
74
  *
67
75
  * @example
68
76
  *
@@ -25,14 +25,10 @@ type EmbedCode = React.FC<{
25
25
  *
26
26
  * application.
27
27
  *
28
- * Usage:
29
- *
30
28
  * @example
31
29
  *
32
30
  * <NeetoWidget.EmbedCode primaryApp={NeetoWidget.WIDGET_TYPES.chat} />
33
31
  * @endexample
34
- * Props:
35
- *
36
32
  */
37
33
  const NeetoWidget: {
38
34
  EmbedCode: EmbedCode;
@@ -31,8 +31,6 @@ export
31
31
  *
32
32
  * ![PhoneNumberInput](https://user-images.githubusercontent.com/35297280/231367938-93aa94b0-2a8c-44b3-b1c7-8c60843e40c4.png|height=200|width=300)
33
33
  *
34
- * Props:
35
- *
36
34
  * @example
37
35
  *
38
36
  * import React, { useState } from "react";
@@ -51,8 +49,6 @@ export
51
49
  *
52
50
  * ![PhoneNumber](https://user-images.githubusercontent.com/35297280/231367945-ee5f0921-92e3-4086-a8e2-f9ab63cf9a37.png|height=200|width=300)
53
51
  *
54
- * Props:
55
- *
56
52
  * @example
57
53
  *
58
54
  * import { PhoneNumber } from "@bigbinary/neeto-molecules/PhoneNumber";
@@ -16,10 +16,6 @@ interface PublishBlockProps {
16
16
  *
17
17
  * ![image](https://user-images.githubusercontent.com/35297280/219363621-9fb295c4-72e4-4cde-b8d1-614f49e5dfa5.png|height=200|width=300)
18
18
  *
19
- * This optional component can be used to render the reset alert modal for
20
- *
21
- * discarding draft.
22
- *
23
19
  * @example
24
20
  *
25
21
  * import PublishBlock from "@bigbinary/neeto-molecules/PublishBlock";
@@ -47,21 +43,37 @@ interface PublishBlockProps {
47
43
  * </>
48
44
  * );
49
45
  * return (
50
- * <>
51
- * <PublishBlock
52
- * renderDraftButtons={renderDraftButtons}
53
- * renderPublishButtons={renderPublishButtons}
54
- * />
46
+ * <PublishBlock
47
+ * renderDraftButtons={renderDraftButtons}
48
+ * renderPublishButtons={renderPublishButtons}
49
+ * />
50
+ * );
51
+ * };
52
+ * @endexample
53
+ * This optional component can be used to render the reset alert modal for
54
+ *
55
+ * discarding draft.
56
+ *
57
+ * It also accepts all other alert props.
58
+ *
59
+ * @example
60
+ *
61
+ * import PublishBlock from "@bigbinary/neeto-molecules/PublishBlock";
55
62
  *
56
- * <PublishBlock.Alert
57
- * isOpen={isResetDraftAlertOpen}
58
- * message="Leaving this page will delete all unpublished changes."
59
- * title="Are you sure you want to discard changes?"
60
- * onClose={() => setIsResetDraftAlertOpen(false)}
61
- * onSubmit={action("handleReset")}
62
- * //other alert props can also be passed
63
- * />
64
- * </>
63
+ * const PublishActionBlock = (
64
+ * {
65
+ * //all variables used in the below example can be passed as props or can be defined in the component itself
66
+ * }
67
+ * ) => {
68
+ * return (
69
+ * <PublishBlock.Alert
70
+ * isOpen={isResetDraftAlertOpen}
71
+ * message="Leaving this page will delete all unpublished changes."
72
+ * title="Are you sure you want to discard changes?"
73
+ * onClose={() => setIsResetDraftAlertOpen(false)}
74
+ * onSubmit={action("handleReset")}
75
+ * //other alert props can also be passed
76
+ * />
65
77
  * );
66
78
  * };
67
79
  * @endexample
@@ -5,8 +5,6 @@ import React from "react";
5
5
  *
6
6
  * ![image](https://user-images.githubusercontent.com/35630321/198989580-36a91233-8e7b-4300-b980-f50d2b0efcaa.png|height=200|width=300)
7
7
  *
8
- * Props:
9
- *
10
8
  * How to Reset Form from outside Schedule Component:
11
9
  *
12
10
  * How to get the form errors from outside Schedule Component:
@@ -15,7 +13,7 @@ import React from "react";
15
13
  *
16
14
  * @example
17
15
  *
18
- * const periods = {
16
+ * const periods = {
19
17
  * sunday: [],
20
18
  * monday: [
21
19
  * {
@@ -95,11 +93,7 @@ import React from "react";
95
93
  * ],
96
94
  * saturday: [],
97
95
  * };
98
- *
99
- * ];
100
96
  * @endexample
101
- * Simple:
102
- *
103
97
  * @example
104
98
  *
105
99
  * import React, { useState } from "react";
@@ -57,12 +57,6 @@ interface RightBlockComposition {
57
57
  * />
58
58
  * );
59
59
  * @endexample
60
- * For common usages with Download, Manage Columns and Filters, we can use the
61
- *
62
- * composite component SubHeader.RightBlock
63
- *
64
- * Props:
65
- *
66
60
  * @example
67
61
  *
68
62
  * import SubHeader from "@bigbinary/neeto-molecules/SubHeader";
@@ -15,10 +15,6 @@ import React from "react";
15
15
  *
16
16
  * below.
17
17
  *
18
- * TableWrapper should be used only with Tables used in the listing layout as shown
19
- *
20
- * below.
21
- *
22
18
  * @example
23
19
  *
24
20
  * import TableWrapper from "@bigbinary/neeto-molecules/TableWrapper";