@axinom/mosaic-ui 0.39.0-rc.0 → 0.39.0-rc.3

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": "@axinom/mosaic-ui",
3
- "version": "0.39.0-rc.0",
3
+ "version": "0.39.0-rc.3",
4
4
  "description": "UI components for building Axinom Mosaic applications",
5
5
  "author": "Axinom",
6
6
  "license": "PROPRIETARY",
@@ -32,9 +32,9 @@
32
32
  "build-storybook": "storybook build"
33
33
  },
34
34
  "dependencies": {
35
- "@axinom/mosaic-core": "^0.4.12-rc.0",
35
+ "@axinom/mosaic-core": "^0.4.12-rc.3",
36
36
  "@faker-js/faker": "^7.4.0",
37
- "@popperjs/core": "^2.9.2",
37
+ "@popperjs/core": "^2.11.8",
38
38
  "clsx": "^1.1.0",
39
39
  "lodash": "^4.17.21",
40
40
  "luxon": "^3.3.0",
@@ -104,5 +104,5 @@
104
104
  "publishConfig": {
105
105
  "access": "public"
106
106
  },
107
- "gitHead": "4ec8f27911162c9f12edd2f061e194ec3daaf51c"
107
+ "gitHead": "1684458c348c8a75ff16d74ddc9650679413bba7"
108
108
  }
