@bigbinary/neeto-molecules 1.0.42 → 1.0.43

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.42",
3
+ "version": "1.0.43",
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>",
@@ -70,6 +70,7 @@
70
70
  "@storybook/react": "6.5.16",
71
71
  "@svgr/rollup": "^6.2.1",
72
72
  "@svgr/webpack": "^6.5.1",
73
+ "@tailwindcss/line-clamp": "^0.4.4",
73
74
  "@testing-library/jest-dom": "5.16.2",
74
75
  "@testing-library/react": "12.1.3",
75
76
  "@testing-library/react-hooks": "^8.0.0",
@@ -135,6 +136,7 @@
135
136
  "react-router-dom": "^5.2.0",
136
137
  "react-toastify": "^9.0.8",
137
138
  "react-transition-group": "^4.4.5",
139
+ "react-window": "^1.8.9",
138
140
  "rollup": "^2.76.0",
139
141
  "rollup-plugin-analyzer": "^4.0.0",
140
142
  "rollup-plugin-cleaner": "^1.0.0",
@@ -386,6 +386,14 @@
386
386
  },
387
387
  "codeblock": {
388
388
  "codeSnippet": "Code snippet"
389
+ },
390
+ "iconPicker": {
391
+ "entity": "icons",
392
+ "dropdown": {
393
+ "label": "Select icon",
394
+ "noResults": "No results",
395
+ "removeButton": "Remove"
396
+ }
389
397
  }
390
398
  }
391
399
  }
@@ -0,0 +1,37 @@
1
+ import React from "react";
2
+ /**
3
+ *
4
+ * A dropdown component that allows you to select an icon from a list of Google icons.
5
+ *
6
+ * ![image](https://user-images.githubusercontent.com/35304653/243669467-148585f0-5499-4914-ba84-4284bda8e2d8.png|height=200|width=300)
7
+ *
8
+ * We make use of a feature called ligatures that convert the snake cased name of an icon to an actual icon. It is achieved like so. Note that the classname "material-symbols-rounded" is necessary for this conversion to work.
9
+ *
10
+ * @example
11
+ *
12
+ * <span className="material-symbols-rounded">icon_name</span>
13
+ * @endexample
14
+ * @example
15
+ *
16
+ * import IconPicker from "@bigbinary/neeto-molecules/IconPicker";
17
+ *
18
+ * const App = () => {
19
+ * const [value, setValue] = useState("home");
20
+ * return (
21
+ * <IconPicker
22
+ * value={value}
23
+ * label="Select an icon"
24
+ * onClick={value => setValue(value)}
25
+ * />
26
+ * );
27
+ * };
28
+ * @endexample
29
+ */
30
+ const IconPicker: React.FC<{
31
+ filled?: boolean;
32
+ value?: string;
33
+ label?: string;
34
+ onClick?: Function;
35
+ className?: string;
36
+ }>;
37
+ export default IconPicker;