gbs-add-block 1.0.2 → 1.0.4

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/README.md CHANGED
@@ -1,4 +1,4 @@
1
- # GBS Building Blocks 2.0 (v1.0.2)
1
+ # GBS Building Blocks 2.0 (v1.0.4)
2
2
 
3
3
  Latest and upgraded version of GBS building blocks with headless UI and removed dependencies.
4
4
 
@@ -6,7 +6,7 @@ Latest and upgraded version of GBS building blocks with headless UI and removed
6
6
 
7
7
  For detailed documentation on usage and props, Please visit: [Building Block Documentation v2.0](https://blackmax-designs.gitbook.io/building-block-v2.0)
8
8
 
9
- ## What's New 🎉 (Ver 1.0.2)
9
+ ## What's New 🎉 (Ver 1.0.4)
10
10
 
11
11
  - Major Update with more stable features and Data Grid.
12
12
  - Deprecated Grid Component, Use New Data Grid instead.
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "gbs-add-block",
3
- "version": "1.0.2",
3
+ "version": "1.0.4",
4
4
  "description": "React Component Library",
5
5
  "type": "module",
6
6
  "files": [
@@ -5,7 +5,7 @@ type MenuSectionProps = {
5
5
  section: MenuSectionType;
6
6
  sectionIndex: number;
7
7
  iconMap: Record<string, IconComponent>;
8
- toggleItem: (sectionIndex: number, itemId: number) => void;
8
+ toggleItem: (sectionIndex: number, itemId: number | string) => void;
9
9
  };
10
10
 
11
11
  export const MenuSection = ({
@@ -4,7 +4,7 @@ import { MenuSection as MenuSectionComponent } from "./MenuSection";
4
4
  type SidebarMenuProps = {
5
5
  sections?: MenuSection[];
6
6
  iconMap: Record<string, IconComponent>;
7
- toggleItem: (sectionIndex: number, itemId: number) => void;
7
+ toggleItem: (sectionIndex: number, itemId: number | string) => void;
8
8
  };
9
9
 
10
10
  export const SidebarMenu = ({
@@ -4,7 +4,7 @@ import { MenuData } from "../type";
4
4
  export const useSidebarState = (menuData: MenuData) => {
5
5
  const [sidebarData, setSidebarData] = useState<MenuData>(menuData);
6
6
 
7
- const toggleItem = (sectionIndex: number, itemId: number): void => {
7
+ const toggleItem = (sectionIndex: number, itemId: number | string): void => {
8
8
  const newData = { ...sidebarData };
9
9
 
10
10
  const section = newData.sections?.[sectionIndex];