@@ -37,16 +37,16 @@ export interface AccordionProps {
37
37
 
38
38
  /**
39
39
  * Renders a component in which each child component of the class AccordionItem can be expanded.
40
- *
41
- * @example
40
+ *
41
+ * @example
42
42
  * <Accordion header={<b>Header</b>}>
43
- <AccordionItem header={<b>Item 1</b>}>
44
- <p>Content 1</p>
45
- </AccordionItem>
46
- <AccordionItem header={<b>Item 2</b>}>
47
- <p>Content 2</p>
48
- </AccordionItem>
49
- </Accordion>
43
+ * <AccordionItem header={<b>Item 1</b>}>
44
+ * <p>Content 1</p>
45
+ * </AccordionItem>
46
+ * <AccordionItem header={<b>Item 2</b>}>
47
+ * <p>Content 2</p>
48
+ * </AccordionItem>
49
+ * </Accordion>
50
50
  */
51
51
  export const Accordion: React.FC<AccordionProps> = ({
52
52
  header,
@@ -27,8 +27,8 @@ export interface AccordionItemProps {
27
27
  * Renders a single Accordion Item
28
28
  * @example
29
29
  * <AccordionItem header={<b>Item 2</b>}>
30
- <p>Content 2</p>
31
- </AccordionItem>
30
+ * <p>Content 2</p>
31
+ * </AccordionItem>
32
32
  */
33
33
  export const AccordionItem: React.FC<AccordionItemProps> = ({
34
34
  header,
@@ -1,6 +1,2 @@
1
1
  export { ConfirmDialog, useConfirmationDelay } from './ConfirmDialog';
2
- export {
3
- ConfirmationConfig,
4
- ConfirmationMode,
5
- ConfirmationPlacement,
6
- } from './ConfirmDialog.models';
2
+ export * from './ConfirmDialog.models';
@@ -322,7 +322,7 @@ describe('DynamicListDataEntry', () => {
322
322
  e: 'event',
323
323
  };
324
324
 
325
- const propertyName = columnWithRenderer[0].propertyName;
325
+ const propertyName = columnWithRenderer[0].propertyName!;
326
326
 
327
327
  const wrapper = shallow(
328
328
  <DynamicListDataEntry
@@ -356,7 +356,7 @@ describe('DynamicListDataEntry', () => {
356
356
  e: 'event',
357
357
  };
358
358
  const mockNewValue = 'test-value';
359
- const propertyName = columnWithRenderer[0].propertyName;
359
+ const propertyName = columnWithRenderer[0].propertyName!;
360
360
  const mockNewPos = 5;
361
361
  const mockPosKey = 'id';
362
362
 
@@ -399,7 +399,7 @@ describe('DynamicListDataEntry', () => {
399
399
  e: 'event',
400
400
  };
401
401
  const mockNewValue = 'test-value';
402
- const propertyName = columnWithRenderer[0].propertyName;
402
+ const propertyName = columnWithRenderer[0].propertyName!;
403
403
  const mockNewPos = 5;
404
404
  const mockPosKey = 'id';
405
405
 
@@ -440,7 +440,7 @@ describe('DynamicListDataEntry', () => {
440
440
  e: 'event',
441
441
  };
442
442
  const mockNewValue = 'test-value';
443
- const propertyName = columnWithRenderer[0].propertyName;
443
+ const propertyName = columnWithRenderer[0].propertyName!;
444
444
  const mockPosKey = 'id';
445
445
 
446
446
  const wrapper = shallow(
@@ -481,7 +481,7 @@ describe('DynamicListDataEntry', () => {
481
481
  e: 'event',
482
482
  };
483
483
  const mockNewValue = 'test-value';
484
- const propertyName = columnWithRenderer[0].propertyName;
484
+ const propertyName = columnWithRenderer[0].propertyName!;
485
485
  const mockPosKey = 'id';
486
486
  const mockNewPos = 5;
487
487
 
@@ -531,7 +531,7 @@ describe('DynamicListDataEntry', () => {
531
531
  },
532
532
  ];
533
533
 
534
- const propertyName = mockColumns[0].propertyName;
534
+ const propertyName = mockColumns[0].propertyName!;
535
535
 
536
536
  const wrapper = shallow(
537
537
  <DynamicListDataEntry
@@ -138,7 +138,7 @@ describe('DynamicListRow', () => {
138
138
 
139
139
  columns.forEach((column, idx) => {
140
140
  expect(column.text()).toBe(
141
- String(defaultData[defaultColumns[idx].propertyName]),
141
+ String(defaultData[defaultColumns[idx].propertyName!]),
142
142
  );
143
143
  });
144
144
  });
@@ -245,11 +245,8 @@ initializeUi({
245
245
  removeIndicator: (args) => {
246
246
  action('removeIndicator')(args);
247
247
  },
248
- showSaveIndicator: () => {
249
- action('showSaveIndicator')();
250
- },
251
- hideSaveIndicator: () => {
252
- action('hideSaveIndicator')();
248
+ setSaveIndicator: () => {
249
+ action('setSaveIndicator')();
253
250
  },
254
251
  on: (event, callback) => {
255
252
  action('on')(event, callback);
@@ -1,4 +1,4 @@
1
- import { mount, ReactWrapper, shallow, ShallowWrapper } from 'enzyme';
1
+ import { mount, ReactWrapper, shallow } from 'enzyme';
2
2
  import React from 'react';
3
3
  import { act } from 'react-dom/test-utils';
4
4
  import { config } from 'react-transition-group';
@@ -12,7 +12,7 @@ describe('CustomTags', () => {
12
12
 
13
13
  const getTagsFromDOM = (wrapper: ReactWrapper): string[] =>
14
14
  wrapper.find('span > span').map((node) => node.text());
15
- const getTagsFromShallowDOM = (wrapper: ShallowWrapper): string[] =>
15
+ const getTagsFromShallowDOM = (wrapper: ReactWrapper): string[] =>
16
16
  wrapper.find('span > span').map((node) => node.text());
17
17
 
18
18
  it('renders the component without crashing', () => {
@@ -1,7 +1,10 @@
1
1
  import { mount, shallow } from 'enzyme';
2
2
  import React from 'react';
3
3
  import { Button } from '../../Buttons';
4
- import { ButtonContext } from '../../Buttons/Button.model';
4
+ import {
5
+ ButtonContext,
6
+ CommonJsButtonOptions,
7
+ } from '../../Buttons/Button.model';
5
8
  import { ListCheckBox } from './ListCheckBox';
6
9
 
7
10
  describe('ListCheckBox', () => {
@@ -16,7 +19,9 @@ describe('ListCheckBox', () => {
16
19
 
17
20
  const button = wrapper.find(Button);
18
21
 
19
- expect(button.props().buttonContext).toBe(ButtonContext.Context);
22
+ expect((button.props() as CommonJsButtonOptions).buttonContext).toBe(
23
+ ButtonContext.Context,
24
+ );
20
25
  });
21
26
 
22
27
  it('sets its state to isChecked prop', () => {
@@ -24,7 +29,9 @@ describe('ListCheckBox', () => {
24
29
 
25
30
  const button = wrapper.find(Button);
26
31
 
27
- expect(button.props().buttonContext).toBe(ButtonContext.Active);
32
+ expect((button.props() as CommonJsButtonOptions).buttonContext).toBe(
33
+ ButtonContext.Active,
34
+ );
28
35
  });
29
36
 
30
37
  it(`raises the onCheckBoxToggled with the inverse of the 'isChecked' prop`, () => {
@@ -57,7 +57,7 @@ describe('ListRow', () => {
57
57
  expect(actualColumns).toHaveLength(expectedColumns.length);
58
58
 
59
59
  actualColumns.forEach((column, idx) => {
60
- const expectedPropertyName = expectedColumns[idx].propertyName;
60
+ const expectedPropertyName = expectedColumns[idx].propertyName!;
61
61
  expect(column.key()).toEqual(expectedPropertyName);
62
62
 
63
63
  expect(column.text()).toEqual(mockExplorerData[expectedPropertyName]);
@@ -2,10 +2,8 @@ import { mount, shallow } from 'enzyme';
2
2
  import React from 'react';
3
3
  import { noop } from '../../helpers/utils';
4
4
  import { PageHeader } from './PageHeader';
5
- import {
6
- PageHeaderAction,
7
- PageHeaderActionProps,
8
- } from './PageHeaderAction/PageHeaderAction';
5
+ import { PageHeaderAction } from './PageHeaderAction/PageHeaderAction';
6
+ import { PageHeaderActionProps } from './PageHeaderAction/PageHeaderAction.model';
9
7
  import { PageHeaderBulkActions } from './PageHeaderBulkActions/PageHeaderBulkActions';
10
8
 
11
9
  const defaultbulkActions: PageHeaderActionProps[] = [