@react-ui-org/react-ui 0.46.0 → 0.47.0
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 +15 -16
 - package/dist/lib.development.js +106 -154
 - package/dist/lib.js +1 -1
 - package/package.json +2 -1
 - package/src/lib/components/Alert/Alert.jsx +43 -43
 - package/src/lib/components/Alert/README.mdx +2 -5
 - package/src/lib/components/Badge/Badge.jsx +3 -3
 - package/src/lib/components/Button/Button.jsx +4 -4
 - package/src/lib/components/Button/README.mdx +4 -4
 - package/src/lib/components/Button/_base.scss +6 -6
 - package/src/lib/components/Button/helpers/getRootLabelVisibilityClassName.js +4 -4
 - package/src/lib/components/ButtonGroup/ButtonGroup.jsx +10 -3
 - package/src/lib/components/ButtonGroup/README.mdx +1 -1
 - package/src/lib/components/Card/Card.jsx +3 -3
 - package/src/lib/components/Card/CardBody.jsx +16 -5
 - package/src/lib/components/Card/CardFooter.jsx +13 -5
 - package/src/lib/components/CheckboxField/CheckboxField.jsx +3 -3
 - package/src/lib/components/FileInputField/FileInputField.jsx +3 -3
 - package/src/lib/components/FormLayout/FormLayout.jsx +3 -3
 - package/src/lib/components/FormLayout/FormLayoutCustomField.jsx +3 -3
 - package/src/lib/components/FormLayout/README.mdx +4 -5
 - package/src/lib/components/Grid/Grid.jsx +21 -21
 - package/src/lib/components/Grid/Grid.scss +6 -0
 - package/src/lib/components/Grid/GridSpan.jsx +7 -7
 - package/src/lib/components/Grid/README.mdx +46 -20
 - package/src/lib/components/Grid/_theme.scss +7 -7
 - package/src/lib/components/Modal/Modal.jsx +30 -26
 - package/src/lib/components/Modal/README.mdx +2 -5
 - package/src/lib/components/Paper/Paper.jsx +3 -3
 - package/src/lib/components/Popover/Popover.jsx +94 -0
 - package/src/lib/components/Popover/Popover.scss +235 -0
 - package/src/lib/components/Popover/PopoverWrapper.jsx +46 -0
 - package/src/lib/components/Popover/README.mdx +333 -0
 - package/src/lib/components/Popover/_helpers/getRootAlignmentClassName.js +13 -0
 - package/src/lib/components/Popover/_helpers/getRootSideClassName.js +17 -0
 - package/src/lib/components/Popover/_theme.scss +16 -0
 - package/src/lib/components/Popover/index.js +2 -0
 - package/src/lib/components/Radio/Radio.jsx +3 -3
 - package/src/lib/components/ScrollView/README.mdx +2 -5
 - package/src/lib/components/ScrollView/ScrollView.jsx +11 -13
 - package/src/lib/components/SelectField/SelectField.jsx +3 -3
 - package/src/lib/components/Table/README.mdx +1 -1
 - package/src/lib/components/Table/Table.jsx +3 -3
 - package/src/lib/components/Tabs/Tabs.jsx +3 -3
 - package/src/lib/components/Tabs/TabsItem.jsx +3 -3
 - package/src/lib/components/Text/README.mdx +2 -2
 - package/src/lib/components/Text/Text.jsx +3 -3
 - package/src/lib/components/TextArea/TextArea.jsx +3 -3
 - package/src/lib/components/TextField/TextField.jsx +3 -3
 - package/src/lib/components/TextLink/TextLink.jsx +3 -3
 - package/src/lib/components/Toggle/Toggle.jsx +3 -3
 - package/src/lib/components/Toolbar/README.mdx +18 -6
 - package/src/lib/components/Toolbar/Toolbar.jsx +10 -3
 - package/src/lib/components/Toolbar/Toolbar.scss +5 -23
 - package/src/lib/components/Toolbar/ToolbarGroup.jsx +10 -3
 - package/src/lib/components/Toolbar/ToolbarItem.jsx +10 -3
 - package/src/lib/index.js +4 -9
 - package/src/lib/provider/index.js +2 -1
 - package/src/lib/provider/withGlobalProps.jsx +21 -0
 - package/src/lib/styles/settings/_breakpoints.scss +2 -2
 - package/src/lib/styles/theme-constants/_breakpoints.scss +2 -2
 - package/src/lib/styles/tools/_spacing.scss +2 -6
 - package/src/lib/theme.scss +19 -18
 - package/src/lib/components/List/List.jsx +0 -73
 - package/src/lib/components/List/List.scss +0 -53
 - package/src/lib/components/List/ListItem.jsx +0 -32
 - package/src/lib/components/List/README.mdx +0 -114
 - package/src/lib/components/List/_theme.scss +0 -1
 - package/src/lib/components/List/index.js +0 -2
 - package/src/lib/components/Media/Media.jsx +0 -36
 - package/src/lib/components/Media/Media.scss +0 -16
 - package/src/lib/components/Media/MediaBody.jsx +0 -32
 - package/src/lib/components/Media/MediaObject.jsx +0 -32
 - package/src/lib/components/Media/README.mdx +0 -63
 - package/src/lib/components/Media/index.js +0 -3
 - package/src/lib/provider/withProviderContext.jsx +0 -32
 
| 
         @@ -1,6 +1,6 @@ 
     | 
|
| 
       1 
1 
     | 
    
         
             
            import PropTypes from 'prop-types';
         
     | 
| 
       2 
2 
     | 
    
         
             
            import React, { useContext } from 'react';
         
     | 
