From bf4bb189983a62a605b2465a1240316d5a96795e Mon Sep 17 00:00:00 2001 From: anuradha9712 Date: Wed, 25 Dec 2024 02:47:05 +0400 Subject: [PATCH 01/13] v4.0.0 From 7e2e6d91cdfbaf887ec23ed54e6e31487eec4a89 Mon Sep 17 00:00:00 2001 From: anuradha9712 Date: Thu, 2 Jan 2025 16:40:53 +0400 Subject: [PATCH 02/13] test(daterangepicker): update test cases for daterange picker component --- .../__tests__/DateRangePicker.test.tsx | 12 ++++++++++++ 1 file changed, 12 insertions(+) diff --git a/core/components/organisms/dateRangePicker/__tests__/DateRangePicker.test.tsx b/core/components/organisms/dateRangePicker/__tests__/DateRangePicker.test.tsx index 6315d44804..dacffa2de5 100644 --- a/core/components/organisms/dateRangePicker/__tests__/DateRangePicker.test.tsx +++ b/core/components/organisms/dateRangePicker/__tests__/DateRangePicker.test.tsx @@ -21,6 +21,18 @@ const dateFormat = [currentDate, 1629790081880]; const inputFormat = ['mm/dd/yyyy', 'dd/mm/yyyy', 'yyyy/mm/dd', 'mm-dd-yyyy', 'dd-mm-yyyy', 'yyyy-mm-dd']; const FunctionValue = jest.fn(); +let dateNowSpy: any; + +beforeAll(() => { + // Lock Time + dateNowSpy = jest.spyOn(Date, 'now').mockImplementation(() => 1725888000000); +}); + +afterAll(() => { + // Unlock Time + dateNowSpy.mockRestore(); +}); + describe('DateRangePicker component', () => { const mapper: Record = { open: valueHelper(booleanValue, { required: true, iterate: true }), From 5c435736048b328f656636c0c27b3727958abbcd Mon Sep 17 00:00:00 2001 From: anuradha9712 Date: Thu, 2 Jan 2025 20:09:54 +0400 Subject: [PATCH 03/13] chore: update design system esm bundle path in docs script --- docs/tools/update-mds.sh | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/docs/tools/update-mds.sh b/docs/tools/update-mds.sh index 890a55f845..775ec9ea59 100755 --- a/docs/tools/update-mds.sh +++ b/docs/tools/update-mds.sh @@ -1,4 +1,4 @@ # !bin/sh -sed -i.bak 's/boundaryElement: document.body/boundaryElement: {}/' node_modules/@innovaccer/design-system/dist/index.esm.js -sed -i.bak 's/boundariesElement: boundaryElement || document.body/boundaryElement: {}/' node_modules/@innovaccer/design-system/dist/index.esm.js +sed -i.bak 's/boundaryElement: document.body/boundaryElement: {}/' node_modules/@innovaccer/design-system/dist/esm/index.js +sed -i.bak 's/boundariesElement: boundaryElement || document.body/boundaryElement: {}/' node_modules/@innovaccer/design-system/dist/esm/index.js From 89642c47a830fa378d8e4bfea33bf7f3d187a63c Mon Sep 17 00:00:00 2001 From: anuradha9712 Date: Thu, 2 Jan 2025 17:02:29 +0400 Subject: [PATCH 04/13] fix(table): remove loading state from static header --- core/components/organisms/table/Header.tsx | 10 +- .../__snapshots__/Table.test.tsx.snap | 9006 ++++++++--------- 2 files changed, 4114 insertions(+), 4902 deletions(-) diff --git a/core/components/organisms/table/Header.tsx b/core/components/organisms/table/Header.tsx index 258e6c2d44..51ae856f5e 100644 --- a/core/components/organisms/table/Header.tsx +++ b/core/components/organisms/table/Header.tsx @@ -1,5 +1,5 @@ import * as React from 'react'; -import { Checkbox, Label, Input, Dropdown, Placeholder, PlaceholderParagraph, Button, Divider } from '@/index'; +import { Checkbox, Label, Input, Dropdown, Button, Divider } from '@/index'; import { updateSchemaFunction, ColumnSchema, @@ -283,11 +283,7 @@ export const Header = (props: HeaderProps) => { }} /> )} - {loading ? ( - - - - ) : ( + { <> {showSelectedLabel ? ( @@ -330,7 +326,7 @@ export const Header = (props: HeaderProps) => { )} - )} + } {dynamicColumn && (
diff --git a/core/components/organisms/table/__tests__/__snapshots__/Table.test.tsx.snap b/core/components/organisms/table/__tests__/__snapshots__/Table.test.tsx.snap index 6ab287241c..b65e49cda7 100644 --- a/core/components/organisms/table/__tests__/__snapshots__/Table.test.tsx.snap +++ b/core/components/organisms/table/__tests__/__snapshots__/Table.test.tsx.snap @@ -1808,23 +1808,21 @@ exports[`Table component async
-
-
- -
+ Showing 0 item +
-
+
-
-
- -
+ Showing 0 item +
-
+
-
-
- -
+ Showing 1-0 of 0 item +
-
+
-
-
- -
+ Showing 1-0 of 0 item +
-
+
-
-
- -
+ Showing 0 item +
-
+
-
-
- -
+ Showing 0 item +
-
+
-
-
- -
+ Showing 1-0 of 0 item +
-
+
-
-
- -
+ Showing 1-0 of 0 item +
-
+
-
-
- -
+ Showing 1-2 of 2 items +
-
+
-
-
- -
+ Showing 1-2 of 2 items +
-
+
-
-
- -
+ Showing 1-2 of 2 items +
-
+
-
-
- -
+ Showing 1-2 of 2 items +
-
+
-
-
- -
+ Showing 1-2 of 2 items +
-
+
-
-
- -
+ Showing 1-2 of 2 items +
-
+
-
-
- -
+ Showing 1-2 of 2 items +
-
+
-
-
- -
+ Showing 1-2 of 2 items +
-
+
-
-
-
- -
+ Showing 1-2 of 2 items +
-
+
-
-
-
- -
+ Showing 1-2 of 2 items +
-
+
-
-
-
- -
+ Showing 1-2 of 2 items +
-
+
-
-
-
- -
+ Showing 1-2 of 2 items +
-
+
+ +
+ +
+
+
+
- +