@digigov/react-core 2.0.0-cbc56209 → 2.0.0-fec6f1f7
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/{src/AutoCompleteWrapper → AutoCompleteContainer}/__snapshots__/index.test.tsx.snap +4 -4
- package/AutoCompleteContainer/index.d.ts +22 -0
- package/{AutoCompleteWrapper → AutoCompleteContainer}/index.js +5 -5
- package/AutoCompleteContainer/index.test/index.js +7 -0
- package/{AutoCompleteStatusWrapper → AutoCompleteContainer}/index.test/package.json +1 -1
- package/{AutoCompleteWrapper → AutoCompleteContainer}/package.json +1 -1
- package/AutoCompleteInput/index.d.ts +1 -9
- package/AutoCompleteInput/index.js +2 -4
- package/AutoCompleteInput/index.test/index.js +5 -19
- package/AutoCompleteMultipleInput/index.d.ts +9 -0
- package/AutoCompleteMultipleInput/index.js +21 -0
- package/{AutoCompleteStatusWrapper → AutoCompleteMultipleInput}/package.json +1 -1
- package/AutoCompleteMultipleInputContainer/index.d.ts +12 -0
- package/AutoCompleteMultipleInputContainer/index.js +24 -0
- package/AutoCompleteMultipleInputContainer/package.json +6 -0
- package/AutoCompleteResultList/index.d.ts +1 -10
- package/AutoCompleteResultList/index.js +2 -3
- package/AutoCompleteResultList/index.test/index.js +0 -14
- package/AutoCompleteStatus/__snapshots__/index.test.tsx.snap +2 -2
- package/AutoCompleteStatus/index.d.ts +1 -1
- package/AutoCompleteStatus/index.js +2 -2
- package/{AutoCompleteStatusWrapper → AutoCompleteStatusContainer}/__snapshots__/index.test.tsx.snap +4 -4
- package/AutoCompleteStatusContainer/index.d.ts +10 -0
- package/{AutoCompleteStatusWrapper → AutoCompleteStatusContainer}/index.js +5 -5
- package/AutoCompleteStatusContainer/index.test/index.js +7 -0
- package/AutoCompleteStatusContainer/index.test/package.json +6 -0
- package/{AutoCompleteWrapper/index.test → AutoCompleteStatusContainer}/package.json +1 -1
- package/DropdownContent/index.d.ts +9 -1
- package/DropdownContent/index.js +6 -5
- package/ImageLogo/index.js +0 -1
- package/Unpurge/index.js +1 -1
- package/{AutoCompleteWrapper → cjs/AutoCompleteContainer}/__snapshots__/index.test.tsx.snap +4 -4
- package/cjs/{AutoCompleteWrapper → AutoCompleteContainer}/index.js +6 -6
- package/cjs/{AutoCompleteWrapper → AutoCompleteContainer}/index.test/index.js +2 -2
- package/cjs/AutoCompleteInput/index.js +2 -4
- package/cjs/AutoCompleteInput/index.test/index.js +5 -19
- package/cjs/AutoCompleteMultipleInput/index.js +28 -0
- package/cjs/AutoCompleteMultipleInputContainer/index.js +31 -0
- package/cjs/AutoCompleteResultList/index.js +2 -3
- package/cjs/AutoCompleteResultList/index.test/index.js +0 -14
- package/cjs/AutoCompleteStatus/__snapshots__/index.test.tsx.snap +2 -2
- package/cjs/AutoCompleteStatus/index.js +2 -2
- package/cjs/{AutoCompleteStatusWrapper → AutoCompleteStatusContainer}/__snapshots__/index.test.tsx.snap +4 -4
- package/cjs/{AutoCompleteStatusWrapper → AutoCompleteStatusContainer}/index.js +6 -6
- package/cjs/{AutoCompleteStatusWrapper → AutoCompleteStatusContainer}/index.test/index.js +2 -2
- package/cjs/DropdownContent/index.js +6 -5
- package/cjs/ImageLogo/index.js +0 -1
- package/cjs/Unpurge/index.js +1 -1
- package/cjs/index.js +26 -4
- package/cjs/lazy/index.js +30 -12
- package/cjs/registry/index.js +8 -4
- package/index.d.ts +3 -1
- package/index.js +4 -2
- package/lazy/index.js +24 -10
- package/lazy.d.ts +7 -5
- package/package.json +3 -3
- package/registry/index.js +8 -4
- package/registry.d.ts +4 -2
- package/{cjs/AutoCompleteWrapper → src/AutoCompleteContainer}/__snapshots__/index.test.tsx.snap +4 -4
- package/src/{AutoCompleteWrapper → AutoCompleteContainer}/index.test.tsx +2 -2
- package/src/{AutoCompleteWrapper → AutoCompleteContainer}/index.tsx +8 -8
- package/src/AutoCompleteInput/index.test.tsx +4 -12
- package/src/AutoCompleteInput/index.tsx +2 -11
- package/src/AutoCompleteMultipleInput/index.tsx +28 -0
- package/src/AutoCompleteMultipleInputContainer/index.tsx +38 -0
- package/src/AutoCompleteResultList/index.test.tsx +0 -20
- package/src/AutoCompleteResultList/index.tsx +1 -13
- package/src/AutoCompleteStatus/__snapshots__/index.test.tsx.snap +2 -2
- package/src/AutoCompleteStatus/index.tsx +2 -2
- package/src/AutoCompleteStatusContainer/__snapshots__/index.test.tsx.snap +16 -0
- package/src/AutoCompleteStatusContainer/index.test.tsx +10 -0
- package/src/AutoCompleteStatusContainer/index.tsx +28 -0
- package/src/DropdownContent/index.tsx +10 -1
- package/src/ImageLogo/index.tsx +0 -1
- package/src/Unpurge/index.tsx +3 -0
- package/src/index.ts +3 -1
- package/src/lazy.js +4 -2
- package/src/registry.js +8 -4
- package/AutoCompleteStatusWrapper/index.d.ts +0 -10
- package/AutoCompleteStatusWrapper/index.test/index.js +0 -7
- package/AutoCompleteWrapper/index.d.ts +0 -22
- package/AutoCompleteWrapper/index.test/index.js +0 -7
- package/src/AutoCompleteStatusWrapper/__snapshots__/index.test.tsx.snap +0 -16
- package/src/AutoCompleteStatusWrapper/index.test.tsx +0 -10
- package/src/AutoCompleteStatusWrapper/index.tsx +0 -28
- /package/{AutoCompleteStatusWrapper → AutoCompleteContainer}/index.test.d.ts +0 -0
- /package/{AutoCompleteWrapper → AutoCompleteStatusContainer}/index.test.d.ts +0 -0
package/registry/index.js
CHANGED
|
@@ -13,13 +13,15 @@ import * as _digigov_react_core_AdminMain from '@digigov/react-core/AdminMain';
|
|
|
13
13
|
import * as _digigov_react_core_AdminTopSection from '@digigov/react-core/AdminTopSection';
|
|
14
14
|
import * as _digigov_react_core_Aside from '@digigov/react-core/Aside';
|
|
15
15
|
import * as _digigov_react_core_AutoCompleteAssistiveHint from '@digigov/react-core/AutoCompleteAssistiveHint';
|
|
16
|
+
import * as _digigov_react_core_AutoCompleteContainer from '@digigov/react-core/AutoCompleteContainer';
|
|
16
17
|
import * as _digigov_react_core_AutoCompleteInput from '@digigov/react-core/AutoCompleteInput';
|
|
17
18
|
import * as _digigov_react_core_AutoCompleteInputTypeahead from '@digigov/react-core/AutoCompleteInputTypeahead';
|
|
19
|
+
import * as _digigov_react_core_AutoCompleteMultipleInput from '@digigov/react-core/AutoCompleteMultipleInput';
|
|
20
|
+
import * as _digigov_react_core_AutoCompleteMultipleInputContainer from '@digigov/react-core/AutoCompleteMultipleInputContainer';
|
|
18
21
|
import * as _digigov_react_core_AutoCompleteResultList from '@digigov/react-core/AutoCompleteResultList';
|
|
19
22
|
import * as _digigov_react_core_AutoCompleteResultListItem from '@digigov/react-core/AutoCompleteResultListItem';
|
|
20
23
|
import * as _digigov_react_core_AutoCompleteStatus from '@digigov/react-core/AutoCompleteStatus';
|
|
21
|
-
import * as
|
|
22
|
-
import * as _digigov_react_core_AutoCompleteWrapper from '@digigov/react-core/AutoCompleteWrapper';
|
|
24
|
+
import * as _digigov_react_core_AutoCompleteStatusContainer from '@digigov/react-core/AutoCompleteStatusContainer';
|
|
23
25
|
import * as _digigov_react_core_BackLink from '@digigov/react-core/BackLink';
|
|
24
26
|
import * as _digigov_react_core_BackToTopContainer from '@digigov/react-core/BackToTopContainer';
|
|
25
27
|
import * as _digigov_react_core_BackToTopLimit from '@digigov/react-core/BackToTopLimit';
|
|
@@ -271,13 +273,15 @@ export default {
|
|
|
271
273
|
'@digigov/react-core/AdminTopSection': lazyImport(_digigov_react_core_AdminTopSection),
|
|
272
274
|
'@digigov/react-core/Aside': lazyImport(_digigov_react_core_Aside),
|
|
273
275
|
'@digigov/react-core/AutoCompleteAssistiveHint': lazyImport(_digigov_react_core_AutoCompleteAssistiveHint),
|
|
276
|
+
'@digigov/react-core/AutoCompleteContainer': lazyImport(_digigov_react_core_AutoCompleteContainer),
|
|
274
277
|
'@digigov/react-core/AutoCompleteInput': lazyImport(_digigov_react_core_AutoCompleteInput),
|
|
275
278
|
'@digigov/react-core/AutoCompleteInputTypeahead': lazyImport(_digigov_react_core_AutoCompleteInputTypeahead),
|
|
279
|
+
'@digigov/react-core/AutoCompleteMultipleInput': lazyImport(_digigov_react_core_AutoCompleteMultipleInput),
|
|
280
|
+
'@digigov/react-core/AutoCompleteMultipleInputContainer': lazyImport(_digigov_react_core_AutoCompleteMultipleInputContainer),
|
|
276
281
|
'@digigov/react-core/AutoCompleteResultList': lazyImport(_digigov_react_core_AutoCompleteResultList),
|
|
277
282
|
'@digigov/react-core/AutoCompleteResultListItem': lazyImport(_digigov_react_core_AutoCompleteResultListItem),
|
|
278
283
|
'@digigov/react-core/AutoCompleteStatus': lazyImport(_digigov_react_core_AutoCompleteStatus),
|
|
279
|
-
'@digigov/react-core/
|
|
280
|
-
'@digigov/react-core/AutoCompleteWrapper': lazyImport(_digigov_react_core_AutoCompleteWrapper),
|
|
284
|
+
'@digigov/react-core/AutoCompleteStatusContainer': lazyImport(_digigov_react_core_AutoCompleteStatusContainer),
|
|
281
285
|
'@digigov/react-core/BackLink': lazyImport(_digigov_react_core_BackLink),
|
|
282
286
|
'@digigov/react-core/BackToTopContainer': lazyImport(_digigov_react_core_BackToTopContainer),
|
|
283
287
|
'@digigov/react-core/BackToTopLimit': lazyImport(_digigov_react_core_BackToTopLimit),
|
package/registry.d.ts
CHANGED
|
@@ -14,13 +14,15 @@ declare const _default: {
|
|
|
14
14
|
'@digigov/react-core/AdminTopSection': {};
|
|
15
15
|
'@digigov/react-core/Aside': {};
|
|
16
16
|
'@digigov/react-core/AutoCompleteAssistiveHint': {};
|
|
17
|
+
'@digigov/react-core/AutoCompleteContainer': {};
|
|
17
18
|
'@digigov/react-core/AutoCompleteInput': {};
|
|
18
19
|
'@digigov/react-core/AutoCompleteInputTypeahead': {};
|
|
20
|
+
'@digigov/react-core/AutoCompleteMultipleInput': {};
|
|
21
|
+
'@digigov/react-core/AutoCompleteMultipleInputContainer': {};
|
|
19
22
|
'@digigov/react-core/AutoCompleteResultList': {};
|
|
20
23
|
'@digigov/react-core/AutoCompleteResultListItem': {};
|
|
21
24
|
'@digigov/react-core/AutoCompleteStatus': {};
|
|
22
|
-
'@digigov/react-core/
|
|
23
|
-
'@digigov/react-core/AutoCompleteWrapper': {};
|
|
25
|
+
'@digigov/react-core/AutoCompleteStatusContainer': {};
|
|
24
26
|
'@digigov/react-core/BackLink': {};
|
|
25
27
|
'@digigov/react-core/BackToTopContainer': {};
|
|
26
28
|
'@digigov/react-core/BackToTopLimit': {};
|
package/{cjs/AutoCompleteWrapper → src/AutoCompleteContainer}/__snapshots__/index.test.tsx.snap
RENAMED
|
@@ -1,16 +1,16 @@
|
|
|
1
1
|
// Jest Snapshot v1, https://goo.gl/fbAQLP
|
|
2
2
|
|
|
3
3
|
exports[`renders the AdminContainer with no props 1`] = `
|
|
4
|
-
<ForwardRef(
|
|
4
|
+
<ForwardRef(AutoCompleteContainer)>
|
|
5
5
|
<ForwardRef(Base)
|
|
6
6
|
as="div"
|
|
7
|
-
className="ds-
|
|
7
|
+
className="ds-autocomplete__container"
|
|
8
8
|
>
|
|
9
9
|
<div
|
|
10
|
-
className="ds-
|
|
10
|
+
className="ds-autocomplete__container"
|
|
11
11
|
>
|
|
12
12
|
hello
|
|
13
13
|
</div>
|
|
14
14
|
</ForwardRef(Base)>
|
|
15
|
-
</ForwardRef(
|
|
15
|
+
</ForwardRef(AutoCompleteContainer)>
|
|
16
16
|
`;
|
|
@@ -1,10 +1,10 @@
|
|
|
1
1
|
import React from 'react';
|
|
2
2
|
import { mount } from 'enzyme';
|
|
3
3
|
|
|
4
|
-
import
|
|
4
|
+
import AutoCompleteContainer from '@digigov/react-core/AutoCompleteContainer';
|
|
5
5
|
|
|
6
6
|
it('renders the AdminContainer with no props', () => {
|
|
7
7
|
expect(
|
|
8
|
-
mount(<
|
|
8
|
+
mount(<AutoCompleteContainer>hello</AutoCompleteContainer>)
|
|
9
9
|
).toMatchSnapshot();
|
|
10
10
|
});
|
|
@@ -2,7 +2,7 @@ import React from 'react';
|
|
|
2
2
|
import clsx from 'clsx';
|
|
3
3
|
import Base, { BaseProps } from '@digigov/react-core/Base';
|
|
4
4
|
|
|
5
|
-
export interface
|
|
5
|
+
export interface AutoCompleteContainerProps extends BaseProps<'div'> {
|
|
6
6
|
/**
|
|
7
7
|
* width is optional.
|
|
8
8
|
* Use width prop to define a custom width in your component.
|
|
@@ -17,19 +17,19 @@ export interface AutoCompleteWrapperProps extends BaseProps<'div'> {
|
|
|
17
17
|
width?: '25%' | '33.3%' | '50%' | '66.6%' | '75%' | '100%' | 'full';
|
|
18
18
|
}
|
|
19
19
|
/**
|
|
20
|
-
*
|
|
21
|
-
* Use
|
|
20
|
+
* AutoCompleteContainer is a wrapper for autocomplete element.
|
|
21
|
+
* Use AutoCompleteContainer to wrap autocomplete elements.
|
|
22
22
|
*/
|
|
23
|
-
export const
|
|
23
|
+
export const AutoCompleteContainer = React.forwardRef<
|
|
24
24
|
HTMLDivElement,
|
|
25
|
-
|
|
26
|
-
>(function
|
|
25
|
+
AutoCompleteContainerProps
|
|
26
|
+
>(function AutoCompleteContainer({ className, width, children, ...props }, ref) {
|
|
27
27
|
return (
|
|
28
28
|
<Base
|
|
29
29
|
as="div"
|
|
30
30
|
ref={ref}
|
|
31
31
|
className={clsx(className, {
|
|
32
|
-
'ds-
|
|
32
|
+
'ds-autocomplete__container': true,
|
|
33
33
|
'ds-!-width-one-quarter': width === '25%',
|
|
34
34
|
'ds-!-width-one-third': width === '33.3%',
|
|
35
35
|
'ds-!-width-one-half': width === '50%',
|
|
@@ -44,4 +44,4 @@ export const AutoCompleteWrapper = React.forwardRef<
|
|
|
44
44
|
);
|
|
45
45
|
});
|
|
46
46
|
|
|
47
|
-
export default
|
|
47
|
+
export default AutoCompleteContainer;
|
|
@@ -7,22 +7,14 @@ it('renders the AutoCompleteInput with no props', () => {
|
|
|
7
7
|
expect(mount(<AutoCompleteInput />)).toMatchSnapshot();
|
|
8
8
|
});
|
|
9
9
|
|
|
10
|
-
it('renders the AutoCompleteInput with
|
|
11
|
-
expect(mount(<AutoCompleteInput showAllValues />)).toMatchSnapshot();
|
|
12
|
-
});
|
|
13
|
-
|
|
14
|
-
it('renders the AutoCompleteInput with showAllValues', () => {
|
|
15
|
-
expect(mount(<AutoCompleteInput showAllValues />)).toMatchSnapshot();
|
|
16
|
-
});
|
|
17
|
-
|
|
18
|
-
it('renders the AutoCompleteInput with showAllValues isFocused', () => {
|
|
10
|
+
it('renders the AutoCompleteInput with isFocused', () => {
|
|
19
11
|
expect(
|
|
20
|
-
mount(<AutoCompleteInput isFocused
|
|
12
|
+
mount(<AutoCompleteInput isFocused />)
|
|
21
13
|
).toMatchSnapshot();
|
|
22
14
|
});
|
|
23
15
|
|
|
24
|
-
it('renders the AutoCompleteInput with
|
|
16
|
+
it('renders the AutoCompleteInput with isFocused and name props', () => {
|
|
25
17
|
expect(
|
|
26
|
-
mount(<AutoCompleteInput name="some-name" isFocused
|
|
18
|
+
mount(<AutoCompleteInput name="some-name" isFocused />)
|
|
27
19
|
).toMatchSnapshot();
|
|
28
20
|
});
|
|
@@ -9,14 +9,7 @@ export interface AutoCompleteInputProps extends BaseProps<'input'> {
|
|
|
9
9
|
* @value false
|
|
10
10
|
*/
|
|
11
11
|
isFocused?: boolean;
|
|
12
|
-
|
|
13
|
-
* showAllValues is optional. The default value is false.
|
|
14
|
-
* showAllValues prop is used to change the css input.
|
|
15
|
-
* @value true
|
|
16
|
-
* @value false
|
|
17
|
-
* @default false
|
|
18
|
-
*/
|
|
19
|
-
showAllValues?: boolean;
|
|
12
|
+
|
|
20
13
|
}
|
|
21
14
|
/**
|
|
22
15
|
* AutoCompleteInput component is used to display the value that the user is typing.
|
|
@@ -26,7 +19,7 @@ export const AutoCompleteInput = React.forwardRef<
|
|
|
26
19
|
HTMLInputElement,
|
|
27
20
|
AutoCompleteInputProps
|
|
28
21
|
>(function AutoCompleteInput(
|
|
29
|
-
{ name, isFocused,
|
|
22
|
+
{ name, isFocused, className, ...props },
|
|
30
23
|
ref
|
|
31
24
|
) {
|
|
32
25
|
return (
|
|
@@ -37,8 +30,6 @@ export const AutoCompleteInput = React.forwardRef<
|
|
|
37
30
|
ref={ref}
|
|
38
31
|
className={clsx(className, {
|
|
39
32
|
'ds-autocomplete__input': true,
|
|
40
|
-
'ds-autocomplete__input--default': showAllValues === false,
|
|
41
|
-
'ds-autocomplete__input--show-all-values': showAllValues,
|
|
42
33
|
'ds-autocomplete__input--focused': isFocused,
|
|
43
34
|
})}
|
|
44
35
|
{...props}
|
|
@@ -0,0 +1,28 @@
|
|
|
1
|
+
import React from 'react';
|
|
2
|
+
import clsx from 'clsx';
|
|
3
|
+
import Base, { BaseProps } from '@digigov/react-core/Base';
|
|
4
|
+
|
|
5
|
+
export interface AutoCompleteMultipleInputProps extends BaseProps<'input'> {}
|
|
6
|
+
/**
|
|
7
|
+
* AutoCompleteMultipleInput is used inside AutoCompleteMultipleInputContainer for multiple values input.
|
|
8
|
+
*/
|
|
9
|
+
export const AutoCompleteMultipleInput = React.forwardRef<
|
|
10
|
+
HTMLInputElement,
|
|
11
|
+
AutoCompleteMultipleInputProps
|
|
12
|
+
>(function AutoCompleteMultipleInput({ children, className, ...props }, ref) {
|
|
13
|
+
return (
|
|
14
|
+
<Base
|
|
15
|
+
as="input"
|
|
16
|
+
type="text"
|
|
17
|
+
ref={ref}
|
|
18
|
+
className={clsx(className, {
|
|
19
|
+
'ds-autocomplete__multi-input': true,
|
|
20
|
+
})}
|
|
21
|
+
{...props}
|
|
22
|
+
>
|
|
23
|
+
{children}
|
|
24
|
+
</Base>
|
|
25
|
+
);
|
|
26
|
+
});
|
|
27
|
+
|
|
28
|
+
export default AutoCompleteMultipleInput;
|
|
@@ -0,0 +1,38 @@
|
|
|
1
|
+
import React from 'react';
|
|
2
|
+
import clsx from 'clsx';
|
|
3
|
+
import Base, { BaseProps } from '@digigov/react-core/Base';
|
|
4
|
+
|
|
5
|
+
export interface AutoCompleteMultipleInputContainerProps
|
|
6
|
+
extends BaseProps<'div'> {
|
|
7
|
+
open?: boolean;
|
|
8
|
+
isFocused?: boolean;
|
|
9
|
+
numberOfSelected?: 1 | 2 | 3 | 'all';
|
|
10
|
+
}
|
|
11
|
+
/**
|
|
12
|
+
* Use AutoCompleteMultipleInputContainer to accept multiple values input.
|
|
13
|
+
*/
|
|
14
|
+
export const AutoCompleteMultipleInputContainer = React.forwardRef<
|
|
15
|
+
HTMLDivElement,
|
|
16
|
+
AutoCompleteMultipleInputContainerProps
|
|
17
|
+
>(function AutoCompleteMultipleInputContainer(
|
|
18
|
+
{ numberOfSelected = 'all', open, children, isFocused, className, ...props },
|
|
19
|
+
ref
|
|
20
|
+
) {
|
|
21
|
+
return (
|
|
22
|
+
<Base
|
|
23
|
+
as="div"
|
|
24
|
+
ref={ref}
|
|
25
|
+
className={clsx(className, {
|
|
26
|
+
'ds-autocomplete__multi-input-container': true,
|
|
27
|
+
'ds-autocomplete__multi-input-container--focused': isFocused,
|
|
28
|
+
[`ds-autocomplete__multi-input-container--${numberOfSelected}`]: typeof(numberOfSelected) === 'number'
|
|
29
|
+
|
|
30
|
+
})}
|
|
31
|
+
{...props}
|
|
32
|
+
>
|
|
33
|
+
{children}
|
|
34
|
+
</Base>
|
|
35
|
+
);
|
|
36
|
+
});
|
|
37
|
+
|
|
38
|
+
export default AutoCompleteMultipleInputContainer;
|
|
@@ -14,23 +14,3 @@ it('renders the AutoCompleteResultList with isVisible props', () => {
|
|
|
14
14
|
mount(<AutoCompleteResultList isVisible>Hello</AutoCompleteResultList>)
|
|
15
15
|
).toMatchSnapshot();
|
|
16
16
|
});
|
|
17
|
-
|
|
18
|
-
it('renders the AutoCompleteResultList with isVisible displayMenu="inline props', () => {
|
|
19
|
-
expect(
|
|
20
|
-
mount(
|
|
21
|
-
<AutoCompleteResultList isVisible displayMenu="inline">
|
|
22
|
-
Hello
|
|
23
|
-
</AutoCompleteResultList>
|
|
24
|
-
)
|
|
25
|
-
).toMatchSnapshot();
|
|
26
|
-
});
|
|
27
|
-
|
|
28
|
-
it('renders the AutoCompleteResultList with isVisible displayMenu="overlay props', () => {
|
|
29
|
-
expect(
|
|
30
|
-
mount(
|
|
31
|
-
<AutoCompleteResultList isVisible displayMenu="overlay">
|
|
32
|
-
Hello
|
|
33
|
-
</AutoCompleteResultList>
|
|
34
|
-
)
|
|
35
|
-
).toMatchSnapshot();
|
|
36
|
-
});
|
|
@@ -13,15 +13,6 @@ export interface AutoCompleteResultListProps extends BaseProps<'ul'> {
|
|
|
13
13
|
* @default false
|
|
14
14
|
*/
|
|
15
15
|
isVisible?: boolean;
|
|
16
|
-
/**
|
|
17
|
-
* displayMenu is optional.
|
|
18
|
-
* Use displayMenu to choose the display of the manue
|
|
19
|
-
* default value is inline.
|
|
20
|
-
*
|
|
21
|
-
* @value 'inline'
|
|
22
|
-
* @value 'overlay'
|
|
23
|
-
*/
|
|
24
|
-
displayMenu?: 'inline' | 'overlay';
|
|
25
16
|
}
|
|
26
17
|
/**
|
|
27
18
|
* AutoCompleteResultList component is used for listing items.
|
|
@@ -31,7 +22,7 @@ export const AutoCompleteResultList = React.forwardRef<
|
|
|
31
22
|
HTMLUListElement,
|
|
32
23
|
AutoCompleteResultListProps
|
|
33
24
|
>(function List(
|
|
34
|
-
{ isVisible = false,
|
|
25
|
+
{ isVisible = false, className, children, ...props },
|
|
35
26
|
ref
|
|
36
27
|
) {
|
|
37
28
|
return (
|
|
@@ -40,9 +31,6 @@ export const AutoCompleteResultList = React.forwardRef<
|
|
|
40
31
|
ref={ref}
|
|
41
32
|
className={clsx(className, {
|
|
42
33
|
'ds-autocomplete__menu': true,
|
|
43
|
-
'ds-autocomplete__menu--inline': displayMenu === 'inline',
|
|
44
|
-
'ds-autocomplete__menu--overlay': displayMenu === 'overlay',
|
|
45
|
-
'ds-autocomplete__menu--visible': isVisible,
|
|
46
34
|
'ds-autocomplete__menu--hidden': isVisible === false,
|
|
47
35
|
})}
|
|
48
36
|
{...props}
|
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
// Jest Snapshot v1, https://goo.gl/fbAQLP
|
|
2
2
|
|
|
3
3
|
exports[`renders the AdminContainer with no props 1`] = `
|
|
4
|
-
<ForwardRef(
|
|
4
|
+
<ForwardRef(AutoCompleteStatusContainer)>
|
|
5
5
|
<ForwardRef(Base)
|
|
6
6
|
aria-atomic="true"
|
|
7
7
|
aria-live="polite"
|
|
@@ -18,5 +18,5 @@ exports[`renders the AdminContainer with no props 1`] = `
|
|
|
18
18
|
hello
|
|
19
19
|
</div>
|
|
20
20
|
</ForwardRef(Base)>
|
|
21
|
-
</ForwardRef(
|
|
21
|
+
</ForwardRef(AutoCompleteStatusContainer)>
|
|
22
22
|
`;
|
|
@@ -5,12 +5,12 @@ import Base, { BaseProps } from '@digigov/react-core/Base';
|
|
|
5
5
|
export interface AutoCompleteStatusProps extends BaseProps<'div'> { }
|
|
6
6
|
/**
|
|
7
7
|
* AutoCompleteStatus is a div element for displaying the autocomplete status.
|
|
8
|
-
* Use AutoCompleteStatus inside
|
|
8
|
+
* Use AutoCompleteStatus inside AutoCompleteStatusContainer wrapper.
|
|
9
9
|
*/
|
|
10
10
|
export const AutoCompleteStatus = React.forwardRef<
|
|
11
11
|
HTMLDivElement,
|
|
12
12
|
AutoCompleteStatusProps
|
|
13
|
-
>(function
|
|
13
|
+
>(function AutoCompleteStatusContainer({ className, children, ...props }, ref) {
|
|
14
14
|
return (
|
|
15
15
|
<Base
|
|
16
16
|
as="div"
|
|
@@ -0,0 +1,16 @@
|
|
|
1
|
+
// Jest Snapshot v1, https://goo.gl/fbAQLP
|
|
2
|
+
|
|
3
|
+
exports[`renders the AdminContainer with no props 1`] = `
|
|
4
|
+
<ForwardRef(AutoCompleteStatusContainer)>
|
|
5
|
+
<ForwardRef(Base)
|
|
6
|
+
as="div"
|
|
7
|
+
className="ds-autocomplete__status__container"
|
|
8
|
+
>
|
|
9
|
+
<div
|
|
10
|
+
className="ds-autocomplete__status__container"
|
|
11
|
+
>
|
|
12
|
+
hello
|
|
13
|
+
</div>
|
|
14
|
+
</ForwardRef(Base)>
|
|
15
|
+
</ForwardRef(AutoCompleteStatusContainer)>
|
|
16
|
+
`;
|
|
@@ -0,0 +1,10 @@
|
|
|
1
|
+
import React from 'react';
|
|
2
|
+
import { mount } from 'enzyme';
|
|
3
|
+
|
|
4
|
+
import AutoCompleteStatusContainer from '@digigov/react-core/AutoCompleteStatusContainer';
|
|
5
|
+
|
|
6
|
+
it('renders the AdminContainer with no props', () => {
|
|
7
|
+
expect(
|
|
8
|
+
mount(<AutoCompleteStatusContainer>hello</AutoCompleteStatusContainer>)
|
|
9
|
+
).toMatchSnapshot();
|
|
10
|
+
});
|
|
@@ -0,0 +1,28 @@
|
|
|
1
|
+
import React from 'react';
|
|
2
|
+
import clsx from 'clsx';
|
|
3
|
+
import Base, { BaseProps } from '@digigov/react-core/Base';
|
|
4
|
+
|
|
5
|
+
export interface AutoCompleteStatusContainerProps extends BaseProps<'div'> {}
|
|
6
|
+
/**
|
|
7
|
+
* AutoCompleteStatusContainer is a wrapper for autocomplete element.
|
|
8
|
+
* Use AutoCompleteStatusContainer to wrap autocomplete elements.
|
|
9
|
+
*/
|
|
10
|
+
export const AutoCompleteStatusContainer = React.forwardRef<
|
|
11
|
+
HTMLDivElement,
|
|
12
|
+
AutoCompleteStatusContainerProps
|
|
13
|
+
>(function AutoCompleteStatusContainer({ className, children, ...props }, ref) {
|
|
14
|
+
return (
|
|
15
|
+
<Base
|
|
16
|
+
as="div"
|
|
17
|
+
ref={ref}
|
|
18
|
+
className={clsx(className, {
|
|
19
|
+
'ds-autocomplete__status__container': true,
|
|
20
|
+
})}
|
|
21
|
+
{...props}
|
|
22
|
+
>
|
|
23
|
+
{children}
|
|
24
|
+
</Base>
|
|
25
|
+
);
|
|
26
|
+
});
|
|
27
|
+
|
|
28
|
+
export default AutoCompleteStatusContainer;
|
|
@@ -11,6 +11,14 @@ export interface DropdownContentProps extends BaseProps<'div'> {
|
|
|
11
11
|
* @default true
|
|
12
12
|
*/
|
|
13
13
|
fullWidth?: boolean;
|
|
14
|
+
/**
|
|
15
|
+
* scrollable prop is optional.
|
|
16
|
+
* If true, the dropdown content will have limited scrollable height.
|
|
17
|
+
* @value true
|
|
18
|
+
* @value false
|
|
19
|
+
* @default false
|
|
20
|
+
*/
|
|
21
|
+
scrollable?: boolean;
|
|
14
22
|
}
|
|
15
23
|
/**
|
|
16
24
|
* You should use DropdownContent component inside Dropdown component.
|
|
@@ -19,7 +27,7 @@ export const DropdownContent = React.forwardRef<
|
|
|
19
27
|
HTMLDivElement,
|
|
20
28
|
DropdownContentProps
|
|
21
29
|
>(function DropdownContent(
|
|
22
|
-
{
|
|
30
|
+
{fullWidth = true, scrollable, className, children, ...props },
|
|
23
31
|
ref
|
|
24
32
|
) {
|
|
25
33
|
return (
|
|
@@ -29,6 +37,7 @@ export const DropdownContent = React.forwardRef<
|
|
|
29
37
|
className={clsx(className, {
|
|
30
38
|
'ds-dropdown__content': true,
|
|
31
39
|
'ds-dropdown__content--full-width': fullWidth,
|
|
40
|
+
'ds-dropdown__content--scrollable': scrollable,
|
|
32
41
|
})}
|
|
33
42
|
{...props}
|
|
34
43
|
>
|
package/src/ImageLogo/index.tsx
CHANGED
package/src/Unpurge/index.tsx
CHANGED
package/src/index.ts
CHANGED
|
@@ -152,7 +152,9 @@ export * from '@digigov/react-core/AutoCompleteInput';
|
|
|
152
152
|
export * from '@digigov/react-core/AutoCompleteInputTypeahead';
|
|
153
153
|
export * from '@digigov/react-core/AutoCompleteResultList';
|
|
154
154
|
export * from '@digigov/react-core/AutoCompleteResultListItem';
|
|
155
|
-
export * from '@digigov/react-core/
|
|
155
|
+
export * from '@digigov/react-core/AutoCompleteContainer';
|
|
156
|
+
export * from '@digigov/react-core/AutoCompleteMultipleInputContainer';
|
|
157
|
+
export * from '@digigov/react-core/AutoCompleteMultipleInput';
|
|
156
158
|
export * from '@digigov/react-core/Chip';
|
|
157
159
|
export * from '@digigov/react-core/ChipHeading';
|
|
158
160
|
export * from '@digigov/react-core/ChipContainer';
|
package/src/lazy.js
CHANGED
|
@@ -15,13 +15,15 @@ export default {
|
|
|
15
15
|
'AdminTopSection': lazy(() => import('@digigov/react-core/AdminTopSection').then((module)=> ({default: module['AdminTopSection']}))),
|
|
16
16
|
'Aside': lazy(() => import('@digigov/react-core/Aside').then((module)=> ({default: module['Aside']}))),
|
|
17
17
|
'AutoCompleteAssistiveHint': lazy(() => import('@digigov/react-core/AutoCompleteAssistiveHint').then((module)=> ({default: module['AutoCompleteAssistiveHint']}))),
|
|
18
|
+
'AutoCompleteContainer': lazy(() => import('@digigov/react-core/AutoCompleteContainer').then((module)=> ({default: module['AutoCompleteContainer']}))),
|
|
18
19
|
'AutoCompleteInput': lazy(() => import('@digigov/react-core/AutoCompleteInput').then((module)=> ({default: module['AutoCompleteInput']}))),
|
|
19
20
|
'AutoCompleteInputTypeahead': lazy(() => import('@digigov/react-core/AutoCompleteInputTypeahead').then((module)=> ({default: module['AutoCompleteInputTypeahead']}))),
|
|
21
|
+
'AutoCompleteMultipleInput': lazy(() => import('@digigov/react-core/AutoCompleteMultipleInput').then((module)=> ({default: module['AutoCompleteMultipleInput']}))),
|
|
22
|
+
'AutoCompleteMultipleInputContainer': lazy(() => import('@digigov/react-core/AutoCompleteMultipleInputContainer').then((module)=> ({default: module['AutoCompleteMultipleInputContainer']}))),
|
|
20
23
|
'AutoCompleteResultList': lazy(() => import('@digigov/react-core/AutoCompleteResultList').then((module)=> ({default: module['AutoCompleteResultList']}))),
|
|
21
24
|
'AutoCompleteResultListItem': lazy(() => import('@digigov/react-core/AutoCompleteResultListItem').then((module)=> ({default: module['AutoCompleteResultListItem']}))),
|
|
22
25
|
'AutoCompleteStatus': lazy(() => import('@digigov/react-core/AutoCompleteStatus').then((module)=> ({default: module['AutoCompleteStatus']}))),
|
|
23
|
-
'
|
|
24
|
-
'AutoCompleteWrapper': lazy(() => import('@digigov/react-core/AutoCompleteWrapper').then((module)=> ({default: module['AutoCompleteWrapper']}))),
|
|
26
|
+
'AutoCompleteStatusContainer': lazy(() => import('@digigov/react-core/AutoCompleteStatusContainer').then((module)=> ({default: module['AutoCompleteStatusContainer']}))),
|
|
25
27
|
'BackLink': lazy(() => import('@digigov/react-core/BackLink').then((module)=> ({default: module['BackLink']}))),
|
|
26
28
|
'BackToTopContainer': lazy(() => import('@digigov/react-core/BackToTopContainer').then((module)=> ({default: module['BackToTopContainer']}))),
|
|
27
29
|
'BackToTopLimit': lazy(() => import('@digigov/react-core/BackToTopLimit').then((module)=> ({default: module['BackToTopLimit']}))),
|
package/src/registry.js
CHANGED
|
@@ -14,13 +14,15 @@ import * as _digigov_react_core_AdminMain from '@digigov/react-core/AdminMain';
|
|
|
14
14
|
import * as _digigov_react_core_AdminTopSection from '@digigov/react-core/AdminTopSection';
|
|
15
15
|
import * as _digigov_react_core_Aside from '@digigov/react-core/Aside';
|
|
16
16
|
import * as _digigov_react_core_AutoCompleteAssistiveHint from '@digigov/react-core/AutoCompleteAssistiveHint';
|
|
17
|
+
import * as _digigov_react_core_AutoCompleteContainer from '@digigov/react-core/AutoCompleteContainer';
|
|
17
18
|
import * as _digigov_react_core_AutoCompleteInput from '@digigov/react-core/AutoCompleteInput';
|
|
18
19
|
import * as _digigov_react_core_AutoCompleteInputTypeahead from '@digigov/react-core/AutoCompleteInputTypeahead';
|
|
20
|
+
import * as _digigov_react_core_AutoCompleteMultipleInput from '@digigov/react-core/AutoCompleteMultipleInput';
|
|
21
|
+
import * as _digigov_react_core_AutoCompleteMultipleInputContainer from '@digigov/react-core/AutoCompleteMultipleInputContainer';
|
|
19
22
|
import * as _digigov_react_core_AutoCompleteResultList from '@digigov/react-core/AutoCompleteResultList';
|
|
20
23
|
import * as _digigov_react_core_AutoCompleteResultListItem from '@digigov/react-core/AutoCompleteResultListItem';
|
|
21
24
|
import * as _digigov_react_core_AutoCompleteStatus from '@digigov/react-core/AutoCompleteStatus';
|
|
22
|
-
import * as
|
|
23
|
-
import * as _digigov_react_core_AutoCompleteWrapper from '@digigov/react-core/AutoCompleteWrapper';
|
|
25
|
+
import * as _digigov_react_core_AutoCompleteStatusContainer from '@digigov/react-core/AutoCompleteStatusContainer';
|
|
24
26
|
import * as _digigov_react_core_BackLink from '@digigov/react-core/BackLink';
|
|
25
27
|
import * as _digigov_react_core_BackToTopContainer from '@digigov/react-core/BackToTopContainer';
|
|
26
28
|
import * as _digigov_react_core_BackToTopLimit from '@digigov/react-core/BackToTopLimit';
|
|
@@ -277,13 +279,15 @@ export default {
|
|
|
277
279
|
'@digigov/react-core/AdminTopSection': lazyImport(_digigov_react_core_AdminTopSection),
|
|
278
280
|
'@digigov/react-core/Aside': lazyImport(_digigov_react_core_Aside),
|
|
279
281
|
'@digigov/react-core/AutoCompleteAssistiveHint': lazyImport(_digigov_react_core_AutoCompleteAssistiveHint),
|
|
282
|
+
'@digigov/react-core/AutoCompleteContainer': lazyImport(_digigov_react_core_AutoCompleteContainer),
|
|
280
283
|
'@digigov/react-core/AutoCompleteInput': lazyImport(_digigov_react_core_AutoCompleteInput),
|
|
281
284
|
'@digigov/react-core/AutoCompleteInputTypeahead': lazyImport(_digigov_react_core_AutoCompleteInputTypeahead),
|
|
285
|
+
'@digigov/react-core/AutoCompleteMultipleInput': lazyImport(_digigov_react_core_AutoCompleteMultipleInput),
|
|
286
|
+
'@digigov/react-core/AutoCompleteMultipleInputContainer': lazyImport(_digigov_react_core_AutoCompleteMultipleInputContainer),
|
|
282
287
|
'@digigov/react-core/AutoCompleteResultList': lazyImport(_digigov_react_core_AutoCompleteResultList),
|
|
283
288
|
'@digigov/react-core/AutoCompleteResultListItem': lazyImport(_digigov_react_core_AutoCompleteResultListItem),
|
|
284
289
|
'@digigov/react-core/AutoCompleteStatus': lazyImport(_digigov_react_core_AutoCompleteStatus),
|
|
285
|
-
'@digigov/react-core/
|
|
286
|
-
'@digigov/react-core/AutoCompleteWrapper': lazyImport(_digigov_react_core_AutoCompleteWrapper),
|
|
290
|
+
'@digigov/react-core/AutoCompleteStatusContainer': lazyImport(_digigov_react_core_AutoCompleteStatusContainer),
|
|
287
291
|
'@digigov/react-core/BackLink': lazyImport(_digigov_react_core_BackLink),
|
|
288
292
|
'@digigov/react-core/BackToTopContainer': lazyImport(_digigov_react_core_BackToTopContainer),
|
|
289
293
|
'@digigov/react-core/BackToTopLimit': lazyImport(_digigov_react_core_BackToTopLimit),
|
|
@@ -1,10 +0,0 @@
|
|
|
1
|
-
import React from 'react';
|
|
2
|
-
import { BaseProps } from '@digigov/react-core/Base';
|
|
3
|
-
export interface AutoCompleteStatusWrapperProps extends BaseProps<'div'> {
|
|
4
|
-
}
|
|
5
|
-
/**
|
|
6
|
-
* AutoCompleteStatusWrapper is a wrapper for autocomplete element.
|
|
7
|
-
* Use AutoCompleteStatusWrapper to wrap autocomplete elements.
|
|
8
|
-
*/
|
|
9
|
-
export declare const AutoCompleteStatusWrapper: React.ForwardRefExoticComponent<Pick<AutoCompleteStatusWrapperProps, "p" | "slot" | "style" | "title" | "as" | "className" | "color" | "id" | "lang" | "role" | "tabIndex" | "aria-activedescendant" | "aria-atomic" | "aria-autocomplete" | "aria-busy" | "aria-checked" | "aria-colcount" | "aria-colindex" | "aria-colspan" | "aria-controls" | "aria-current" | "aria-describedby" | "aria-details" | "aria-disabled" | "aria-dropeffect" | "aria-errormessage" | "aria-expanded" | "aria-flowto" | "aria-grabbed" | "aria-haspopup" | "aria-hidden" | "aria-invalid" | "aria-keyshortcuts" | "aria-label" | "aria-labelledby" | "aria-level" | "aria-live" | "aria-modal" | "aria-multiline" | "aria-multiselectable" | "aria-orientation" | "aria-owns" | "aria-placeholder" | "aria-posinset" | "aria-pressed" | "aria-readonly" | "aria-relevant" | "aria-required" | "aria-roledescription" | "aria-rowcount" | "aria-rowindex" | "aria-rowspan" | "aria-selected" | "aria-setsize" | "aria-sort" | "aria-valuemax" | "aria-valuemin" | "aria-valuenow" | "aria-valuetext" | "children" | "dangerouslySetInnerHTML" | "onCopy" | "onCopyCapture" | "onCut" | "onCutCapture" | "onPaste" | "onPasteCapture" | "onCompositionEnd" | "onCompositionEndCapture" | "onCompositionStart" | "onCompositionStartCapture" | "onCompositionUpdate" | "onCompositionUpdateCapture" | "onFocus" | "onFocusCapture" | "onBlur" | "onBlurCapture" | "onChange" | "onChangeCapture" | "onBeforeInput" | "onBeforeInputCapture" | "onInput" | "onInputCapture" | "onReset" | "onResetCapture" | "onSubmit" | "onSubmitCapture" | "onInvalid" | "onInvalidCapture" | "onLoad" | "onLoadCapture" | "onError" | "onErrorCapture" | "onKeyDown" | "onKeyDownCapture" | "onKeyPress" | "onKeyPressCapture" | "onKeyUp" | "onKeyUpCapture" | "onAbort" | "onAbortCapture" | "onCanPlay" | "onCanPlayCapture" | "onCanPlayThrough" | "onCanPlayThroughCapture" | "onDurationChange" | "onDurationChangeCapture" | "onEmptied" | "onEmptiedCapture" | "onEncrypted" | "onEncryptedCapture" | "onEnded" | "onEndedCapture" | "onLoadedData" | "onLoadedDataCapture" | "onLoadedMetadata" | "onLoadedMetadataCapture" | "onLoadStart" | "onLoadStartCapture" | "onPause" | "onPauseCapture" | "onPlay" | "onPlayCapture" | "onPlaying" | "onPlayingCapture" | "onProgress" | "onProgressCapture" | "onRateChange" | "onRateChangeCapture" | "onSeeked" | "onSeekedCapture" | "onSeeking" | "onSeekingCapture" | "onStalled" | "onStalledCapture" | "onSuspend" | "onSuspendCapture" | "onTimeUpdate" | "onTimeUpdateCapture" | "onVolumeChange" | "onVolumeChangeCapture" | "onWaiting" | "onWaitingCapture" | "onAuxClick" | "onAuxClickCapture" | "onClick" | "onClickCapture" | "onContextMenu" | "onContextMenuCapture" | "onDoubleClick" | "onDoubleClickCapture" | "onDrag" | "onDragCapture" | "onDragEnd" | "onDragEndCapture" | "onDragEnter" | "onDragEnterCapture" | "onDragExit" | "onDragExitCapture" | "onDragLeave" | "onDragLeaveCapture" | "onDragOver" | "onDragOverCapture" | "onDragStart" | "onDragStartCapture" | "onDrop" | "onDropCapture" | "onMouseDown" | "onMouseDownCapture" | "onMouseEnter" | "onMouseLeave" | "onMouseMove" | "onMouseMoveCapture" | "onMouseOut" | "onMouseOutCapture" | "onMouseOver" | "onMouseOverCapture" | "onMouseUp" | "onMouseUpCapture" | "onSelect" | "onSelectCapture" | "onTouchCancel" | "onTouchCancelCapture" | "onTouchEnd" | "onTouchEndCapture" | "onTouchMove" | "onTouchMoveCapture" | "onTouchStart" | "onTouchStartCapture" | "onPointerDown" | "onPointerDownCapture" | "onPointerMove" | "onPointerMoveCapture" | "onPointerUp" | "onPointerUpCapture" | "onPointerCancel" | "onPointerCancelCapture" | "onPointerEnter" | "onPointerEnterCapture" | "onPointerLeave" | "onPointerLeaveCapture" | "onPointerOver" | "onPointerOverCapture" | "onPointerOut" | "onPointerOutCapture" | "onGotPointerCapture" | "onGotPointerCaptureCapture" | "onLostPointerCapture" | "onLostPointerCaptureCapture" | "onScroll" | "onScrollCapture" | "onWheel" | "onWheelCapture" | "onAnimationStart" | "onAnimationStartCapture" | "onAnimationEnd" | "onAnimationEndCapture" | "onAnimationIteration" | "onAnimationIterationCapture" | "onTransitionEnd" | "onTransitionEndCapture" | "key" | "defaultChecked" | "defaultValue" | "suppressContentEditableWarning" | "suppressHydrationWarning" | "accessKey" | "contentEditable" | "contextMenu" | "dir" | "draggable" | "hidden" | "placeholder" | "spellCheck" | "translate" | "radioGroup" | "about" | "datatype" | "inlist" | "prefix" | "property" | "resource" | "typeof" | "vocab" | "autoCapitalize" | "autoCorrect" | "autoSave" | "itemProp" | "itemScope" | "itemType" | "itemID" | "itemRef" | "results" | "security" | "unselectable" | "inputMode" | "is" | "margin" | "marginTop" | "marginBottom" | "marginLeft" | "marginRight" | "m" | "mt" | "mb" | "ml" | "mr" | "mx" | "my" | "padding" | "paddingTop" | "paddingBottom" | "paddingLeft" | "paddingRight" | "pt" | "pb" | "pl" | "pr" | "px" | "py" | "printHidden" | "printVisible" | "xsUpHidden" | "smUpHidden" | "mdUpHidden" | "lgUpHidden" | "xlUpHidden" | "xsHidden" | "smHidden" | "mdHidden" | "lgHidden" | "xlHidden"> & React.RefAttributes<HTMLDivElement>>;
|
|
10
|
-
export default AutoCompleteStatusWrapper;
|
|
@@ -1,7 +0,0 @@
|
|
|
1
|
-
import React from 'react';
|
|
2
|
-
import { mount } from 'enzyme';
|
|
3
|
-
import AutoCompleteStatusWrapper from '@digigov/react-core/AutoCompleteStatusWrapper';
|
|
4
|
-
var _ref = /*#__PURE__*/React.createElement(AutoCompleteStatusWrapper, null, "hello");
|
|
5
|
-
it('renders the AdminContainer with no props', function () {
|
|
6
|
-
expect(mount(_ref)).toMatchSnapshot();
|
|
7
|
-
});
|
|
@@ -1,22 +0,0 @@
|
|
|
1
|
-
import React from 'react';
|
|
2
|
-
import { BaseProps } from '@digigov/react-core/Base';
|
|
3
|
-
export interface AutoCompleteWrapperProps extends BaseProps<'div'> {
|
|
4
|
-
/**
|
|
5
|
-
* width is optional.
|
|
6
|
-
* Use width prop to define a custom width in your component.
|
|
7
|
-
* @value '25%';
|
|
8
|
-
* @value '33.3%';
|
|
9
|
-
* @value '50%';
|
|
10
|
-
* @value '66.6%';
|
|
11
|
-
* @value '75%';
|
|
12
|
-
* @value '100%';
|
|
13
|
-
* @value 'full';
|
|
14
|
-
*/
|
|
15
|
-
width?: '25%' | '33.3%' | '50%' | '66.6%' | '75%' | '100%' | 'full';
|
|
16
|
-
}
|
|
17
|
-
/**
|
|
18
|
-
* AutoCompleteWrapper is a wrapper for autocomplete element.
|
|
19
|
-
* Use AutoCompleteWrapper to wrap autocomplete elements.
|
|
20
|
-
*/
|
|
21
|
-
export declare const AutoCompleteWrapper: React.ForwardRefExoticComponent<Pick<AutoCompleteWrapperProps, "p" | "slot" | "style" | "title" | "as" | "className" | "color" | "id" | "lang" | "width" | "role" | "tabIndex" | "aria-activedescendant" | "aria-atomic" | "aria-autocomplete" | "aria-busy" | "aria-checked" | "aria-colcount" | "aria-colindex" | "aria-colspan" | "aria-controls" | "aria-current" | "aria-describedby" | "aria-details" | "aria-disabled" | "aria-dropeffect" | "aria-errormessage" | "aria-expanded" | "aria-flowto" | "aria-grabbed" | "aria-haspopup" | "aria-hidden" | "aria-invalid" | "aria-keyshortcuts" | "aria-label" | "aria-labelledby" | "aria-level" | "aria-live" | "aria-modal" | "aria-multiline" | "aria-multiselectable" | "aria-orientation" | "aria-owns" | "aria-placeholder" | "aria-posinset" | "aria-pressed" | "aria-readonly" | "aria-relevant" | "aria-required" | "aria-roledescription" | "aria-rowcount" | "aria-rowindex" | "aria-rowspan" | "aria-selected" | "aria-setsize" | "aria-sort" | "aria-valuemax" | "aria-valuemin" | "aria-valuenow" | "aria-valuetext" | "children" | "dangerouslySetInnerHTML" | "onCopy" | "onCopyCapture" | "onCut" | "onCutCapture" | "onPaste" | "onPasteCapture" | "onCompositionEnd" | "onCompositionEndCapture" | "onCompositionStart" | "onCompositionStartCapture" | "onCompositionUpdate" | "onCompositionUpdateCapture" | "onFocus" | "onFocusCapture" | "onBlur" | "onBlurCapture" | "onChange" | "onChangeCapture" | "onBeforeInput" | "onBeforeInputCapture" | "onInput" | "onInputCapture" | "onReset" | "onResetCapture" | "onSubmit" | "onSubmitCapture" | "onInvalid" | "onInvalidCapture" | "onLoad" | "onLoadCapture" | "onError" | "onErrorCapture" | "onKeyDown" | "onKeyDownCapture" | "onKeyPress" | "onKeyPressCapture" | "onKeyUp" | "onKeyUpCapture" | "onAbort" | "onAbortCapture" | "onCanPlay" | "onCanPlayCapture" | "onCanPlayThrough" | "onCanPlayThroughCapture" | "onDurationChange" | "onDurationChangeCapture" | "onEmptied" | "onEmptiedCapture" | "onEncrypted" | "onEncryptedCapture" | "onEnded" | "onEndedCapture" | "onLoadedData" | "onLoadedDataCapture" | "onLoadedMetadata" | "onLoadedMetadataCapture" | "onLoadStart" | "onLoadStartCapture" | "onPause" | "onPauseCapture" | "onPlay" | "onPlayCapture" | "onPlaying" | "onPlayingCapture" | "onProgress" | "onProgressCapture" | "onRateChange" | "onRateChangeCapture" | "onSeeked" | "onSeekedCapture" | "onSeeking" | "onSeekingCapture" | "onStalled" | "onStalledCapture" | "onSuspend" | "onSuspendCapture" | "onTimeUpdate" | "onTimeUpdateCapture" | "onVolumeChange" | "onVolumeChangeCapture" | "onWaiting" | "onWaitingCapture" | "onAuxClick" | "onAuxClickCapture" | "onClick" | "onClickCapture" | "onContextMenu" | "onContextMenuCapture" | "onDoubleClick" | "onDoubleClickCapture" | "onDrag" | "onDragCapture" | "onDragEnd" | "onDragEndCapture" | "onDragEnter" | "onDragEnterCapture" | "onDragExit" | "onDragExitCapture" | "onDragLeave" | "onDragLeaveCapture" | "onDragOver" | "onDragOverCapture" | "onDragStart" | "onDragStartCapture" | "onDrop" | "onDropCapture" | "onMouseDown" | "onMouseDownCapture" | "onMouseEnter" | "onMouseLeave" | "onMouseMove" | "onMouseMoveCapture" | "onMouseOut" | "onMouseOutCapture" | "onMouseOver" | "onMouseOverCapture" | "onMouseUp" | "onMouseUpCapture" | "onSelect" | "onSelectCapture" | "onTouchCancel" | "onTouchCancelCapture" | "onTouchEnd" | "onTouchEndCapture" | "onTouchMove" | "onTouchMoveCapture" | "onTouchStart" | "onTouchStartCapture" | "onPointerDown" | "onPointerDownCapture" | "onPointerMove" | "onPointerMoveCapture" | "onPointerUp" | "onPointerUpCapture" | "onPointerCancel" | "onPointerCancelCapture" | "onPointerEnter" | "onPointerEnterCapture" | "onPointerLeave" | "onPointerLeaveCapture" | "onPointerOver" | "onPointerOverCapture" | "onPointerOut" | "onPointerOutCapture" | "onGotPointerCapture" | "onGotPointerCaptureCapture" | "onLostPointerCapture" | "onLostPointerCaptureCapture" | "onScroll" | "onScrollCapture" | "onWheel" | "onWheelCapture" | "onAnimationStart" | "onAnimationStartCapture" | "onAnimationEnd" | "onAnimationEndCapture" | "onAnimationIteration" | "onAnimationIterationCapture" | "onTransitionEnd" | "onTransitionEndCapture" | "key" | "defaultChecked" | "defaultValue" | "suppressContentEditableWarning" | "suppressHydrationWarning" | "accessKey" | "contentEditable" | "contextMenu" | "dir" | "draggable" | "hidden" | "placeholder" | "spellCheck" | "translate" | "radioGroup" | "about" | "datatype" | "inlist" | "prefix" | "property" | "resource" | "typeof" | "vocab" | "autoCapitalize" | "autoCorrect" | "autoSave" | "itemProp" | "itemScope" | "itemType" | "itemID" | "itemRef" | "results" | "security" | "unselectable" | "inputMode" | "is" | "margin" | "marginTop" | "marginBottom" | "marginLeft" | "marginRight" | "m" | "mt" | "mb" | "ml" | "mr" | "mx" | "my" | "padding" | "paddingTop" | "paddingBottom" | "paddingLeft" | "paddingRight" | "pt" | "pb" | "pl" | "pr" | "px" | "py" | "printHidden" | "printVisible" | "xsUpHidden" | "smUpHidden" | "mdUpHidden" | "lgUpHidden" | "xlUpHidden" | "xsHidden" | "smHidden" | "mdHidden" | "lgHidden" | "xlHidden"> & React.RefAttributes<HTMLDivElement>>;
|
|
22
|
-
export default AutoCompleteWrapper;
|
|
@@ -1,7 +0,0 @@
|
|
|
1
|
-
import React from 'react';
|
|
2
|
-
import { mount } from 'enzyme';
|
|
3
|
-
import AutoCompleteWrapper from '@digigov/react-core/AutoCompleteWrapper';
|
|
4
|
-
var _ref = /*#__PURE__*/React.createElement(AutoCompleteWrapper, null, "hello");
|
|
5
|
-
it('renders the AdminContainer with no props', function () {
|
|
6
|
-
expect(mount(_ref)).toMatchSnapshot();
|
|
7
|
-
});
|