| 
       3 
     | 
    
         
            -
            import {  
     | 
| 
      
 3 
     | 
    
         
            +
            import { withGlobalProps } from '../../provider';
         
     | 
| 
       4 
4 
     | 
    
         
             
            import { classNames } from '../../utils/classNames';
         
     | 
| 
       5 
5 
     | 
    
         
             
            import { getRootSizeClassName } from '../_helpers/getRootSizeClassName';
         
     | 
| 
       6 
6 
     | 
    
         
             
            import { getRootValidationStateClassName } from '../_helpers/getRootValidationStateClassName';
         
     | 
| 
         @@ -209,6 +209,6 @@ TextField.propTypes = { 
     | 
|
| 
       209 
209 
     | 
    
         
             
              variant: PropTypes.oneOf(['filled', 'outline']),
         
     | 
| 
       210 
210 
     | 
    
         
             
            };
         
     | 
| 
       211 
211 
     | 
    
         | 
| 
       212 
     | 
    
         
            -
            export const  
     | 
| 
      
 212 
     | 
    
         
            +
            export const TextFieldWithGlobalProps = withForwardedRef(withGlobalProps(TextField, 'TextField'));
         
     | 
| 
       213 
213 
     | 
    
         | 
| 
       214 
     | 
    
         
            -
            export default  
     | 
| 
      
 214 
     | 
    
         
            +
            export default TextFieldWithGlobalProps;
         
     | 
| 
         @@ -1,6 +1,6 @@ 
     | 
|
| 
       1 
1 
     | 
    
         
             
            import PropTypes from 'prop-types';
         
     | 
| 
       2 
2 
     | 
    
         
             
            import React from 'react';
         
     | 
| 
       3 
     | 
    
         
            -
            import {  
     | 
| 
      
 3 
     | 
    
         
            +
            import { withGlobalProps } from '../../provider';
         
     | 
| 
       4 
4 
     | 
    
         
             
            import { transferProps } from '../_helpers/transferProps';
         
     | 
| 
       5 
5 
     | 
    
         
             
            import styles from './TextLink.scss';
         
     | 
| 
       6 
6 
     | 
    
         | 
| 
         @@ -39,6 +39,6 @@ TextLink.propTypes = { 
     | 
|
| 
       39 
39 
     | 
    
         
             
              label: PropTypes.string.isRequired,
         
     | 
| 
       40 
40 
     | 
    
         
             
            };
         
     | 
| 
       41 
41 
     | 
    
         | 
| 
       42 
     | 
    
         
            -
            export const  
     | 
| 
      
 42 
     | 
    
         
            +
            export const LinkWithGlobalProps = withGlobalProps(TextLink, 'TextLink');
         
     | 
| 
       43 
43 
     | 
    
         | 
| 
       44 
     | 
    
         
            -
            export default  
     | 
| 
      
 44 
     | 
    
         
            +
            export default LinkWithGlobalProps;
         
     | 
| 
         @@ -1,6 +1,6 @@ 
     | 
|
| 
       1 
1 
     | 
    
         
             
            import PropTypes from 'prop-types';
         
     | 
| 
       2 
2 
     | 
    
         
             
            import React, { useContext } from 'react';
         
     | 
| 
       3 
     | 
    
         
            -
            import {  
     | 
| 
      
 3 
     | 
    
         
            +
            import { withGlobalProps } from '../../provider';
         
     | 
| 
       4 
4 
     | 
    
         
             
            import { classNames } from '../../utils/classNames';
         
     | 
| 
       5 
5 
     | 
    
         
             
            import { getRootValidationStateClassName } from '../_helpers/getRootValidationStateClassName';
         
     | 
| 
       6 
6 
     | 
    
         
             
            import { transferProps } from '../_helpers/transferProps';
         
     | 
| 
         @@ -159,6 +159,6 @@ Toggle.propTypes = { 
     | 
|
| 
       159 
159 
     | 
    
         
             
              ]),
         
     | 
| 
       160 
160 
     | 
    
         
             
            };
         
     | 
| 
       161 
161 
     | 
    
         | 
| 
       162 
     | 
    
         
            -
            export const  
     | 
| 
      
 162 
     | 
    
         
            +
            export const ToggleWithGlobalProps = withForwardedRef(withGlobalProps(Toggle, 'Toggle'));
         
     | 
| 
       163 
163 
     | 
    
         | 
| 
       164 
     | 
    
         
            -
            export default  
     | 
| 
      
 164 
     | 
    
         
            +
            export default ToggleWithGlobalProps;
         
     | 
| 
         @@ -50,8 +50,8 @@ See [API](#api) for all available options. 
     | 
|
| 
       50 
50 
     | 
    
         
             
            ## General Guidelines
         
     | 
| 
       51 
51 
     | 
    
         | 
| 
       52 
52 
     | 
    
         
             
            - **Toolbar is great for flexible inline layouts.** For stacking your content
         
     | 
| 
       53 
     | 
    
         
            -
              vertically 
     | 
| 
       54 
     | 
    
         
            -
               
     | 
| 
      
 53 
     | 
    
         
            +
              vertically or building two-dimensional layouts head to the [Grid][grid]
         
     | 
| 
      
 54 
     | 
    
         
            +
              layout.
         
     | 
| 
       55 
55 
     | 
    
         | 
| 
       56 
56 
     | 
    
         
             
            - **Wrap your items** into the ToolbarItem component. This ensures your content
         
     | 
| 
       57 
57 
     | 
    
         
             
              is properly spaced and aligned with other Toolbar elements. Do **not** try to
         
     | 
| 
         @@ -88,7 +88,7 @@ of `right`. 
     | 
|
| 
       88 
88 
     | 
    
         
             
                          <span id="alignment-label">Alignment:</span>
         
     | 
| 
       89 
89 
     | 
    
         
             
                        </ToolbarItem>
         
     | 
| 
       90 
90 
     | 
    
         
             
                        <ToolbarItem>
         
     | 
| 
       91 
     | 
    
         
            -
                          <ButtonGroup aria-labelledby=" 
     | 
| 
      
 91 
     | 
    
         
            +
                          <ButtonGroup aria-labelledby="alignment-label">
         
     | 
| 
       92 
92 
     | 
    
         
             
                            <Button
         
     | 
| 
       93 
93 
     | 
    
         
             
                              color={alignment === 'top' ? 'dark' : 'primary'}
         
     | 
| 
       94 
94 
     | 
    
         
             
                              label="top"
         
     | 
| 
         @@ -117,7 +117,7 @@ of `right`. 
     | 
|
| 
       117 
117 
     | 
    
         
             
                          <span id="justification-label">Justification:</span>
         
     | 
| 
       118 
118 
     | 
    
         
             
                        </ToolbarItem>
         
     | 
| 
       119 
119 
     | 
    
         
             
                        <ToolbarItem>
         
     | 
| 
       120 
     | 
    
         
            -
                          <ButtonGroup aria-labelledby=" 
     | 
| 
      
 120 
     | 
    
         
            +
                          <ButtonGroup aria-labelledby="justification-label">
         
     | 
| 
       121 
121 
     | 
    
         
             
                            <Button
         
     | 
| 
       122 
122 
     | 
    
         
             
                              color={justification === 'start' ? 'dark' : 'primary'}
         
     | 
| 
       123 
123 
     | 
    
         
             
                              label="start"
         
     | 
| 
         @@ -307,7 +307,7 @@ specifically for this kind of job. 
     | 
|
| 
       307 
307 
     | 
    
         
             
            ## Flexible Items
         
     | 
| 
       308 
308 
     | 
    
         | 
| 
       309 
309 
     | 
    
         
             
            Toolbar items can be made flexible to grow and shrink according to the available
         
     | 
| 
       310 
     | 
    
         
            -
            space. This is useful e.g. when you need to combine text with an action 
     | 
| 
      
 310 
     | 
    
         
            +
            space. This is useful e.g. when you need to combine text with an action:
         
     | 
| 
       311 
311 
     | 
    
         | 
| 
       312 
312 
     | 
    
         
             
            <Playground>
         
     | 
| 
       313 
313 
     | 
    
         
             
              <Toolbar>
         
     | 
| 
         @@ -320,6 +320,19 @@ space. This is useful e.g. when you need to combine text with an action. 
     | 
|
| 
       320 
320 
     | 
    
         
             
              </Toolbar>
         
     | 
| 
       321 
321 
     | 
    
         
             
            </Playground>
         
     | 
| 
       322 
322 
     | 
    
         | 
| 
      
 323 
     | 
    
         
            +
            Or to build a classic media layout with image on the left and text on the right:
         
     | 
| 
      
 324 
     | 
    
         
            +
             
     | 
| 
      
 325 
     | 
    
         
            +
            <Playground>
         
     | 
| 
      
 326 
     | 
    
         
            +
              <Toolbar>
         
     | 
| 
      
 327 
     | 
    
         
            +
                <ToolbarItem>
         
     | 
| 
      
 328 
     | 
    
         
            +
                  <Placeholder bordered>Media object</Placeholder>
         
     | 
| 
      
 329 
     | 
    
         
            +
                </ToolbarItem>
         
     | 
| 
      
 330 
     | 
    
         
            +
                <ToolbarItem flexible>
         
     | 
| 
      
 331 
     | 
    
         
            +
                  <Placeholder bordered>Media body</Placeholder>
         
     | 
| 
      
 332 
     | 
    
         
            +
                </ToolbarItem>
         
     | 
| 
      
 333 
     | 
    
         
            +
              </Toolbar>
         
     | 
| 
      
 334 
     | 
    
         
            +
            </Playground>
         
     | 
| 
      
 335 
     | 
    
         
            +
             
     | 
| 
       323 
336 
     | 
    
         
             
            ## API
         
     | 
| 
       324 
337 
     | 
    
         | 
| 
       325 
338 
     | 
    
         
             
            <Props table of={Toolbar} />
         
     | 
| 
         @@ -346,6 +359,5 @@ A wrapper for individual toolbar items. 
     | 
|
| 
       346 
359 
     | 
    
         
             
            [inline-elements]: https://developer.mozilla.org/en-US/docs/Web/HTML/Inline_elements
         
     | 
| 
       347 
360 
     | 
    
         
             
            [block-elements]: https://developer.mozilla.org/en-US/docs/Web/HTML/Inline_elements
         
     | 
| 
       348 
361 
     | 
    
         
             
            [grid]: /components/grid
         
     | 
| 
       349 
     | 
    
         
            -
            [list]: /components/list
         
     | 
| 
       350 
362 
     | 
    
         
             
            [spacing]: /css-helpers/spacing
         
     | 
| 
       351 
363 
     | 
    
         
             
            [text]: /components/text
         
     | 
| 
         @@ -1,6 +1,6 @@ 
     | 
|
| 
       1 
1 
     | 
    
         
             
            import PropTypes from 'prop-types';
         
     | 
| 
       2 
2 
     | 
    
         
             
            import React from 'react';
         
     | 
| 
       3 
     | 
    
         
            -
            import {  
     | 
| 
      
 3 
     | 
    
         
            +
            import { withGlobalProps } from '../../provider';
         
     | 
| 
       4 
4 
     | 
    
         
             
            import { classNames } from '../../utils/classNames';
         
     | 
| 
       5 
5 
     | 
    
         
             
            import { isChildrenEmpty } from '../_helpers/isChildrenEmpty';
         
     | 
| 
       6 
6 
     | 
    
         
             
            import styles from './Toolbar.scss';
         
     | 
| 
         @@ -9,6 +9,7 @@ export const Toolbar = ({ 
     | 
|
| 
       9 
9 
     | 
    
         
             
              align,
         
     | 
| 
       10 
10 
     | 
    
         
             
              children,
         
     | 
| 
       11 
11 
     | 
    
         
             
              dense,
         
     | 
| 
      
 12 
     | 
    
         
            +
              id,
         
     | 
| 
       12 
13 
     | 
    
         
             
              justify,
         
     | 
| 
       13 
14 
     | 
    
         
             
              nowrap,
         
     | 
| 
       14 
15 
     | 
    
         
             
            }) => {
         
     | 
| 
         @@ -57,6 +58,7 @@ export const Toolbar = ({ 
     | 
|
| 
       57 
58 
     | 
    
         
             
                    alignClass(align),
         
     | 
| 
       58 
59 
     | 
    
         
             
                    justifyClass(justify),
         
     | 
| 
       59 
60 
     | 
    
         
             
                  )}
         
     | 
| 
      
 61 
     | 
    
         
            +
                  id={id}
         
     | 
| 
       60 
62 
     | 
    
         
             
                >
         
     | 
| 
       61 
63 
     | 
    
         
             
                  {children}
         
     | 
| 
       62 
64 
     | 
    
         
             
                </div>
         
     | 
| 
         @@ -67,6 +69,7 @@ Toolbar.defaultProps = { 
     | 
|
| 
       67 
69 
     | 
    
         
             
              align: 'top',
         
     | 
| 
       68 
70 
     | 
    
         
             
              children: null,
         
     | 
| 
       69 
71 
     | 
    
         
             
              dense: false,
         
     | 
| 
      
 72 
     | 
    
         
            +
              id: undefined,
         
     | 
| 
       70 
73 
     | 
    
         
             
              justify: 'start',
         
     | 
| 
       71 
74 
     | 
    
         
             
              nowrap: false,
         
     | 
| 
       72 
75 
     | 
    
         
             
            };
         
     | 
| 
         @@ -88,6 +91,10 @@ Toolbar.propTypes = { 
     | 
|
| 
       88 
91 
     | 
    
         
             
               * If `true`, spacing of all toolbar items in the toolbar will be reduced.
         
     | 
| 
       89 
92 
     | 
    
         
             
               */
         
     | 
| 
       90 
93 
     | 
    
         
             
              dense: PropTypes.bool,
         
     | 
| 
      
 94 
     | 
    
         
            +
              /**
         
     | 
| 
      
 95 
     | 
    
         
            +
               * ID of the root HTML element.
         
     | 
| 
      
 96 
     | 
    
         
            +
               */
         
     | 
| 
      
 97 
     | 
    
         
            +
              id: PropTypes.string,
         
     | 
| 
       91 
98 
     | 
    
         
             
              /**
         
     | 
| 
       92 
99 
     | 
    
         
             
               * Horizontal alignment (distribution) of toolbar items and groups.
         
     | 
| 
       93 
100 
     | 
    
         
             
               */
         
     | 
| 
         @@ -98,6 +105,6 @@ Toolbar.propTypes = { 
     | 
|
| 
       98 
105 
     | 
    
         
             
              nowrap: PropTypes.bool,
         
     | 
| 
       99 
106 
     | 
    
         
             
            };
         
     | 
| 
       100 
107 
     | 
    
         | 
| 
       101 
     | 
    
         
            -
            export const  
     | 
| 
      
 108 
     | 
    
         
            +
            export const ToolbarWithGlobalProps = withGlobalProps(Toolbar, 'Toolbar');
         
     | 
| 
       102 
109 
     | 
    
         | 
| 
       103 
     | 
    
         
            -
            export default  
     | 
| 
      
 110 
     | 
    
         
            +
            export default ToolbarWithGlobalProps;
         
     | 
| 
         @@ -7,19 +7,17 @@ 
     | 
|
| 
       7 
7 
     | 
    
         
             
            .group {
         
     | 
| 
       8 
8 
     | 
    
         
             
                display: flex;
         
     | 
| 
       9 
9 
     | 
    
         
             
                flex-wrap: wrap;
         
     | 
| 
      
 10 
     | 
    
         
            +
                gap: theme.$gap;
         
     | 
| 
       10 
11 
     | 
    
         
             
            }
         
     | 
| 
       11 
12 
     | 
    
         | 
| 
       12 
13 
     | 
    
         
             
            .toolbar {
         
     | 
| 
       13 
     | 
    
         
            -
                @include spacing.bottom(layouts 
     | 
| 
       14 
     | 
    
         
            -
             
     | 
| 
       15 
     | 
    
         
            -
                margin: calc(-1 * #{theme.$gap});
         
     | 
| 
      
 14 
     | 
    
         
            +
                @include spacing.bottom(layouts);
         
     | 
| 
       16 
15 
     | 
    
         
             
            }
         
     | 
| 
       17 
16 
     | 
    
         | 
| 
       18 
17 
     | 
    
         
             
            .item {
         
     | 
| 
       19 
18 
     | 
    
         
             
                display: flex; // 1.
         
     | 
| 
       20 
19 
     | 
    
         
             
                flex: none;
         
     | 
| 
       21 
20 
     | 
    
         
             
                flex-direction: column; // 1.
         
     | 
| 
       22 
     | 
    
         
            -
                margin: theme.$gap;
         
     | 
| 
       23 
21 
     | 
    
         
             
            }
         
     | 
| 
       24 
22 
     | 
    
         | 
| 
       25 
23 
     | 
    
         
             
            .isItemFlexible {
         
     | 
| 
         @@ -59,16 +57,9 @@ 
     | 
|
| 
       59 
57 
     | 
    
         
             
                justify-content: space-between;
         
     | 
| 
       60 
58 
     | 
    
         
             
            }
         
     | 
| 
       61 
59 
     | 
    
         | 
| 
       62 
     | 
    
         
            -
            .isDense 
     | 
| 
       63 
     | 
    
         
            -
             
     | 
| 
       64 
     | 
    
         
            -
             
     | 
| 
       65 
     | 
    
         
            -
             
     | 
| 
       66 
     | 
    
         
            -
            .isDense .item {
         
     | 
| 
       67 
     | 
    
         
            -
                margin: theme.$gap-dense;
         
     | 
| 
       68 
     | 
    
         
            -
            }
         
     | 
| 
       69 
     | 
    
         
            -
             
     | 
| 
       70 
     | 
    
         
            -
            .isDense > .isDense {
         
     | 
| 
       71 
     | 
    
         
            -
                margin: 0;
         
     | 
| 
      
 60 
     | 
    
         
            +
            .isDense,
         
     | 
| 
      
 61 
     | 
    
         
            +
            .isDense .group {
         
     | 
| 
      
 62 
     | 
    
         
            +
                gap: theme.$gap-dense;
         
     | 
| 
       72 
63 
     | 
    
         
             
            }
         
     | 
| 
       73 
64 
     | 
    
         | 
| 
       74 
65 
     | 
    
         
             
            .isNowrap {
         
     | 
| 
         @@ -78,12 +69,3 @@ 
     | 
|
| 
       78 
69 
     | 
    
         
             
            .isNowrap > .item:not(.isItemFlexible) {
         
     | 
| 
       79 
70 
     | 
    
         
             
                flex: 0 1 auto;
         
     | 
| 
       80 
71 
     | 
    
         
             
            }
         
     | 
| 
       81 
     | 
    
         
            -
             
     | 
| 
       82 
     | 
    
         
            -
            .toolbar.isDense {
         
     | 
| 
       83 
     | 
    
         
            -
                @include spacing.bottom(layouts, $compensation: theme.$gap-dense);
         
     | 
| 
       84 
     | 
    
         
            -
            }
         
     | 
| 
       85 
     | 
    
         
            -
             
     | 
| 
       86 
     | 
    
         
            -
            .toolbar:not(.isDense) > .isDense,
         
     | 
| 
       87 
     | 
    
         
            -
            .group:not(.isDense) > .isDense {
         
     | 
| 
       88 
     | 
    
         
            -
                margin: theme.$gap-dense;
         
     | 
| 
       89 
     | 
    
         
            -
            }
         
     | 
| 
         @@ -1,6 +1,6 @@ 
     | 
|
| 
       1 
1 
     | 
    
         
             
            import PropTypes from 'prop-types';
         
     | 
| 
       2 
2 
     | 
    
         
             
            import React from 'react';
         
     | 
| 
       3 
     | 
    
         
            -
            import {  
     | 
| 
      
 3 
     | 
    
         
            +
            import { withGlobalProps } from '../../provider';
         
     | 
| 
       4 
4 
     | 
    
         
             
            import { classNames } from '../../utils/classNames';
         
     | 
| 
       5 
5 
     | 
    
         
             
            import { isChildrenEmpty } from '../_helpers/isChildrenEmpty';
         
     | 
| 
       6 
6 
     | 
    
         
             
            import styles from './Toolbar.scss';
         
     | 
| 
         @@ -9,6 +9,7 @@ export const ToolbarGroup = ({ 
     | 
|
| 
       9 
9 
     | 
    
         
             
              align,
         
     | 
| 
       10 
10 
     | 
    
         
             
              children,
         
     | 
| 
       11 
11 
     | 
    
         
             
              dense,
         
     | 
| 
      
 12 
     | 
    
         
            +
              id,
         
     | 
| 
       12 
13 
     | 
    
         
             
              nowrap,
         
     | 
| 
       13 
14 
     | 
    
         
             
            }) => {
         
     | 
| 
       14 
15 
     | 
    
         
             
              if (isChildrenEmpty(children)) {
         
     | 
| 
         @@ -39,6 +40,7 @@ export const ToolbarGroup = ({ 
     | 
|
| 
       39 
40 
     | 
    
         
             
                    nowrap && styles.isNowrap,
         
     | 
| 
       40 
41 
     | 
    
         
             
                    alignClass(align),
         
     | 
| 
       41 
42 
     | 
    
         
             
                  )}
         
     | 
| 
      
 43 
     | 
    
         
            +
                  id={id}
         
     | 
| 
       42 
44 
     | 
    
         
             
                >
         
     | 
| 
       43 
45 
     | 
    
         
             
                  {children}
         
     | 
| 
       44 
46 
     | 
    
         
             
                </div>
         
     | 
| 
         @@ -49,6 +51,7 @@ ToolbarGroup.defaultProps = { 
     | 
|
| 
       49 
51 
     | 
    
         
             
              align: 'top',
         
     | 
| 
       50 
52 
     | 
    
         
             
              children: null,
         
     | 
| 
       51 
53 
     | 
    
         
             
              dense: false,
         
     | 
| 
      
 54 
     | 
    
         
            +
              id: undefined,
         
     | 
| 
       52 
55 
     | 
    
         
             
              nowrap: false,
         
     | 
| 
       53 
56 
     | 
    
         
             
            };
         
     | 
| 
       54 
57 
     | 
    
         | 
| 
         @@ -65,12 +68,16 @@ ToolbarGroup.propTypes = { 
     | 
|
| 
       65 
68 
     | 
    
         
             
               * If `true`, spacing of toolbar items in the group will be reduced.
         
     | 
| 
       66 
69 
     | 
    
         
             
               */
         
     | 
| 
       67 
70 
     | 
    
         
             
              dense: PropTypes.bool,
         
     | 
| 
      
 71 
     | 
    
         
            +
              /**
         
     | 
| 
      
 72 
     | 
    
         
            +
               * ID of the root HTML element.
         
     | 
| 
      
 73 
     | 
    
         
            +
               */
         
     | 
| 
      
 74 
     | 
    
         
            +
              id: PropTypes.string,
         
     | 
| 
       68 
75 
     | 
    
         
             
              /**
         
     | 
| 
       69 
76 
     | 
    
         
             
               * If set, the toolbar group will not wrap.
         
     | 
| 
       70 
77 
     | 
    
         
             
               */
         
     | 
| 
       71 
78 
     | 
    
         
             
              nowrap: PropTypes.bool,
         
     | 
| 
       72 
79 
     | 
    
         
             
            };
         
     | 
| 
       73 
80 
     | 
    
         | 
| 
       74 
     | 
    
         
            -
            export const  
     | 
| 
      
 81 
     | 
    
         
            +
            export const ToolbarGroupWithGlobalProps = withGlobalProps(ToolbarGroup, 'ToolbarGroup');
         
     | 
| 
       75 
82 
     | 
    
         | 
| 
       76 
     | 
    
         
            -
            export default  
     | 
| 
      
 83 
     | 
    
         
            +
            export default ToolbarGroupWithGlobalProps;
         
     | 
| 
         @@ -1,13 +1,14 @@ 
     | 
|
| 
       1 
1 
     | 
    
         
             
            import PropTypes from 'prop-types';
         
     | 
| 
       2 
2 
     | 
    
         
             
            import React from 'react';
         
     | 
| 
       3 
3 
     | 
    
         
             
            import { classNames } from '../../utils/classNames';
         
     | 
| 
       4 
     | 
    
         
            -
            import {  
     | 
| 
      
 4 
     | 
    
         
            +
            import { withGlobalProps } from '../../provider';
         
     | 
| 
       5 
5 
     | 
    
         
             
            import { isChildrenEmpty } from '../_helpers/isChildrenEmpty';
         
     | 
| 
       6 
6 
     | 
    
         
             
            import styles from './Toolbar.scss';
         
     | 
| 
       7 
7 
     | 
    
         | 
| 
       8 
8 
     | 
    
         
             
            export const ToolbarItem = ({
         
     | 
| 
       9 
9 
     | 
    
         
             
              children,
         
     | 
| 
       10 
10 
     | 
    
         
             
              flexible,
         
     | 
| 
      
 11 
     | 
    
         
            +
              id,
         
     | 
| 
       11 
12 
     | 
    
         
             
            }) => {
         
     | 
| 
       12 
13 
     | 
    
         
             
              if (isChildrenEmpty(children)) {
         
     | 
| 
       13 
14 
     | 
    
         
             
                return null;
         
     | 
| 
         @@ -19,6 +20,7 @@ export const ToolbarItem = ({ 
     | 
|
| 
       19 
20 
     | 
    
         
             
                    styles.item,
         
     | 
| 
       20 
21 
     | 
    
         
             
                    flexible && styles.isItemFlexible,
         
     | 
| 
       21 
22 
     | 
    
         
             
                  )}
         
     | 
| 
      
 23 
     | 
    
         
            +
                  id={id}
         
     | 
| 
       22 
24 
     | 
    
         
             
                >
         
     | 
| 
       23 
25 
     | 
    
         
             
                  {children}
         
     | 
| 
       24 
26 
     | 
    
         
             
                </div>
         
     | 
| 
         @@ -28,6 +30,7 @@ export const ToolbarItem = ({ 
     | 
|
| 
       28 
30 
     | 
    
         
             
            ToolbarItem.defaultProps = {
         
     | 
| 
       29 
31 
     | 
    
         
             
              children: null,
         
     | 
| 
       30 
32 
     | 
    
         
             
              flexible: false,
         
     | 
| 
      
 33 
     | 
    
         
            +
              id: undefined,
         
     | 
| 
       31 
34 
     | 
    
         
             
            };
         
     | 
| 
       32 
35 
     | 
    
         | 
| 
       33 
36 
     | 
    
         
             
            ToolbarItem.propTypes = {
         
     | 
| 
         @@ -39,8 +42,12 @@ ToolbarItem.propTypes = { 
     | 
|
| 
       39 
42 
     | 
    
         
             
               * Allow item to grow and shrink if needed.
         
     | 
| 
       40 
43 
     | 
    
         
             
               */
         
     | 
| 
       41 
44 
     | 
    
         
             
              flexible: PropTypes.bool,
         
     | 
| 
      
 45 
     | 
    
         
            +
              /**
         
     | 
| 
      
 46 
     | 
    
         
            +
               * ID of the root HTML element.
         
     | 
| 
      
 47 
     | 
    
         
            +
               */
         
     | 
| 
      
 48 
     | 
    
         
            +
              id: PropTypes.string,
         
     | 
| 
       42 
49 
     | 
    
         
             
            };
         
     | 
| 
       43 
50 
     | 
    
         | 
| 
       44 
     | 
    
         
            -
            export const  
     | 
| 
      
 51 
     | 
    
         
            +
            export const ToolbarItemWithGlobalProps = withGlobalProps(ToolbarItem, 'ToolbarItem');
         
     | 
| 
       45 
52 
     | 
    
         | 
| 
       46 
     | 
    
         
            -
            export default  
     | 
| 
      
 53 
     | 
    
         
            +
            export default ToolbarItemWithGlobalProps;
         
     | 
    
        package/src/lib/index.js
    CHANGED
    
    | 
         @@ -18,17 +18,12 @@ export { 
     | 
|
| 
       18 
18 
     | 
    
         
             
              Grid,
         
     | 
| 
       19 
19 
     | 
    
         
             
              GridSpan,
         
     | 
| 
       20 
20 
     | 
    
         
             
            } from './components/Grid';
         
     | 
| 
       21 
     | 
    
         
            -
            export {
         
     | 
| 
       22 
     | 
    
         
            -
              List,
         
     | 
| 
       23 
     | 
    
         
            -
              ListItem,
         
     | 
| 
       24 
     | 
    
         
            -
            } from './components/List';
         
     | 
| 
       25 
     | 
    
         
            -
            export {
         
     | 
| 
       26 
     | 
    
         
            -
              Media,
         
     | 
| 
       27 
     | 
    
         
            -
              MediaBody,
         
     | 
| 
       28 
     | 
    
         
            -
              MediaObject,
         
     | 
| 
       29 
     | 
    
         
            -
            } from './components/Media';
         
     | 
| 
       30 
21 
     | 
    
         
             
            export { default as Modal } from './components/Modal';
         
     | 
| 
       31 
22 
     | 
    
         
             
            export { default as Paper } from './components/Paper';
         
     | 
| 
      
 23 
     | 
    
         
            +
            export {
         
     | 
| 
      
 24 
     | 
    
         
            +
              Popover,
         
     | 
| 
      
 25 
     | 
    
         
            +
              PopoverWrapper,
         
     | 
| 
      
 26 
     | 
    
         
            +
            } from './components/Popover';
         
     | 
| 
       32 
27 
     | 
    
         
             
            export { default as Radio } from './components/Radio';
         
     | 
| 
       33 
28 
     | 
    
         
             
            export { default as ScrollView } from './components/ScrollView';
         
     | 
| 
       34 
29 
     | 
    
         
             
            export { default as SelectField } from './components/SelectField';
         
     | 
| 
         @@ -0,0 +1,21 @@ 
     | 
|
| 
      
 1 
     | 
    
         
            +
            import React from 'react';
         
     | 
| 
      
 2 
     | 
    
         
            +
            import RUIContext from './RUIContext';
         
     | 
| 
      
 3 
     | 
    
         
            +
             
     | 
| 
      
 4 
     | 
    
         
            +
            export default (Component, componentName) => {
         
     | 
| 
      
 5 
     | 
    
         
            +
              const WithGlobalPropsComponent = (props) => (
         
     | 
| 
      
 6 
     | 
    
         
            +
                <RUIContext.Consumer>
         
     | 
| 
      
 7 
     | 
    
         
            +
                  {({ globalProps }) => {
         
     | 
| 
      
 8 
     | 
    
         
            +
                    const contextGlobalProps = globalProps ? globalProps[componentName] : null;
         
     | 
| 
      
 9 
     | 
    
         
            +
             
     | 
| 
      
 10 
     | 
    
         
            +
                    return (
         
     | 
| 
      
 11 
     | 
    
         
            +
                      <Component
         
     | 
| 
      
 12 
     | 
    
         
            +
                        {...contextGlobalProps}
         
     | 
| 
      
 13 
     | 
    
         
            +
                        {...props}
         
     | 
| 
      
 14 
     | 
    
         
            +
                      />
         
     | 
| 
      
 15 
     | 
    
         
            +
                    );
         
     | 
| 
      
 16 
     | 
    
         
            +
                  }}
         
     | 
| 
      
 17 
     | 
    
         
            +
                </RUIContext.Consumer>
         
     | 
| 
      
 18 
     | 
    
         
            +
              );
         
     | 
| 
      
 19 
     | 
    
         
            +
             
     | 
| 
      
 20 
     | 
    
         
            +
              return WithGlobalPropsComponent;
         
     | 
| 
      
 21 
     | 
    
         
            +
            };
         
     | 
| 
         @@ -8,5 +8,5 @@ $sm: map.get(breakpoints.$values, sm); 
     | 
|
| 
       8 
8 
     | 
    
         
             
            $md: map.get(breakpoints.$values, md);
         
     | 
| 
       9 
9 
     | 
    
         
             
            $lg: map.get(breakpoints.$values, lg);
         
     | 
| 
       10 
10 
     | 
    
         
             
            $xl: map.get(breakpoints.$values, xl);
         
     | 
| 
       11 
     | 
    
         
            -
            $ 
     | 
| 
       12 
     | 
    
         
            -
            $ 
     | 
| 
      
 11 
     | 
    
         
            +
            $x2l: map.get(breakpoints.$values, x2l);
         
     | 
| 
      
 12 
     | 
    
         
            +
            $x3l: map.get(breakpoints.$values, x3l);
         
     | 
| 
         @@ -11,17 +11,13 @@ 
     | 
|
| 
       11 
11 
     | 
    
         
             
                }
         
     | 
| 
       12 
12 
     | 
    
         
             
            }
         
     | 
| 
       13 
13 
     | 
    
         | 
| 
       14 
     | 
    
         
            -
            @mixin bottom($category: default 
     | 
| 
      
 14 
     | 
    
         
            +
            @mixin bottom($category: default) {
         
     | 
| 
       15 
15 
     | 
    
         
             
                @if not map.has-key(spacing.$bottom, $category) {
         
     | 
| 
       16 
16 
     | 
    
         
             
                    @error "Invalid spacing category specified! #{$category} doesn't exist. "
         
     | 
| 
       17 
17 
     | 
    
         
             
                        + "Choose one of #{map.keys(spacing.$bottom)}.";
         
     | 
| 
       18 
18 
     | 
    
         
             
                }
         
     | 
| 
       19 
19 
     | 
    
         | 
| 
       20 
20 
     | 
    
         
             
                &:not(:last-child) {
         
     | 
| 
       21 
     | 
    
         
            -
                     
     | 
| 
       22 
     | 
    
         
            -
                        margin-bottom: calc(#{map.get(spacing.$bottom, $category)} - #{$compensation});
         
     | 
| 
       23 
     | 
    
         
            -
                    } @else {
         
     | 
| 
       24 
     | 
    
         
            -
                        margin-bottom: map.get(spacing.$bottom, $category);
         
     | 
| 
       25 
     | 
    
         
            -
                    }
         
     | 
| 
      
 21 
     | 
    
         
            +
                    margin-bottom: map.get(spacing.$bottom, $category);
         
     | 
| 
       26 
22 
     | 
    
         
             
                }
         
     | 
| 
       27 
23 
     | 
    
         
             
            }
         
     | 
    
        package/src/lib/theme.scss
    CHANGED
    
    | 
         @@ -98,8 +98,8 @@ 
     | 
|
| 
       98 
98 
     | 
    
         
             
                --rui-breakpoint-md: #{breakpoints.$md};
         
     | 
| 
       99 
99 
     | 
    
         
             
                --rui-breakpoint-lg: #{breakpoints.$lg};
         
     | 
| 
       100 
100 
     | 
    
         
             
                --rui-breakpoint-xl: #{breakpoints.$xl};
         
     | 
| 
       101 
     | 
    
         
            -
                --rui-breakpoint- 
     | 
| 
       102 
     | 
    
         
            -
                --rui-breakpoint- 
     | 
| 
      
 101 
     | 
    
         
            +
                --rui-breakpoint-x2l: #{breakpoints.$x2l};
         
     | 
| 
      
 102 
     | 
    
         
            +
                --rui-breakpoint-x3l: #{breakpoints.$x3l};
         
     | 
| 
       103 
103 
     | 
    
         | 
| 
       104 
104 
     | 
    
         
             
                // Spacing
         
     | 
| 
       105 
105 
     | 
    
         
             
                --rui-spacing-0: 0;
         
     | 
| 
         @@ -145,6 +145,7 @@ 
     | 
|
| 
       145 
145 
     | 
    
         | 
| 
       146 
146 
     | 
    
         
             
                // Elevations
         
     | 
| 
       147 
147 
     | 
    
         
             
                --rui-elevation-1: 0 0.01rem 0.65rem -0.1rem #{rgba(0, 0, 0, 0.3)};
         
     | 
| 
      
 148 
     | 
    
         
            +
                --rui-elevation-2: 0.2rem 0.25rem 1.2rem -0.1rem #{rgba(0, 0, 0, 0.15)};
         
     | 
| 
       148 
149 
     | 
    
         | 
| 
       149 
150 
     | 
    
         
             
                // Accessibility
         
     | 
| 
       150 
151 
     | 
    
         
             
                --rui-tap-target-size: 10mm;
         
     | 
| 
         @@ -199,28 +200,15 @@ 
     | 
|
| 
       199 
200 
     | 
    
         
             
                // Grid
         
     | 
| 
       200 
201 
     | 
    
         
             
                // ====
         
     | 
| 
       201 
202 
     | 
    
         | 
| 
       202 
     | 
    
         
            -
                --rui-Grid__columns: 1fr;
         
     | 
| 
       203 
203 
     | 
    
         
             
                --rui-Grid__column-gap: var(--rui-spacing-4);
         
     | 
| 
       204 
     | 
    
         
            -
                --rui-Grid__rows: auto;
         
     | 
| 
       205 
204 
     | 
    
         
             
                --rui-Grid__row-gap: var(--rui-spacing-4);
         
     | 
| 
       206 
     | 
    
         
            -
                --rui-Grid__auto-flow: initial;
         
     | 
| 
       207 
     | 
    
         
            -
                --rui-Grid__align-content: initial;
         
     | 
| 
       208 
     | 
    
         
            -
                --rui-Grid__align-items: initial;
         
     | 
| 
       209 
     | 
    
         
            -
                --rui-Grid__justify-content: initial;
         
     | 
| 
       210 
     | 
    
         
            -
                --rui-Grid__justify-items: initial;
         
     | 
| 
       211 
     | 
    
         
            -
             
     | 
| 
       212 
     | 
    
         
            -
                //
         
     | 
| 
       213 
     | 
    
         
            -
                // List
         
     | 
| 
       214 
     | 
    
         
            -
                // ====
         
     | 
| 
       215 
     | 
    
         
            -
             
     | 
| 
       216 
     | 
    
         
            -
                --rui-List__row-gap: var(--rui-spacing-2);
         
     | 
| 
       217 
205 
     | 
    
         | 
| 
       218 
206 
     | 
    
         
             
                //
         
     | 
| 
       219 
207 
     | 
    
         
             
                // Toolbar
         
     | 
| 
       220 
208 
     | 
    
         
             
                // =======
         
     | 
| 
       221 
209 
     | 
    
         | 
| 
       222 
     | 
    
         
            -
                --rui-Toolbar__gap: var(--rui-spacing- 
     | 
| 
       223 
     | 
    
         
            -
                --rui-Toolbar__gap--dense: var(--rui-spacing- 
     | 
| 
      
 210 
     | 
    
         
            +
                --rui-Toolbar__gap: var(--rui-spacing-4);
         
     | 
| 
      
 211 
     | 
    
         
            +
                --rui-Toolbar__gap--dense: var(--rui-spacing-2);
         
     | 
| 
       224 
212 
     | 
    
         | 
| 
       225 
213 
     | 
    
         
             
                // ============================================================================================ //
         
     | 
| 
       226 
214 
     | 
    
         
             
                // 3. UI COMPONENTS                                                                             //
         
     | 
| 
         @@ -876,7 +864,7 @@ 
     | 
|
| 
       876 
864 
     | 
    
         
             
                // =====
         
     | 
| 
       877 
865 
     | 
    
         | 
| 
       878 
866 
     | 
    
         
             
                --rui-Modal__background: var(--rui-color-white);
         
     | 
| 
       879 
     | 
    
         
            -
                --rui-Modal__box-shadow:  
     | 
| 
      
 867 
     | 
    
         
            +
                --rui-Modal__box-shadow: var(--rui-elevation-2);
         
     | 
| 
       880 
868 
     | 
    
         
             
                --rui-Modal__outer-spacing--xs: var(--rui-spacing-2);
         
     | 
| 
       881 
869 
     | 
    
         
             
                --rui-Modal__outer-spacing--sm: var(--rui-spacing-6);
         
     | 
| 
       882 
870 
     | 
    
         
             
                --rui-Modal__footer__background: var(--rui-color-gray-100);
         
     | 
| 
         @@ -902,6 +890,19 @@ 
     | 
|
| 
       902 
890 
     | 
    
         
             
                --rui-Paper--muted__opacity: var(--rui-disabled-opacity);
         
     | 
| 
       903 
891 
     | 
    
         
             
                --rui-Paper--raised__box-shadow: var(--rui-elevation-1);
         
     | 
| 
       904 
892 
     | 
    
         | 
| 
      
 893 
     | 
    
         
            +
                //
         
     | 
| 
      
 894 
     | 
    
         
            +
                // Popover
         
     | 
| 
      
 895 
     | 
    
         
            +
                // =======
         
     | 
| 
      
 896 
     | 
    
         
            +
             
     | 
| 
      
 897 
     | 
    
         
            +
                --rui-Popover__width: 15rem;
         
     | 
| 
      
 898 
     | 
    
         
            +
                --rui-Popover__padding: var(--rui-spacing-3);
         
     | 
| 
      
 899 
     | 
    
         
            +
                --rui-Popover__border-width: 0;
         
     | 
| 
      
 900 
     | 
    
         
            +
                --rui-Popover__border-color: transparent;
         
     | 
| 
      
 901 
     | 
    
         
            +
                --rui-Popover__border-radius: var(--rui-border-radius);
         
     | 
| 
      
 902 
     | 
    
         
            +
                --rui-Popover__color: var(--rui-color-black);
         
     | 
| 
      
 903 
     | 
    
         
            +
                --rui-Popover__background-color: var(--rui-color-white);
         
     | 
| 
      
 904 
     | 
    
         
            +
                --rui-Popover__box-shadow: var(--rui-elevation-2);
         
     | 
| 
      
 905 
     | 
    
         
            +
             
     | 
| 
       905 
906 
     | 
    
         
             
                //
         
     | 
| 
       906 
907 
     | 
    
         
             
                // ScrollView
         
     | 
| 
       907 
908 
     | 
    
         
             
                // ==========
         
     | 
| 
         @@ -1,73 +0,0 @@ 
     | 
|
| 
       1 
     | 
    
         
            -
            import PropTypes from 'prop-types';
         
     | 
| 
       2 
     | 
    
         
            -
            import React from 'react';
         
     | 
| 
       3 
     | 
    
         
            -
            import { withProviderContext } from '../../provider';
         
     | 
| 
       4 
     | 
    
         
            -
            import { classNames } from '../../utils/classNames';
         
     | 
| 
       5 
     | 
    
         
            -
            import { isChildrenEmpty } from '../_helpers/isChildrenEmpty';
         
     | 
| 
       6 
     | 
    
         
            -
            import styles from './List.scss';
         
     | 
| 
       7 
     | 
    
         
            -
             
     | 
| 
       8 
     | 
    
         
            -
            export const List = ({
         
     | 
| 
       9 
     | 
    
         
            -
              align,
         
     | 
| 
       10 
     | 
    
         
            -
              autoWidth,
         
     | 
| 
       11 
     | 
    
         
            -
              children,
         
     | 
| 
       12 
     | 
    
         
            -
            }) => {
         
     | 
| 
       13 
     | 
    
         
            -
              if (isChildrenEmpty(children)) {
         
     | 
| 
       14 
     | 
    
         
            -
                return null;
         
     | 
| 
       15 
     | 
    
         
            -
              }
         
     | 
| 
       16 
     | 
    
         
            -
             
     | 
| 
       17 
     | 
    
         
            -
              let alignClass;
         
     | 
| 
       18 
     | 
    
         
            -
             
     | 
| 
       19 
     | 
    
         
            -
              if (align === 'start') {
         
     | 
| 
       20 
     | 
    
         
            -
                alignClass = styles.alignStart;
         
     | 
| 
       21 
     | 
    
         
            -
              } else if (align === 'end') {
         
     | 
| 
       22 
     | 
    
         
            -
                alignClass = styles.alignEnd;
         
     | 
| 
       23 
     | 
    
         
            -
              }
         
     | 
| 
       24 
     | 
    
         
            -
             
     | 
| 
       25 
     | 
    
         
            -
              let autoWidthClass;
         
     | 
| 
       26 
     | 
    
         
            -
             
     | 
| 
       27 
     | 
    
         
            -
              if (autoWidth) {
         
     | 
| 
       28 
     | 
    
         
            -
                autoWidthClass = styles.isAutoWidth;
         
     | 
| 
       29 
     | 
    
         
            -
              }
         
     | 
| 
       30 
     | 
    
         
            -
             
     | 
| 
       31 
     | 
    
         
            -
              return (
         
     | 
| 
       32 
     | 
    
         
            -
                <div
         
     | 
| 
       33 
     | 
    
         
            -
                  className={classNames(
         
     | 
| 
       34 
     | 
    
         
            -
                    styles.root,
         
     | 
| 
       35 
     | 
    
         
            -
                    autoWidthClass,
         
     | 
| 
       36 
     | 
    
         
            -
                  )}
         
     | 
| 
       37 
     | 
    
         
            -
                >
         
     | 
| 
       38 
     | 
    
         
            -
                  <ul
         
     | 
| 
       39 
     | 
    
         
            -
                    className={classNames(
         
     | 
| 
       40 
     | 
    
         
            -
                      styles.list,
         
     | 
| 
       41 
     | 
    
         
            -
                      alignClass,
         
     | 
| 
       42 
     | 
    
         
            -
                    )}
         
     | 
| 
       43 
     | 
    
         
            -
                  >
         
     | 
| 
       44 
     | 
    
         
            -
                    {children}
         
     | 
| 
       45 
     | 
    
         
            -
                  </ul>
         
     | 
| 
       46 
     | 
    
         
            -
                </div>
         
     | 
| 
       47 
     | 
    
         
            -
              );
         
     | 
| 
       48 
     | 
    
         
            -
            };
         
     | 
| 
       49 
     | 
    
         
            -
             
     | 
| 
       50 
     | 
    
         
            -
            List.defaultProps = {
         
     | 
| 
       51 
     | 
    
         
            -
              align: 'start',
         
     | 
| 
       52 
     | 
    
         
            -
              autoWidth: false,
         
     | 
| 
       53 
     | 
    
         
            -
              children: null,
         
     | 
| 
       54 
     | 
    
         
            -
            };
         
     | 
| 
       55 
     | 
    
         
            -
             
     | 
| 
       56 
     | 
    
         
            -
            List.propTypes = {
         
     | 
| 
       57 
     | 
    
         
            -
              /**
         
     | 
| 
       58 
     | 
    
         
            -
               * Horizontal alignment of list items.
         
     | 
| 
       59 
     | 
    
         
            -
               */
         
     | 
| 
       60 
     | 
    
         
            -
              align: PropTypes.oneOf(['start', 'end']),
         
     | 
| 
       61 
     | 
    
         
            -
              /**
         
     | 
| 
       62 
     | 
    
         
            -
               * If `true`, the list items will take up only as much horizontal space as necessary.
         
     | 
| 
       63 
     | 
    
         
            -
               */
         
     | 
| 
       64 
     | 
    
         
            -
              autoWidth: PropTypes.bool,
         
     | 
| 
       65 
     | 
    
         
            -
              /**
         
     | 
| 
       66 
     | 
    
         
            -
               * Individual ListItems. If none are provided nothing is rendered.
         
     | 
| 
       67 
     | 
    
         
            -
               */
         
     | 
| 
       68 
     | 
    
         
            -
              children: PropTypes.node,
         
     | 
| 
       69 
     | 
    
         
            -
            };
         
     | 
| 
       70 
     | 
    
         
            -
             
     | 
| 
       71 
     | 
    
         
            -
            export const ListWithContext = withProviderContext(List, 'List');
         
     | 
| 
       72 
     | 
    
         
            -
             
     | 
| 
       73 
     | 
    
         
            -
            export default ListWithContext;
         
     | 
| 
         @@ -1,53 +0,0 @@ 
     | 
|
| 
       1 
     | 
    
         
            -
            @use "../../styles/tools/reset";
         
     | 
| 
       2 
     | 
    
         
            -
            @use "../../styles/tools/spacing";
         
     | 
| 
       3 
     | 
    
         
            -
            @use "theme";
         
     | 
| 
       4 
     | 
    
         
            -
             
     | 
| 
       5 
     | 
    
         
            -
            .root {
         
     | 
| 
       6 
     | 
    
         
            -
                @include spacing.bottom(layouts);
         
     | 
| 
       7 
     | 
    
         
            -
            }
         
     | 
| 
       8 
     | 
    
         
            -
             
     | 
| 
       9 
     | 
    
         
            -
            .list {
         
     | 
| 
       10 
     | 
    
         
            -
                @include reset.list();
         
     | 
| 
       11 
     | 
    
         
            -
             
     | 
| 
       12 
     | 
    
         
            -
                display: flex;
         
     | 
| 
       13 
     | 
    
         
            -
                flex-direction: column;
         
     | 
| 
       14 
     | 
    
         
            -
            }
         
     | 
| 
       15 
     | 
    
         
            -
             
     | 
| 
       16 
     | 
    
         
            -
            .item {
         
     | 
| 
       17 
     | 
    
         
            -
                width: 100%;
         
     | 
| 
       18 
     | 
    
         
            -
                margin-bottom: theme.$row-gap;
         
     | 
| 
       19 
     | 
    
         
            -
             
     | 
| 
       20 
     | 
    
         
            -
                &:last-child {
         
     | 
| 
       21 
     | 
    
         
            -
                    margin-bottom: 0;
         
     | 
| 
       22 
     | 
    
         
            -
                }
         
     | 
| 
       23 
     | 
    
         
            -
            }
         
     | 
| 
       24 
     | 
    
         
            -
             
     | 
| 
       25 
     | 
    
         
            -
            .alignStart {
         
     | 
| 
       26 
     | 
    
         
            -
                align-items: flex-start;
         
     | 
| 
       27 
     | 
    
         
            -
                text-align: left;
         
     | 
| 
       28 
     | 
    
         
            -
            }
         
     | 
| 
       29 
     | 
    
         
            -
             
     | 
| 
       30 
     | 
    
         
            -
            .alignEnd {
         
     | 
| 
       31 
     | 
    
         
            -
                align-items: flex-end;
         
     | 
| 
       32 
     | 
    
         
            -
                text-align: right;
         
     | 
| 
       33 
     | 
    
         
            -
            }
         
     | 
| 
       34 
     | 
    
         
            -
             
     | 
| 
       35 
     | 
    
         
            -
            [dir="rtl"] .alignStart {
         
     | 
| 
       36 
     | 
    
         
            -
                text-align: right;
         
     | 
| 
       37 
     | 
    
         
            -
            }
         
     | 
| 
       38 
     | 
    
         
            -
             
     | 
| 
       39 
     | 
    
         
            -
            [dir="rtl"] .alignEnd {
         
     | 
| 
       40 
     | 
    
         
            -
                text-align: left;
         
     | 
| 
       41 
     | 
    
         
            -
            }
         
     | 
| 
       42 
     | 
    
         
            -
             
     | 
| 
       43 
     | 
    
         
            -
            .isAutoWidth .list {
         
     | 
| 
       44 
     | 
    
         
            -
                display: inline-flex;
         
     | 
| 
       45 
     | 
    
         
            -
            }
         
     | 
| 
       46 
     | 
    
         
            -
             
     | 
| 
       47 
     | 
    
         
            -
            .isAutoWidth .item {
         
     | 
| 
       48 
     | 
    
         
            -
                width: auto;
         
     | 
| 
       49 
     | 
    
         
            -
            }
         
     | 
| 
       50 
     | 
    
         
            -
             
     | 
| 
       51 
     | 
    
         
            -
            .item .root {
         
     | 
| 
       52 
     | 
    
         
            -
                margin-bottom: 0;
         
     | 
| 
       53 
     | 
    
         
            -
            }
         
     | 
| 
         @@ -1,32 +0,0 @@ 
     | 
|
| 
       1 
     | 
    
         
            -
            import PropTypes from 'prop-types';
         
     | 
| 
       2 
     | 
    
         
            -
            import React from 'react';
         
     | 
| 
       3 
     | 
    
         
            -
            import { withProviderContext } from '../../provider';
         
     | 
| 
       4 
     | 
    
         
            -
            import { isChildrenEmpty } from '../_helpers/isChildrenEmpty';
         
     | 
| 
       5 
     | 
    
         
            -
            import styles from './List.scss';
         
     | 
| 
       6 
     | 
    
         
            -
             
     | 
| 
       7 
     | 
    
         
            -
            export const ListItem = ({ children }) => {
         
     | 
| 
       8 
     | 
    
         
            -
              if (isChildrenEmpty(children)) {
         
     | 
| 
       9 
     | 
    
         
            -
                return null;
         
     | 
| 
       10 
     | 
    
         
            -
              }
         
     | 
| 
       11 
     | 
    
         
            -
             
     | 
| 
       12 
     | 
    
         
            -
              return (
         
     | 
| 
       13 
     | 
    
         
            -
                <li className={styles.item}>
         
     | 
| 
       14 
     | 
    
         
            -
                  {children}
         
     | 
| 
       15 
     | 
    
         
            -
                </li>
         
     | 
| 
       16 
     | 
    
         
            -
              );
         
     | 
| 
       17 
     | 
    
         
            -
            };
         
     | 
| 
       18 
     | 
    
         
            -
             
     | 
| 
       19 
     | 
    
         
            -
            ListItem.defaultProps = {
         
     | 
| 
       20 
     | 
    
         
            -
              children: null,
         
     | 
| 
       21 
     | 
    
         
            -
            };
         
     | 
| 
       22 
     | 
    
         
            -
             
     | 
| 
       23 
     | 
    
         
            -
            ListItem.propTypes = {
         
     | 
| 
       24 
     | 
    
         
            -
              /**
         
     | 
| 
       25 
     | 
    
         
            -
               * Content of the list item. If none are provided nothing is rendered.
         
     | 
| 
       26 
     | 
    
         
            -
               */
         
     | 
| 
       27 
     | 
    
         
            -
              children: PropTypes.node,
         
     | 
| 
       28 
     | 
    
         
            -
            };
         
     | 
| 
       29 
     | 
    
         
            -
             
     | 
| 
       30 
     | 
    
         
            -
            export const ListItemWithContext = withProviderContext(ListItem, 'ListItem');
         
     | 
| 
       31 
     | 
    
         
            -
             
     | 
| 
       32 
     | 
    
         
            -
            export default ListItemWithContext;
         
     |