@salutejs/plasma-new-hope 0.237.1-dev.0 → 0.238.0-dev.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.
Files changed (85) hide show
  1. package/cjs/components/Flow/Flow.css +2 -0
  2. package/cjs/components/Flow/Flow.js +84 -0
  3. package/cjs/components/Flow/Flow.js.map +1 -0
  4. package/cjs/components/Flow/Flow.styles.js +17 -0
  5. package/cjs/components/Flow/Flow.styles.js.map +1 -0
  6. package/cjs/components/Flow/Flow.styles_q8k0on.css +2 -0
  7. package/cjs/index.css +3 -0
  8. package/cjs/index.js +3 -0
  9. package/cjs/index.js.map +1 -1
  10. package/emotion/cjs/components/Flow/Flow.js +92 -0
  11. package/emotion/cjs/components/Flow/Flow.styles.js +31 -0
  12. package/emotion/cjs/components/Flow/Flow.template-doc.mdx +127 -0
  13. package/emotion/cjs/components/Flow/Flow.types.js +5 -0
  14. package/emotion/cjs/components/Flow/index.js +18 -0
  15. package/emotion/cjs/examples/plasma_b2c/components/Flow/Flow.config.js +10 -0
  16. package/emotion/cjs/examples/plasma_b2c/components/Flow/Flow.js +11 -0
  17. package/emotion/cjs/examples/plasma_b2c/components/Flow/Flow.stories.tsx +135 -0
  18. package/emotion/cjs/examples/plasma_web/components/Flow/Flow.config.js +10 -0
  19. package/emotion/cjs/examples/plasma_web/components/Flow/Flow.js +11 -0
  20. package/emotion/cjs/examples/plasma_web/components/Flow/Flow.stories.tsx +135 -0
  21. package/emotion/cjs/index.js +11 -0
  22. package/emotion/es/components/Flow/Flow.js +83 -0
  23. package/emotion/es/components/Flow/Flow.styles.js +24 -0
  24. package/emotion/es/components/Flow/Flow.template-doc.mdx +127 -0
  25. package/emotion/es/components/Flow/Flow.types.js +1 -0
  26. package/emotion/es/components/Flow/index.js +1 -0
  27. package/emotion/es/examples/plasma_b2c/components/Flow/Flow.config.js +4 -0
  28. package/emotion/es/examples/plasma_b2c/components/Flow/Flow.js +5 -0
  29. package/emotion/es/examples/plasma_b2c/components/Flow/Flow.stories.tsx +135 -0
  30. package/emotion/es/examples/plasma_web/components/Flow/Flow.config.js +4 -0
  31. package/emotion/es/examples/plasma_web/components/Flow/Flow.js +5 -0
  32. package/emotion/es/examples/plasma_web/components/Flow/Flow.stories.tsx +135 -0
  33. package/emotion/es/index.js +2 -0
  34. package/es/components/Flow/Flow.css +2 -0
  35. package/es/components/Flow/Flow.js +79 -0
  36. package/es/components/Flow/Flow.js.map +1 -0
  37. package/es/components/Flow/Flow.styles.js +12 -0
  38. package/es/components/Flow/Flow.styles.js.map +1 -0
  39. package/es/components/Flow/Flow.styles_q8k0on.css +2 -0
  40. package/es/index.css +3 -0
  41. package/es/index.js +1 -0
  42. package/es/index.js.map +1 -1
  43. package/package.json +4 -2
  44. package/styled-components/cjs/components/Flow/Flow.js +92 -0
  45. package/styled-components/cjs/components/Flow/Flow.styles.js +16 -0
  46. package/styled-components/cjs/components/Flow/Flow.template-doc.mdx +127 -0
  47. package/styled-components/cjs/components/Flow/Flow.types.js +5 -0
  48. package/styled-components/cjs/components/Flow/index.js +18 -0
  49. package/styled-components/cjs/examples/plasma_b2c/components/Flow/Flow.config.js +10 -0
  50. package/styled-components/cjs/examples/plasma_b2c/components/Flow/Flow.js +11 -0
  51. package/styled-components/cjs/examples/plasma_b2c/components/Flow/Flow.stories.tsx +135 -0
  52. package/styled-components/cjs/examples/plasma_web/components/Flow/Flow.config.js +10 -0
  53. package/styled-components/cjs/examples/plasma_web/components/Flow/Flow.js +11 -0
  54. package/styled-components/cjs/examples/plasma_web/components/Flow/Flow.stories.tsx +135 -0
  55. package/styled-components/cjs/index.js +11 -0
  56. package/styled-components/es/components/Flow/Flow.js +83 -0
  57. package/styled-components/es/components/Flow/Flow.styles.js +8 -0
  58. package/styled-components/es/components/Flow/Flow.template-doc.mdx +127 -0
  59. package/styled-components/es/components/Flow/Flow.types.js +1 -0
  60. package/styled-components/es/components/Flow/index.js +1 -0
  61. package/styled-components/es/examples/plasma_b2c/components/Flow/Flow.config.js +4 -0
  62. package/styled-components/es/examples/plasma_b2c/components/Flow/Flow.js +5 -0
  63. package/styled-components/es/examples/plasma_b2c/components/Flow/Flow.stories.tsx +135 -0
  64. package/styled-components/es/examples/plasma_web/components/Flow/Flow.config.js +4 -0
  65. package/styled-components/es/examples/plasma_web/components/Flow/Flow.js +5 -0
  66. package/styled-components/es/examples/plasma_web/components/Flow/Flow.stories.tsx +135 -0
  67. package/styled-components/es/index.js +2 -0
  68. package/types/components/Flow/Flow.d.ts +33 -0
  69. package/types/components/Flow/Flow.d.ts.map +1 -0
  70. package/types/components/Flow/Flow.styles.d.ts +4 -0
  71. package/types/components/Flow/Flow.styles.d.ts.map +1 -0
  72. package/types/components/Flow/Flow.types.d.ts +34 -0
  73. package/types/components/Flow/Flow.types.d.ts.map +1 -0
  74. package/types/components/Flow/index.d.ts +3 -0
  75. package/types/components/Flow/index.d.ts.map +1 -0
  76. package/types/examples/plasma_b2c/components/Flow/Flow.config.d.ts +5 -0
  77. package/types/examples/plasma_b2c/components/Flow/Flow.config.d.ts.map +1 -0
  78. package/types/examples/plasma_b2c/components/Flow/Flow.d.ts +5 -0
  79. package/types/examples/plasma_b2c/components/Flow/Flow.d.ts.map +1 -0
  80. package/types/examples/plasma_web/components/Flow/Flow.config.d.ts +5 -0
  81. package/types/examples/plasma_web/components/Flow/Flow.config.d.ts.map +1 -0
  82. package/types/examples/plasma_web/components/Flow/Flow.d.ts +5 -0
  83. package/types/examples/plasma_web/components/Flow/Flow.d.ts.map +1 -0
  84. package/types/index.d.ts +2 -0
  85. package/types/index.d.ts.map +1 -1
@@ -0,0 +1,135 @@
1
+ import React, { ComponentProps } from 'react';
2
+ import type { StoryObj, Meta } from '@storybook/react';
3
+ import styled from 'styled-components';
4
+ import { disableProps } from '@salutejs/plasma-sb-utils';
5
+
6
+ import { WithTheme } from '../../../_helpers';
7
+
8
+ import { Flow } from './Flow';
9
+
10
+ const orientations = ['vertical', 'horizontal'];
11
+ const arrangements = ['start', 'center', 'end', 'spaceBetween', 'spaceAround'];
12
+ const alignments = ['start', 'center', 'end'];
13
+
14
+ const widths = [100, 32, 171, 74, 179, 55];
15
+ const heights = [10, 50, 45, 33, 14, 55];
16
+
17
+ const FlowCustom = styled(Flow)`
18
+ background: var(--surface-transparent-primary);
19
+ border-radius: 0.5rem;
20
+ `;
21
+
22
+ const Item = styled.div`
23
+ padding: 0.5rem 1rem;
24
+ border-radius: 0.5rem;
25
+ background: #aab1e9;
26
+ display: flex;
27
+ align-items: center;
28
+ justify-content: center;
29
+ `;
30
+
31
+ const meta: Meta<typeof Flow> = {
32
+ title: 'b2c/Layout/Flow',
33
+ component: Flow,
34
+ decorators: [WithTheme],
35
+ argTypes: {
36
+ itemsCount: {
37
+ control: {
38
+ type: 'number',
39
+ },
40
+ },
41
+ containerWidth: {
42
+ control: {
43
+ type: 'text',
44
+ },
45
+ },
46
+ containerHeight: {
47
+ control: {
48
+ type: 'text',
49
+ },
50
+ },
51
+ orientation: {
52
+ options: orientations,
53
+ control: {
54
+ type: 'select',
55
+ },
56
+ },
57
+ arrangement: {
58
+ options: arrangements,
59
+ control: {
60
+ type: 'select',
61
+ },
62
+ },
63
+ alignment: {
64
+ options: alignments,
65
+ control: {
66
+ type: 'select',
67
+ },
68
+ },
69
+ mainAxisGap: {
70
+ control: {
71
+ type: 'text',
72
+ },
73
+ },
74
+ crossAxisGap: {
75
+ control: {
76
+ type: 'text',
77
+ },
78
+ },
79
+ itemsPerLine: {
80
+ control: {
81
+ type: 'text',
82
+ },
83
+ },
84
+ minColWidth: {
85
+ control: {
86
+ type: 'text',
87
+ },
88
+ },
89
+ ...disableProps(['minColWidth']),
90
+ },
91
+ };
92
+
93
+ export default meta;
94
+
95
+ type Story = StoryObj<typeof Flow>;
96
+
97
+ export const Default: Story = {
98
+ args: {
99
+ containerWidth: '450px',
100
+ containerHeight: '200px',
101
+ orientation: 'horizontal',
102
+ arrangement: 'start',
103
+ alignment: 'start',
104
+ mainAxisGap: '10',
105
+ crossAxisGap: '10',
106
+ itemsPerLine: '',
107
+ itemsCount: 6,
108
+ },
109
+ render: ({ itemsCount, containerWidth, containerHeight, ...args }: ComponentProps<typeof Flow>) => {
110
+ const hasLines = Boolean(args.itemsPerLine);
111
+
112
+ return (
113
+ <FlowCustom {...args} style={{ width: containerWidth, height: containerHeight }}>
114
+ {new Array(itemsCount).fill(null).map((width, index) => (
115
+ <Item
116
+ key={index}
117
+ style={
118
+ hasLines
119
+ ? {
120
+ minWidth: widths[index % widths.length],
121
+ minHeight: heights[index % heights.length],
122
+ }
123
+ : {
124
+ width: widths[index % widths.length],
125
+ height: heights[index % heights.length],
126
+ }
127
+ }
128
+ >
129
+ {index + 1}
130
+ </Item>
131
+ ))}
132
+ </FlowCustom>
133
+ );
134
+ },
135
+ };
@@ -0,0 +1,4 @@
1
+ export var config = {
2
+ defaults: {},
3
+ variations: {}
4
+ };
@@ -0,0 +1,5 @@
1
+ import { flowConfig } from '../../../../components/Flow';
2
+ import { component, mergeConfig } from '../../../../engines';
3
+ import { config } from './Flow.config';
4
+ var mergedConfig = /*#__PURE__*/mergeConfig(flowConfig, config);
5
+ export var Flow = /*#__PURE__*/component(mergedConfig);
@@ -0,0 +1,135 @@
1
+ import React, { ComponentProps } from 'react';
2
+ import type { StoryObj, Meta } from '@storybook/react';
3
+ import styled from 'styled-components';
4
+ import { disableProps } from '@salutejs/plasma-sb-utils';
5
+
6
+ import { WithTheme } from '../../../_helpers';
7
+
8
+ import { Flow } from './Flow';
9
+
10
+ const orientations = ['vertical', 'horizontal'];
11
+ const arrangements = ['start', 'center', 'end', 'spaceBetween', 'spaceAround'];
12
+ const alignments = ['start', 'center', 'end'];
13
+
14
+ const widths = [100, 32, 171, 74, 179, 55];
15
+ const heights = [10, 50, 45, 33, 14, 55];
16
+
17
+ const FlowCustom = styled(Flow)`
18
+ background: var(--surface-transparent-primary);
19
+ border-radius: 0.5rem;
20
+ `;
21
+
22
+ const Item = styled.div`
23
+ padding: 0.5rem 1rem;
24
+ border-radius: 0.5rem;
25
+ background: #aab1e9;
26
+ display: flex;
27
+ align-items: center;
28
+ justify-content: center;
29
+ `;
30
+
31
+ const meta: Meta<typeof Flow> = {
32
+ title: 'web/Layout/Flow',
33
+ component: Flow,
34
+ decorators: [WithTheme],
35
+ argTypes: {
36
+ itemsCount: {
37
+ control: {
38
+ type: 'number',
39
+ },
40
+ },
41
+ containerWidth: {
42
+ control: {
43
+ type: 'text',
44
+ },
45
+ },
46
+ containerHeight: {
47
+ control: {
48
+ type: 'text',
49
+ },
50
+ },
51
+ orientation: {
52
+ options: orientations,
53
+ control: {
54
+ type: 'select',
55
+ },
56
+ },
57
+ arrangement: {
58
+ options: arrangements,
59
+ control: {
60
+ type: 'select',
61
+ },
62
+ },
63
+ alignment: {
64
+ options: alignments,
65
+ control: {
66
+ type: 'select',
67
+ },
68
+ },
69
+ mainAxisGap: {
70
+ control: {
71
+ type: 'text',
72
+ },
73
+ },
74
+ crossAxisGap: {
75
+ control: {
76
+ type: 'text',
77
+ },
78
+ },
79
+ itemsPerLine: {
80
+ control: {
81
+ type: 'text',
82
+ },
83
+ },
84
+ minColWidth: {
85
+ control: {
86
+ type: 'text',
87
+ },
88
+ },
89
+ ...disableProps(['minColWidth']),
90
+ },
91
+ };
92
+
93
+ export default meta;
94
+
95
+ type Story = StoryObj<typeof Flow>;
96
+
97
+ export const Default: Story = {
98
+ args: {
99
+ containerWidth: '450px',
100
+ containerHeight: '200px',
101
+ orientation: 'horizontal',
102
+ arrangement: 'start',
103
+ alignment: 'start',
104
+ mainAxisGap: '10',
105
+ crossAxisGap: '10',
106
+ itemsPerLine: '',
107
+ itemsCount: 6,
108
+ },
109
+ render: ({ itemsCount, containerWidth, containerHeight, ...args }: ComponentProps<typeof Flow>) => {
110
+ const hasLines = Boolean(args.itemsPerLine);
111
+
112
+ return (
113
+ <FlowCustom {...args} style={{ width: containerWidth, height: containerHeight }}>
114
+ {new Array(itemsCount).fill(null).map((width, index) => (
115
+ <Item
116
+ key={index}
117
+ style={
118
+ hasLines
119
+ ? {
120
+ minWidth: widths[index % widths.length],
121
+ minHeight: heights[index % heights.length],
122
+ }
123
+ : {
124
+ width: widths[index % widths.length],
125
+ height: heights[index % heights.length],
126
+ }
127
+ }
128
+ >
129
+ {index + 1}
130
+ </Item>
131
+ ))}
132
+ </FlowCustom>
133
+ );
134
+ },
135
+ };
@@ -12,6 +12,7 @@ export * from './components/Breadcrumbs';
12
12
  export * from './components/Chip';
13
13
  export * from './components/ChipGroup';
14
14
  export * from './components/Cell';
15
+ export * from './components/Flow';
15
16
  export * from './components/Link';
16
17
  export * from './components/Spinner';
17
18
  export * from './components/Checkbox';
@@ -44,6 +45,7 @@ export * from './components/SSRProvider';
44
45
  export * from './components/Combobox';
45
46
  export * from './components/Indicator';
46
47
  export * from './components/ButtonBase';
48
+ export * from './components/Flow';
47
49
  export * from './components/Grid';
48
50
  export * from './components/Progress';
49
51
  export * from './components/Select';
@@ -0,0 +1,2 @@
1
+ .Flow_styles_q8k0on_b1iyfec1__5db9d70e{display:-webkit-box;display:-webkit-flex;display:-ms-flexbox;display:flex;-webkit-flex-direction:row;-ms-flex-direction:row;flex-direction:row;-webkit-flex-wrap:wrap;-ms-flex-wrap:wrap;flex-wrap:wrap;gap:var(--plasma-private-gap);}.Flow_styles_q8k0on_b1iyfec1__5db9d70e.Flow_styles_q8k0on_hasChunks__5db9d70e{-webkit-flex-wrap:nowrap;-ms-flex-wrap:nowrap;flex-wrap:nowrap;-webkit-flex-direction:column;-ms-flex-direction:column;flex-direction:column;}.Flow_styles_q8k0on_b1iyfec1__5db9d70e.Flow_styles_q8k0on_hasChunks__5db9d70e.Flow_styles_q8k0on_vertical__5db9d70e{-webkit-flex-direction:row;-ms-flex-direction:row;flex-direction:row;}.Flow_styles_q8k0on_b1iyfec1__5db9d70e.Flow_styles_q8k0on_vertical__5db9d70e{-webkit-flex-direction:column;-ms-flex-direction:column;flex-direction:column;}.Flow_styles_q8k0on_b1iyfec1__5db9d70e.Flow_styles_q8k0on_grid__5db9d70e{display:grid;grid-template-columns:repeat(var(--plasma-private-items),auto);grid-auto-flow:row;}.Flow_styles_q8k0on_b1iyfec1__5db9d70e.Flow_styles_q8k0on_grid__5db9d70e.Flow_styles_q8k0on_elastic__5db9d70e{grid-template-columns:repeat(auto-fill,minmax(var(--plasma-private-min-width),auto));grid-auto-flow:row;}.Flow_styles_q8k0on_b1iyfec1__5db9d70e.Flow_styles_q8k0on_grid__5db9d70e:not(.Flow_styles_q8k0on_vertical__5db9d70e)[data-arrangement='start']{justify-items:start;}.Flow_styles_q8k0on_b1iyfec1__5db9d70e.Flow_styles_q8k0on_grid__5db9d70e:not(.Flow_styles_q8k0on_vertical__5db9d70e)[data-arrangement='center']{justify-items:center;}.Flow_styles_q8k0on_b1iyfec1__5db9d70e.Flow_styles_q8k0on_grid__5db9d70e:not(.Flow_styles_q8k0on_vertical__5db9d70e)[data-arrangement='end']{justify-items:end;}.Flow_styles_q8k0on_b1iyfec1__5db9d70e.Flow_styles_q8k0on_grid__5db9d70e:not(.Flow_styles_q8k0on_vertical__5db9d70e)[data-arrangement='spaceBetween']{-webkit-box-pack:justify;-webkit-justify-content:space-between;-ms-flex-pack:justify;justify-content:space-between;}.Flow_styles_q8k0on_b1iyfec1__5db9d70e.Flow_styles_q8k0on_grid__5db9d70e:not(.Flow_styles_q8k0on_vertical__5db9d70e)[data-arrangement='spaceAround']{-webkit-box-pack:space-around;-webkit-justify-content:space-around;-ms-flex-pack:space-around;justify-content:space-around;}.Flow_styles_q8k0on_b1iyfec1__5db9d70e.Flow_styles_q8k0on_grid__5db9d70e:not(.Flow_styles_q8k0on_vertical__5db9d70e)[data-alignment='start']{-webkit-align-items:start;-webkit-box-align:start;-ms-flex-align:start;align-items:start;}.Flow_styles_q8k0on_b1iyfec1__5db9d70e.Flow_styles_q8k0on_grid__5db9d70e:not(.Flow_styles_q8k0on_vertical__5db9d70e)[data-alignment='center']{-webkit-align-items:center;-webkit-box-align:center;-ms-flex-align:center;align-items:center;}.Flow_styles_q8k0on_b1iyfec1__5db9d70e.Flow_styles_q8k0on_grid__5db9d70e:not(.Flow_styles_q8k0on_vertical__5db9d70e)[data-alignment='end']{-webkit-align-items:end;-webkit-box-align:end;-ms-flex-align:end;align-items:end;}.Flow_styles_q8k0on_b1iyfec1__5db9d70e.Flow_styles_q8k0on_grid__5db9d70e.Flow_styles_q8k0on_vertical__5db9d70e{grid-template-columns:auto;grid-template-rows:repeat(var(--plasma-private-items),auto);grid-auto-flow:column;}.Flow_styles_q8k0on_b1iyfec1__5db9d70e.Flow_styles_q8k0on_grid__5db9d70e.Flow_styles_q8k0on_vertical__5db9d70e[data-arrangement='start']{-webkit-align-items:start;-webkit-box-align:start;-ms-flex-align:start;align-items:start;}.Flow_styles_q8k0on_b1iyfec1__5db9d70e.Flow_styles_q8k0on_grid__5db9d70e.Flow_styles_q8k0on_vertical__5db9d70e[data-arrangement='center']{-webkit-align-items:center;-webkit-box-align:center;-ms-flex-align:center;align-items:center;}.Flow_styles_q8k0on_b1iyfec1__5db9d70e.Flow_styles_q8k0on_grid__5db9d70e.Flow_styles_q8k0on_vertical__5db9d70e[data-arrangement='end']{-webkit-align-items:end;-webkit-box-align:end;-ms-flex-align:end;align-items:end;}.Flow_styles_q8k0on_b1iyfec1__5db9d70e.Flow_styles_q8k0on_grid__5db9d70e.Flow_styles_q8k0on_vertical__5db9d70e[data-arrangement='spaceBetween']{-webkit-align-content:space-between;-ms-flex-line-pack:space-between;align-content:space-between;-webkit-align-items:normal;-webkit-box-align:normal;-ms-flex-align:normal;align-items:normal;}.Flow_styles_q8k0on_b1iyfec1__5db9d70e.Flow_styles_q8k0on_grid__5db9d70e.Flow_styles_q8k0on_vertical__5db9d70e[data-arrangement='spaceAround']{-webkit-align-content:space-around;-ms-flex-line-pack:space-around;align-content:space-around;-webkit-align-items:normal;-webkit-box-align:normal;-ms-flex-align:normal;align-items:normal;}.Flow_styles_q8k0on_b1iyfec1__5db9d70e.Flow_styles_q8k0on_grid__5db9d70e.Flow_styles_q8k0on_vertical__5db9d70e[data-alignment='start']{justify-items:start;}.Flow_styles_q8k0on_b1iyfec1__5db9d70e.Flow_styles_q8k0on_grid__5db9d70e.Flow_styles_q8k0on_vertical__5db9d70e[data-alignment='center']{justify-items:center;}.Flow_styles_q8k0on_b1iyfec1__5db9d70e.Flow_styles_q8k0on_grid__5db9d70e.Flow_styles_q8k0on_vertical__5db9d70e[data-alignment='end']{justify-items:end;}.Flow_styles_q8k0on_b1iyfec1__5db9d70e:not(.Flow_styles_q8k0on_b1iyfec1__5db9d70e.Flow_styles_q8k0on_grid__5db9d70e):not(.Flow_styles_q8k0on_b1iyfec1__5db9d70e.Flow_styles_q8k0on_hasChunks__5db9d70e){-webkit-align-content:start;-ms-flex-line-pack:start;align-content:start;}.Flow_styles_q8k0on_b1iyfec1__5db9d70e:not(.Flow_styles_q8k0on_b1iyfec1__5db9d70e.Flow_styles_q8k0on_grid__5db9d70e):not(.Flow_styles_q8k0on_b1iyfec1__5db9d70e.Flow_styles_q8k0on_hasChunks__5db9d70e)[data-arrangement='start']{-webkit-box-pack:start;-webkit-justify-content:start;-ms-flex-pack:start;justify-content:start;}.Flow_styles_q8k0on_b1iyfec1__5db9d70e:not(.Flow_styles_q8k0on_b1iyfec1__5db9d70e.Flow_styles_q8k0on_grid__5db9d70e):not(.Flow_styles_q8k0on_b1iyfec1__5db9d70e.Flow_styles_q8k0on_hasChunks__5db9d70e)[data-arrangement='center']{-webkit-box-pack:center;-webkit-justify-content:center;-ms-flex-pack:center;justify-content:center;}.Flow_styles_q8k0on_b1iyfec1__5db9d70e:not(.Flow_styles_q8k0on_b1iyfec1__5db9d70e.Flow_styles_q8k0on_grid__5db9d70e):not(.Flow_styles_q8k0on_b1iyfec1__5db9d70e.Flow_styles_q8k0on_hasChunks__5db9d70e)[data-arrangement='end']{-webkit-box-pack:end;-webkit-justify-content:end;-ms-flex-pack:end;justify-content:end;}.Flow_styles_q8k0on_b1iyfec1__5db9d70e:not(.Flow_styles_q8k0on_b1iyfec1__5db9d70e.Flow_styles_q8k0on_grid__5db9d70e):not(.Flow_styles_q8k0on_b1iyfec1__5db9d70e.Flow_styles_q8k0on_hasChunks__5db9d70e)[data-arrangement='spaceBetween']{-webkit-box-pack:justify;-webkit-justify-content:space-between;-ms-flex-pack:justify;justify-content:space-between;}.Flow_styles_q8k0on_b1iyfec1__5db9d70e:not(.Flow_styles_q8k0on_b1iyfec1__5db9d70e.Flow_styles_q8k0on_grid__5db9d70e):not(.Flow_styles_q8k0on_b1iyfec1__5db9d70e.Flow_styles_q8k0on_hasChunks__5db9d70e)[data-arrangement='spaceAround']{-webkit-box-pack:space-around;-webkit-justify-content:space-around;-ms-flex-pack:space-around;justify-content:space-around;}.Flow_styles_q8k0on_b1iyfec1__5db9d70e:not(.Flow_styles_q8k0on_b1iyfec1__5db9d70e.Flow_styles_q8k0on_grid__5db9d70e):not(.Flow_styles_q8k0on_b1iyfec1__5db9d70e.Flow_styles_q8k0on_hasChunks__5db9d70e)[data-alignment='start']{-webkit-align-items:start;-webkit-box-align:start;-ms-flex-align:start;align-items:start;}.Flow_styles_q8k0on_b1iyfec1__5db9d70e:not(.Flow_styles_q8k0on_b1iyfec1__5db9d70e.Flow_styles_q8k0on_grid__5db9d70e):not(.Flow_styles_q8k0on_b1iyfec1__5db9d70e.Flow_styles_q8k0on_hasChunks__5db9d70e)[data-alignment='center']{-webkit-align-items:center;-webkit-box-align:center;-ms-flex-align:center;align-items:center;}.Flow_styles_q8k0on_b1iyfec1__5db9d70e:not(.Flow_styles_q8k0on_b1iyfec1__5db9d70e.Flow_styles_q8k0on_grid__5db9d70e):not(.Flow_styles_q8k0on_b1iyfec1__5db9d70e.Flow_styles_q8k0on_hasChunks__5db9d70e)[data-alignment='end']{-webkit-align-items:end;-webkit-box-align:end;-ms-flex-align:end;align-items:end;}
2
+ .Flow_styles_q8k0on_lxs138i__5db9d70e{display:-webkit-box;display:-webkit-flex;display:-ms-flexbox;display:flex;gap:var(--plasma-private-gap);}.Flow_styles_q8k0on_lxs138i__5db9d70e.Flow_styles_q8k0on_vertical__5db9d70e{-webkit-flex-direction:column;-ms-flex-direction:column;flex-direction:column;height:100%;}.Flow_styles_q8k0on_lxs138i__5db9d70e[data-arrangement='start']{-webkit-box-pack:start;-webkit-justify-content:start;-ms-flex-pack:start;justify-content:start;}.Flow_styles_q8k0on_lxs138i__5db9d70e[data-arrangement='center']{-webkit-box-pack:center;-webkit-justify-content:center;-ms-flex-pack:center;justify-content:center;}.Flow_styles_q8k0on_lxs138i__5db9d70e[data-arrangement='end']{-webkit-box-pack:end;-webkit-justify-content:end;-ms-flex-pack:end;justify-content:end;}.Flow_styles_q8k0on_lxs138i__5db9d70e[data-arrangement='spaceBetween']{-webkit-box-pack:justify;-webkit-justify-content:space-between;-ms-flex-pack:justify;justify-content:space-between;}.Flow_styles_q8k0on_lxs138i__5db9d70e[data-arrangement='spaceAround']{-webkit-box-pack:space-around;-webkit-justify-content:space-around;-ms-flex-pack:space-around;justify-content:space-around;}.Flow_styles_q8k0on_lxs138i__5db9d70e[data-alignment='start']{-webkit-align-items:start;-webkit-box-align:start;-ms-flex-align:start;align-items:start;}.Flow_styles_q8k0on_lxs138i__5db9d70e[data-alignment='center']{-webkit-align-items:center;-webkit-box-align:center;-ms-flex-align:center;align-items:center;}.Flow_styles_q8k0on_lxs138i__5db9d70e[data-alignment='end']{-webkit-align-items:end;-webkit-box-align:end;-ms-flex-align:end;align-items:end;}
@@ -0,0 +1,79 @@
1
+ import { objectWithoutProperties as _objectWithoutProperties, extends as _extends, objectSpread2 as _objectSpread2 } from '../../_virtual/_rollupPluginBabelHelpers.js';
2
+ import React, { forwardRef } from 'react';
3
+ import cls from 'classnames';
4
+ import chunk from 'lodash.chunk';
5
+ import { Line, base } from './Flow.styles.js';
6
+
7
+ var _excluded = ["children", "className", "style", "orientation", "arrangement", "alignment", "mainAxisGap", "crossAxisGap", "minColWidth", "itemsPerLine"];
8
+ var flowRoot = function flowRoot(Root) {
9
+ return /*#__PURE__*/forwardRef(function (_ref, ref) {
10
+ var children = _ref.children,
11
+ className = _ref.className,
12
+ style = _ref.style,
13
+ _ref$orientation = _ref.orientation,
14
+ orientation = _ref$orientation === void 0 ? 'horizontal' : _ref$orientation,
15
+ arrangement = _ref.arrangement,
16
+ alignment = _ref.alignment,
17
+ _ref$mainAxisGap = _ref.mainAxisGap,
18
+ mainAxisGap = _ref$mainAxisGap === void 0 ? '0' : _ref$mainAxisGap,
19
+ _ref$crossAxisGap = _ref.crossAxisGap,
20
+ crossAxisGap = _ref$crossAxisGap === void 0 ? '0' : _ref$crossAxisGap,
21
+ _ref$minColWidth = _ref.minColWidth,
22
+ minColWidth = _ref$minColWidth === void 0 ? 'auto' : _ref$minColWidth,
23
+ itemsPerLine = _ref.itemsPerLine,
24
+ rest = _objectWithoutProperties(_ref, _excluded);
25
+ var isVertical = orientation === 'vertical';
26
+ var hasMinWidth = Boolean(minColWidth && minColWidth !== 'auto');
27
+ var needGrid = Boolean(Number(itemsPerLine) > 0 || hasMinWidth);
28
+ var innerMainAxisGap = typeof mainAxisGap === 'number' || !Number.isNaN(+mainAxisGap) ? "".concat(mainAxisGap || 0, "px") : mainAxisGap;
29
+ var innerCrossAxisGap = typeof crossAxisGap === 'number' || !Number.isNaN(+crossAxisGap) ? "".concat(crossAxisGap || 0, "px") : crossAxisGap;
30
+ if (arrangement === 'spaceBetween' || arrangement === 'spaceAround') {
31
+ innerMainAxisGap = '0';
32
+ }
33
+ var hasChunks = Number(itemsPerLine) > 0;
34
+ var chunks = hasChunks ? chunk(React.Children.toArray(children), itemsPerLine) : [];
35
+ var gap = isVertical ? "".concat(innerMainAxisGap, " ").concat(innerCrossAxisGap) : "".concat(innerCrossAxisGap, " ").concat(innerMainAxisGap);
36
+ var wrapperGap = isVertical ? "0 ".concat(innerCrossAxisGap) : "".concat(innerCrossAxisGap, " 0");
37
+ var lineGap = isVertical ? "".concat(innerMainAxisGap, " 0") : "0 ".concat(innerMainAxisGap);
38
+ return /*#__PURE__*/React.createElement(Root, _extends({
39
+ ref: ref,
40
+ className: cls(className, {
41
+ vertical: isVertical,
42
+ grid: hasMinWidth,
43
+ elastic: hasMinWidth,
44
+ hasChunks: hasChunks
45
+ }),
46
+ style: _objectSpread2(_objectSpread2({}, style), {}, {
47
+ '--plasma-private-gap': hasChunks ? wrapperGap : gap,
48
+ '--plasma-private-items': String(itemsPerLine),
49
+ '--plasma-private-min-width': String(minColWidth)
50
+ }),
51
+ "data-arrangement": arrangement,
52
+ "data-alignment": alignment
53
+ }, rest), hasChunks && chunks.map(function (chunkNode) {
54
+ return /*#__PURE__*/React.createElement(Line, {
55
+ className: cls({
56
+ vertical: isVertical,
57
+ grid: needGrid,
58
+ elastic: hasMinWidth
59
+ }),
60
+ style: {
61
+ '--plasma-private-gap': lineGap
62
+ },
63
+ "data-arrangement": arrangement,
64
+ "data-alignment": alignment
65
+ }, chunkNode);
66
+ }), !hasChunks && children);
67
+ });
68
+ };
69
+ var flowConfig = {
70
+ name: 'Flow',
71
+ tag: 'div',
72
+ layout: flowRoot,
73
+ base: base,
74
+ defaults: {},
75
+ variations: {}
76
+ };
77
+
78
+ export { flowConfig, flowRoot };
79
+ //# sourceMappingURL=Flow.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"Flow.js","sources":["../../../src/components/Flow/Flow.tsx"],"sourcesContent":["import React, { CSSProperties, forwardRef } from 'react';\nimport cls from 'classnames';\nimport chunk from 'lodash.chunk';\n\nimport { RootProps } from '../../engines';\n\nimport { base, Line } from './Flow.styles';\nimport { FlowProps } from './Flow.types';\n\ntype TempFlowTypes = FlowProps & {\n /**\n * Минимальный размер колонки для эластичной сетки с динамическим количеством растянутых столбцов\n * через `repeat(auto-fill, minmax(${minColWidth}, auto))`\n */\n minColWidth?: string;\n};\n\nexport const flowRoot = (Root: RootProps<HTMLDivElement, TempFlowTypes>) =>\n forwardRef<HTMLDivElement, TempFlowTypes>(\n (\n {\n children,\n className,\n style,\n orientation = 'horizontal',\n arrangement,\n alignment,\n mainAxisGap = '0',\n crossAxisGap = '0',\n minColWidth = 'auto',\n itemsPerLine,\n ...rest\n },\n ref,\n ) => {\n const isVertical = orientation === 'vertical';\n const hasMinWidth = Boolean(minColWidth && minColWidth !== 'auto');\n const needGrid = Boolean(Number(itemsPerLine) > 0 || hasMinWidth);\n\n let innerMainAxisGap =\n typeof mainAxisGap === 'number' || !Number.isNaN(+mainAxisGap) ? `${mainAxisGap || 0}px` : mainAxisGap;\n const innerCrossAxisGap =\n typeof crossAxisGap === 'number' || !Number.isNaN(+crossAxisGap)\n ? `${crossAxisGap || 0}px`\n : crossAxisGap;\n\n if (arrangement === 'spaceBetween' || arrangement === 'spaceAround') {\n innerMainAxisGap = '0';\n }\n\n const hasChunks = Number(itemsPerLine) > 0;\n const chunks: React.ReactNode[] = hasChunks ? chunk(React.Children.toArray(children), itemsPerLine) : [];\n\n const gap = isVertical\n ? `${innerMainAxisGap} ${innerCrossAxisGap}`\n : `${innerCrossAxisGap} ${innerMainAxisGap}`;\n\n const wrapperGap = isVertical ? `0 ${innerCrossAxisGap}` : `${innerCrossAxisGap} 0`;\n const lineGap = isVertical ? `${innerMainAxisGap} 0` : `0 ${innerMainAxisGap}`;\n\n return (\n <Root\n ref={ref}\n className={cls(className, {\n vertical: isVertical,\n grid: hasMinWidth,\n elastic: hasMinWidth,\n hasChunks,\n })}\n style={\n {\n ...style,\n '--plasma-private-gap': hasChunks ? wrapperGap : gap,\n '--plasma-private-items': String(itemsPerLine),\n '--plasma-private-min-width': String(minColWidth),\n } as CSSProperties & {\n '--plasma-private-gap': string;\n '--plasma-private-items': string;\n '--plasma-private-min-width': string;\n }\n }\n data-arrangement={arrangement}\n data-alignment={alignment}\n {...rest}\n >\n {hasChunks &&\n chunks.map((chunkNode) => (\n <Line\n className={cls({\n vertical: isVertical,\n grid: needGrid,\n elastic: hasMinWidth,\n })}\n style={\n {\n '--plasma-private-gap': lineGap,\n } as CSSProperties & {\n '--plasma-private-gap': string;\n }\n }\n data-arrangement={arrangement}\n data-alignment={alignment}\n >\n {chunkNode}\n </Line>\n ))}\n {!hasChunks && children}\n </Root>\n );\n },\n );\n\nexport const flowConfig = {\n name: 'Flow',\n tag: 'div',\n layout: flowRoot,\n base,\n defaults: {},\n variations: {},\n};\n"],"names":["flowRoot","Root","forwardRef","_ref","ref","children","className","style","_ref$orientation","orientation","arrangement","alignment","_ref$mainAxisGap","mainAxisGap","_ref$crossAxisGap","crossAxisGap","_ref$minColWidth","minColWidth","itemsPerLine","rest","_objectWithoutProperties","_excluded","isVertical","hasMinWidth","Boolean","needGrid","Number","innerMainAxisGap","isNaN","concat","innerCrossAxisGap","hasChunks","chunks","chunk","React","Children","toArray","gap","wrapperGap","lineGap","createElement","_extends","cls","vertical","grid","elastic","_objectSpread","String","map","chunkNode","Line","flowConfig","name","tag","layout","base","defaults","variations"],"mappings":"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"}
@@ -0,0 +1,12 @@
1
+ import './Flow.styles_q8k0on.css';
2
+ import { styled } from '@linaria/react';
3
+
4
+ var base = "b1iyfec1";
5
+ var Line = /*#__PURE__*/styled('div')({
6
+ name: "Line",
7
+ "class": "lxs138i",
8
+ propsAsIs: false
9
+ });
10
+
11
+ export { Line, base };
12
+ //# sourceMappingURL=Flow.styles.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"Flow.styles.js","sources":["../../../src/components/Flow/Flow.styles.ts"],"sourcesContent":["import { css } from '@linaria/core';\nimport { styled } from '@linaria/react';\n\nexport const base = css`\n display: flex;\n flex-direction: row;\n flex-wrap: wrap;\n\n gap: var(--plasma-private-gap);\n\n &.hasChunks {\n flex-wrap: nowrap;\n flex-direction: column;\n\n &.vertical {\n flex-direction: row;\n }\n }\n\n &.vertical {\n flex-direction: column;\n }\n\n &.grid {\n display: grid;\n\n grid-template-columns: repeat(var(--plasma-private-items), auto);\n grid-auto-flow: row;\n\n &.elastic {\n grid-template-columns: repeat(auto-fill, minmax(var(--plasma-private-min-width), auto));\n grid-auto-flow: row;\n }\n\n &:not(.vertical) {\n &[data-arrangement='start'] {\n justify-items: start;\n }\n\n &[data-arrangement='center'] {\n justify-items: center;\n }\n\n &[data-arrangement='end'] {\n justify-items: end;\n }\n\n &[data-arrangement='spaceBetween'] {\n justify-content: space-between;\n }\n\n &[data-arrangement='spaceAround'] {\n justify-content: space-around;\n }\n\n &[data-alignment='start'] {\n align-items: start;\n }\n\n &[data-alignment='center'] {\n align-items: center;\n }\n\n &[data-alignment='end'] {\n align-items: end;\n }\n }\n\n &.vertical {\n grid-template-columns: auto;\n grid-template-rows: repeat(var(--plasma-private-items), auto);\n grid-auto-flow: column;\n\n &[data-arrangement='start'] {\n align-items: start;\n }\n\n &[data-arrangement='center'] {\n align-items: center;\n }\n\n &[data-arrangement='end'] {\n align-items: end;\n }\n\n &[data-arrangement='spaceBetween'] {\n align-content: space-between;\n align-items: normal;\n }\n\n &[data-arrangement='spaceAround'] {\n align-content: space-around;\n align-items: normal;\n }\n\n &[data-alignment='start'] {\n justify-items: start;\n }\n\n &[data-alignment='center'] {\n justify-items: center;\n }\n\n &[data-alignment='end'] {\n justify-items: end;\n }\n }\n }\n\n &:not(&.grid):not(&.hasChunks) {\n align-content: start;\n\n &[data-arrangement='start'] {\n justify-content: start;\n }\n\n &[data-arrangement='center'] {\n justify-content: center;\n }\n\n &[data-arrangement='end'] {\n justify-content: end;\n }\n\n &[data-arrangement='spaceBetween'] {\n justify-content: space-between;\n }\n\n &[data-arrangement='spaceAround'] {\n justify-content: space-around;\n }\n\n &[data-alignment='start'] {\n align-items: start;\n }\n\n &[data-alignment='center'] {\n align-items: center;\n }\n\n &[data-alignment='end'] {\n align-items: end;\n }\n }\n`;\n\nexport const Line = styled.div`\n display: flex;\n\n gap: var(--plasma-private-gap);\n\n &.vertical {\n flex-direction: column;\n height: 100%;\n }\n\n &[data-arrangement='start'] {\n justify-content: start;\n }\n\n &[data-arrangement='center'] {\n justify-content: center;\n }\n\n &[data-arrangement='end'] {\n justify-content: end;\n }\n\n &[data-arrangement='spaceBetween'] {\n justify-content: space-between;\n }\n\n &[data-arrangement='spaceAround'] {\n justify-content: space-around;\n }\n\n &[data-alignment='start'] {\n align-items: start;\n }\n\n &[data-alignment='center'] {\n align-items: center;\n }\n\n &[data-alignment='end'] {\n align-items: end;\n }\n`;\n"],"names":["base","Line","styled","name","class","propsAsIs"],"mappings":";;AAGO,IAAMA,IAAI,GA6IhB,WAAA;AAEM,IAAMC,IAAI,gBAAGC,MAAM,CAAA,KAAA,CAAA,CAAA;AAAAC,EAAAA,IAAA,EAAA,MAAA;AAAAC,EAAAA,OAAAA,EAAA,SAAA;AAAAC,EAAAA,SAAA,EAAA,KAAA;AAAA,CAyCzB;;;;"}
@@ -0,0 +1,2 @@
1
+ .b1iyfec1{display:-webkit-box;display:-webkit-flex;display:-ms-flexbox;display:flex;-webkit-flex-direction:row;-ms-flex-direction:row;flex-direction:row;-webkit-flex-wrap:wrap;-ms-flex-wrap:wrap;flex-wrap:wrap;gap:var(--plasma-private-gap);}.b1iyfec1.hasChunks{-webkit-flex-wrap:nowrap;-ms-flex-wrap:nowrap;flex-wrap:nowrap;-webkit-flex-direction:column;-ms-flex-direction:column;flex-direction:column;}.b1iyfec1.hasChunks.vertical{-webkit-flex-direction:row;-ms-flex-direction:row;flex-direction:row;}.b1iyfec1.vertical{-webkit-flex-direction:column;-ms-flex-direction:column;flex-direction:column;}.b1iyfec1.grid{display:grid;grid-template-columns:repeat(var(--plasma-private-items),auto);grid-auto-flow:row;}.b1iyfec1.grid.elastic{grid-template-columns:repeat(auto-fill,minmax(var(--plasma-private-min-width),auto));grid-auto-flow:row;}.b1iyfec1.grid:not(.vertical)[data-arrangement='start']{justify-items:start;}.b1iyfec1.grid:not(.vertical)[data-arrangement='center']{justify-items:center;}.b1iyfec1.grid:not(.vertical)[data-arrangement='end']{justify-items:end;}.b1iyfec1.grid:not(.vertical)[data-arrangement='spaceBetween']{-webkit-box-pack:justify;-webkit-justify-content:space-between;-ms-flex-pack:justify;justify-content:space-between;}.b1iyfec1.grid:not(.vertical)[data-arrangement='spaceAround']{-webkit-box-pack:space-around;-webkit-justify-content:space-around;-ms-flex-pack:space-around;justify-content:space-around;}.b1iyfec1.grid:not(.vertical)[data-alignment='start']{-webkit-align-items:start;-webkit-box-align:start;-ms-flex-align:start;align-items:start;}.b1iyfec1.grid:not(.vertical)[data-alignment='center']{-webkit-align-items:center;-webkit-box-align:center;-ms-flex-align:center;align-items:center;}.b1iyfec1.grid:not(.vertical)[data-alignment='end']{-webkit-align-items:end;-webkit-box-align:end;-ms-flex-align:end;align-items:end;}.b1iyfec1.grid.vertical{grid-template-columns:auto;grid-template-rows:repeat(var(--plasma-private-items),auto);grid-auto-flow:column;}.b1iyfec1.grid.vertical[data-arrangement='start']{-webkit-align-items:start;-webkit-box-align:start;-ms-flex-align:start;align-items:start;}.b1iyfec1.grid.vertical[data-arrangement='center']{-webkit-align-items:center;-webkit-box-align:center;-ms-flex-align:center;align-items:center;}.b1iyfec1.grid.vertical[data-arrangement='end']{-webkit-align-items:end;-webkit-box-align:end;-ms-flex-align:end;align-items:end;}.b1iyfec1.grid.vertical[data-arrangement='spaceBetween']{-webkit-align-content:space-between;-ms-flex-line-pack:space-between;align-content:space-between;-webkit-align-items:normal;-webkit-box-align:normal;-ms-flex-align:normal;align-items:normal;}.b1iyfec1.grid.vertical[data-arrangement='spaceAround']{-webkit-align-content:space-around;-ms-flex-line-pack:space-around;align-content:space-around;-webkit-align-items:normal;-webkit-box-align:normal;-ms-flex-align:normal;align-items:normal;}.b1iyfec1.grid.vertical[data-alignment='start']{justify-items:start;}.b1iyfec1.grid.vertical[data-alignment='center']{justify-items:center;}.b1iyfec1.grid.vertical[data-alignment='end']{justify-items:end;}.b1iyfec1:not(.b1iyfec1.grid):not(.b1iyfec1.hasChunks){-webkit-align-content:start;-ms-flex-line-pack:start;align-content:start;}.b1iyfec1:not(.b1iyfec1.grid):not(.b1iyfec1.hasChunks)[data-arrangement='start']{-webkit-box-pack:start;-webkit-justify-content:start;-ms-flex-pack:start;justify-content:start;}.b1iyfec1:not(.b1iyfec1.grid):not(.b1iyfec1.hasChunks)[data-arrangement='center']{-webkit-box-pack:center;-webkit-justify-content:center;-ms-flex-pack:center;justify-content:center;}.b1iyfec1:not(.b1iyfec1.grid):not(.b1iyfec1.hasChunks)[data-arrangement='end']{-webkit-box-pack:end;-webkit-justify-content:end;-ms-flex-pack:end;justify-content:end;}.b1iyfec1:not(.b1iyfec1.grid):not(.b1iyfec1.hasChunks)[data-arrangement='spaceBetween']{-webkit-box-pack:justify;-webkit-justify-content:space-between;-ms-flex-pack:justify;justify-content:space-between;}.b1iyfec1:not(.b1iyfec1.grid):not(.b1iyfec1.hasChunks)[data-arrangement='spaceAround']{-webkit-box-pack:space-around;-webkit-justify-content:space-around;-ms-flex-pack:space-around;justify-content:space-around;}.b1iyfec1:not(.b1iyfec1.grid):not(.b1iyfec1.hasChunks)[data-alignment='start']{-webkit-align-items:start;-webkit-box-align:start;-ms-flex-align:start;align-items:start;}.b1iyfec1:not(.b1iyfec1.grid):not(.b1iyfec1.hasChunks)[data-alignment='center']{-webkit-align-items:center;-webkit-box-align:center;-ms-flex-align:center;align-items:center;}.b1iyfec1:not(.b1iyfec1.grid):not(.b1iyfec1.hasChunks)[data-alignment='end']{-webkit-align-items:end;-webkit-box-align:end;-ms-flex-align:end;align-items:end;}
2
+ .lxs138i{display:-webkit-box;display:-webkit-flex;display:-ms-flexbox;display:flex;gap:var(--plasma-private-gap);}.lxs138i.vertical{-webkit-flex-direction:column;-ms-flex-direction:column;flex-direction:column;height:100%;}.lxs138i[data-arrangement='start']{-webkit-box-pack:start;-webkit-justify-content:start;-ms-flex-pack:start;justify-content:start;}.lxs138i[data-arrangement='center']{-webkit-box-pack:center;-webkit-justify-content:center;-ms-flex-pack:center;justify-content:center;}.lxs138i[data-arrangement='end']{-webkit-box-pack:end;-webkit-justify-content:end;-ms-flex-pack:end;justify-content:end;}.lxs138i[data-arrangement='spaceBetween']{-webkit-box-pack:justify;-webkit-justify-content:space-between;-ms-flex-pack:justify;justify-content:space-between;}.lxs138i[data-arrangement='spaceAround']{-webkit-box-pack:space-around;-webkit-justify-content:space-around;-ms-flex-pack:space-around;justify-content:space-around;}.lxs138i[data-alignment='start']{-webkit-align-items:start;-webkit-box-align:start;-ms-flex-align:start;align-items:start;}.lxs138i[data-alignment='center']{-webkit-align-items:center;-webkit-box-align:center;-ms-flex-align:center;align-items:center;}.lxs138i[data-alignment='end']{-webkit-align-items:end;-webkit-box-align:end;-ms-flex-align:end;align-items:end;}
package/es/index.css CHANGED
@@ -85,6 +85,9 @@
85
85
 
86
86
  .CellTextbox_styles_rgpies_cz0uqdu__c842929b{display:-webkit-box;display:-webkit-flex;display:-ms-flexbox;display:flex;-webkit-flex-direction:column;-ms-flex-direction:column;flex-direction:column;gap:var(--plasma-cell-textbox-gap);}
87
87
 
88
+ .Flow_styles_q8k0on_b1iyfec1__5db9d70e{display:-webkit-box;display:-webkit-flex;display:-ms-flexbox;display:flex;-webkit-flex-direction:row;-ms-flex-direction:row;flex-direction:row;-webkit-flex-wrap:wrap;-ms-flex-wrap:wrap;flex-wrap:wrap;gap:var(--plasma-private-gap);}.Flow_styles_q8k0on_b1iyfec1__5db9d70e.Flow_styles_q8k0on_hasChunks__5db9d70e{-webkit-flex-wrap:nowrap;-ms-flex-wrap:nowrap;flex-wrap:nowrap;-webkit-flex-direction:column;-ms-flex-direction:column;flex-direction:column;}.Flow_styles_q8k0on_b1iyfec1__5db9d70e.Flow_styles_q8k0on_hasChunks__5db9d70e.Flow_styles_q8k0on_vertical__5db9d70e{-webkit-flex-direction:row;-ms-flex-direction:row;flex-direction:row;}.Flow_styles_q8k0on_b1iyfec1__5db9d70e.Flow_styles_q8k0on_vertical__5db9d70e{-webkit-flex-direction:column;-ms-flex-direction:column;flex-direction:column;}.Flow_styles_q8k0on_b1iyfec1__5db9d70e.Flow_styles_q8k0on_grid__5db9d70e{display:grid;grid-template-columns:repeat(var(--plasma-private-items),auto);grid-auto-flow:row;}.Flow_styles_q8k0on_b1iyfec1__5db9d70e.Flow_styles_q8k0on_grid__5db9d70e.Flow_styles_q8k0on_elastic__5db9d70e{grid-template-columns:repeat(auto-fill,minmax(var(--plasma-private-min-width),auto));grid-auto-flow:row;}.Flow_styles_q8k0on_b1iyfec1__5db9d70e.Flow_styles_q8k0on_grid__5db9d70e:not(.Flow_styles_q8k0on_vertical__5db9d70e)[data-arrangement='start']{justify-items:start;}.Flow_styles_q8k0on_b1iyfec1__5db9d70e.Flow_styles_q8k0on_grid__5db9d70e:not(.Flow_styles_q8k0on_vertical__5db9d70e)[data-arrangement='center']{justify-items:center;}.Flow_styles_q8k0on_b1iyfec1__5db9d70e.Flow_styles_q8k0on_grid__5db9d70e:not(.Flow_styles_q8k0on_vertical__5db9d70e)[data-arrangement='end']{justify-items:end;}.Flow_styles_q8k0on_b1iyfec1__5db9d70e.Flow_styles_q8k0on_grid__5db9d70e:not(.Flow_styles_q8k0on_vertical__5db9d70e)[data-arrangement='spaceBetween']{-webkit-box-pack:justify;-webkit-justify-content:space-between;-ms-flex-pack:justify;justify-content:space-between;}.Flow_styles_q8k0on_b1iyfec1__5db9d70e.Flow_styles_q8k0on_grid__5db9d70e:not(.Flow_styles_q8k0on_vertical__5db9d70e)[data-arrangement='spaceAround']{-webkit-box-pack:space-around;-webkit-justify-content:space-around;-ms-flex-pack:space-around;justify-content:space-around;}.Flow_styles_q8k0on_b1iyfec1__5db9d70e.Flow_styles_q8k0on_grid__5db9d70e:not(.Flow_styles_q8k0on_vertical__5db9d70e)[data-alignment='start']{-webkit-align-items:start;-webkit-box-align:start;-ms-flex-align:start;align-items:start;}.Flow_styles_q8k0on_b1iyfec1__5db9d70e.Flow_styles_q8k0on_grid__5db9d70e:not(.Flow_styles_q8k0on_vertical__5db9d70e)[data-alignment='center']{-webkit-align-items:center;-webkit-box-align:center;-ms-flex-align:center;align-items:center;}.Flow_styles_q8k0on_b1iyfec1__5db9d70e.Flow_styles_q8k0on_grid__5db9d70e:not(.Flow_styles_q8k0on_vertical__5db9d70e)[data-alignment='end']{-webkit-align-items:end;-webkit-box-align:end;-ms-flex-align:end;align-items:end;}.Flow_styles_q8k0on_b1iyfec1__5db9d70e.Flow_styles_q8k0on_grid__5db9d70e.Flow_styles_q8k0on_vertical__5db9d70e{grid-template-columns:auto;grid-template-rows:repeat(var(--plasma-private-items),auto);grid-auto-flow:column;}.Flow_styles_q8k0on_b1iyfec1__5db9d70e.Flow_styles_q8k0on_grid__5db9d70e.Flow_styles_q8k0on_vertical__5db9d70e[data-arrangement='start']{-webkit-align-items:start;-webkit-box-align:start;-ms-flex-align:start;align-items:start;}.Flow_styles_q8k0on_b1iyfec1__5db9d70e.Flow_styles_q8k0on_grid__5db9d70e.Flow_styles_q8k0on_vertical__5db9d70e[data-arrangement='center']{-webkit-align-items:center;-webkit-box-align:center;-ms-flex-align:center;align-items:center;}.Flow_styles_q8k0on_b1iyfec1__5db9d70e.Flow_styles_q8k0on_grid__5db9d70e.Flow_styles_q8k0on_vertical__5db9d70e[data-arrangement='end']{-webkit-align-items:end;-webkit-box-align:end;-ms-flex-align:end;align-items:end;}.Flow_styles_q8k0on_b1iyfec1__5db9d70e.Flow_styles_q8k0on_grid__5db9d70e.Flow_styles_q8k0on_vertical__5db9d70e[data-arrangement='spaceBetween']{-webkit-align-content:space-between;-ms-flex-line-pack:space-between;align-content:space-between;-webkit-align-items:normal;-webkit-box-align:normal;-ms-flex-align:normal;align-items:normal;}.Flow_styles_q8k0on_b1iyfec1__5db9d70e.Flow_styles_q8k0on_grid__5db9d70e.Flow_styles_q8k0on_vertical__5db9d70e[data-arrangement='spaceAround']{-webkit-align-content:space-around;-ms-flex-line-pack:space-around;align-content:space-around;-webkit-align-items:normal;-webkit-box-align:normal;-ms-flex-align:normal;align-items:normal;}.Flow_styles_q8k0on_b1iyfec1__5db9d70e.Flow_styles_q8k0on_grid__5db9d70e.Flow_styles_q8k0on_vertical__5db9d70e[data-alignment='start']{justify-items:start;}.Flow_styles_q8k0on_b1iyfec1__5db9d70e.Flow_styles_q8k0on_grid__5db9d70e.Flow_styles_q8k0on_vertical__5db9d70e[data-alignment='center']{justify-items:center;}.Flow_styles_q8k0on_b1iyfec1__5db9d70e.Flow_styles_q8k0on_grid__5db9d70e.Flow_styles_q8k0on_vertical__5db9d70e[data-alignment='end']{justify-items:end;}.Flow_styles_q8k0on_b1iyfec1__5db9d70e:not(.Flow_styles_q8k0on_b1iyfec1__5db9d70e.Flow_styles_q8k0on_grid__5db9d70e):not(.Flow_styles_q8k0on_b1iyfec1__5db9d70e.Flow_styles_q8k0on_hasChunks__5db9d70e){-webkit-align-content:start;-ms-flex-line-pack:start;align-content:start;}.Flow_styles_q8k0on_b1iyfec1__5db9d70e:not(.Flow_styles_q8k0on_b1iyfec1__5db9d70e.Flow_styles_q8k0on_grid__5db9d70e):not(.Flow_styles_q8k0on_b1iyfec1__5db9d70e.Flow_styles_q8k0on_hasChunks__5db9d70e)[data-arrangement='start']{-webkit-box-pack:start;-webkit-justify-content:start;-ms-flex-pack:start;justify-content:start;}.Flow_styles_q8k0on_b1iyfec1__5db9d70e:not(.Flow_styles_q8k0on_b1iyfec1__5db9d70e.Flow_styles_q8k0on_grid__5db9d70e):not(.Flow_styles_q8k0on_b1iyfec1__5db9d70e.Flow_styles_q8k0on_hasChunks__5db9d70e)[data-arrangement='center']{-webkit-box-pack:center;-webkit-justify-content:center;-ms-flex-pack:center;justify-content:center;}.Flow_styles_q8k0on_b1iyfec1__5db9d70e:not(.Flow_styles_q8k0on_b1iyfec1__5db9d70e.Flow_styles_q8k0on_grid__5db9d70e):not(.Flow_styles_q8k0on_b1iyfec1__5db9d70e.Flow_styles_q8k0on_hasChunks__5db9d70e)[data-arrangement='end']{-webkit-box-pack:end;-webkit-justify-content:end;-ms-flex-pack:end;justify-content:end;}.Flow_styles_q8k0on_b1iyfec1__5db9d70e:not(.Flow_styles_q8k0on_b1iyfec1__5db9d70e.Flow_styles_q8k0on_grid__5db9d70e):not(.Flow_styles_q8k0on_b1iyfec1__5db9d70e.Flow_styles_q8k0on_hasChunks__5db9d70e)[data-arrangement='spaceBetween']{-webkit-box-pack:justify;-webkit-justify-content:space-between;-ms-flex-pack:justify;justify-content:space-between;}.Flow_styles_q8k0on_b1iyfec1__5db9d70e:not(.Flow_styles_q8k0on_b1iyfec1__5db9d70e.Flow_styles_q8k0on_grid__5db9d70e):not(.Flow_styles_q8k0on_b1iyfec1__5db9d70e.Flow_styles_q8k0on_hasChunks__5db9d70e)[data-arrangement='spaceAround']{-webkit-box-pack:space-around;-webkit-justify-content:space-around;-ms-flex-pack:space-around;justify-content:space-around;}.Flow_styles_q8k0on_b1iyfec1__5db9d70e:not(.Flow_styles_q8k0on_b1iyfec1__5db9d70e.Flow_styles_q8k0on_grid__5db9d70e):not(.Flow_styles_q8k0on_b1iyfec1__5db9d70e.Flow_styles_q8k0on_hasChunks__5db9d70e)[data-alignment='start']{-webkit-align-items:start;-webkit-box-align:start;-ms-flex-align:start;align-items:start;}.Flow_styles_q8k0on_b1iyfec1__5db9d70e:not(.Flow_styles_q8k0on_b1iyfec1__5db9d70e.Flow_styles_q8k0on_grid__5db9d70e):not(.Flow_styles_q8k0on_b1iyfec1__5db9d70e.Flow_styles_q8k0on_hasChunks__5db9d70e)[data-alignment='center']{-webkit-align-items:center;-webkit-box-align:center;-ms-flex-align:center;align-items:center;}.Flow_styles_q8k0on_b1iyfec1__5db9d70e:not(.Flow_styles_q8k0on_b1iyfec1__5db9d70e.Flow_styles_q8k0on_grid__5db9d70e):not(.Flow_styles_q8k0on_b1iyfec1__5db9d70e.Flow_styles_q8k0on_hasChunks__5db9d70e)[data-alignment='end']{-webkit-align-items:end;-webkit-box-align:end;-ms-flex-align:end;align-items:end;}
89
+ .Flow_styles_q8k0on_lxs138i__5db9d70e{display:-webkit-box;display:-webkit-flex;display:-ms-flexbox;display:flex;gap:var(--plasma-private-gap);}.Flow_styles_q8k0on_lxs138i__5db9d70e.Flow_styles_q8k0on_vertical__5db9d70e{-webkit-flex-direction:column;-ms-flex-direction:column;flex-direction:column;height:100%;}.Flow_styles_q8k0on_lxs138i__5db9d70e[data-arrangement='start']{-webkit-box-pack:start;-webkit-justify-content:start;-ms-flex-pack:start;justify-content:start;}.Flow_styles_q8k0on_lxs138i__5db9d70e[data-arrangement='center']{-webkit-box-pack:center;-webkit-justify-content:center;-ms-flex-pack:center;justify-content:center;}.Flow_styles_q8k0on_lxs138i__5db9d70e[data-arrangement='end']{-webkit-box-pack:end;-webkit-justify-content:end;-ms-flex-pack:end;justify-content:end;}.Flow_styles_q8k0on_lxs138i__5db9d70e[data-arrangement='spaceBetween']{-webkit-box-pack:justify;-webkit-justify-content:space-between;-ms-flex-pack:justify;justify-content:space-between;}.Flow_styles_q8k0on_lxs138i__5db9d70e[data-arrangement='spaceAround']{-webkit-box-pack:space-around;-webkit-justify-content:space-around;-ms-flex-pack:space-around;justify-content:space-around;}.Flow_styles_q8k0on_lxs138i__5db9d70e[data-alignment='start']{-webkit-align-items:start;-webkit-box-align:start;-ms-flex-align:start;align-items:start;}.Flow_styles_q8k0on_lxs138i__5db9d70e[data-alignment='center']{-webkit-align-items:center;-webkit-box-align:center;-ms-flex-align:center;align-items:center;}.Flow_styles_q8k0on_lxs138i__5db9d70e[data-alignment='end']{-webkit-align-items:end;-webkit-box-align:end;-ms-flex-align:end;align-items:end;}
90
+
88
91
  .base_1vy4dme_bcchm3r__d3e4eaba{font-family:var(--plasma-link-font-family);color:var(--plasma-link-color);}.base_1vy4dme_bcchm3r__d3e4eaba::before{border-bottom:var(--plasma-link-underline-border) solid currentColor;}.base_1vy4dme_bcchm3r__d3e4eaba:hover{color:var(--plasma-link-color-hover,var(--plasma-link-color));}.base_1vy4dme_bcchm3r__d3e4eaba:hover::before{opacity:1;}.base_1vy4dme_bcchm3r__d3e4eaba:active{color:var(--plasma-link-color-active,var(--plasma-link-color));}.base_1vy4dme_bcchm3r__d3e4eaba:active::before{opacity:1;}.base_1vy4dme_bcchm3r__d3e4eaba:visited{color:var(--plasma-link-color-visited,var(--plasma-link-color));}.base_1vy4dme_bcchm3r__d3e4eaba:visited::before{opacity:1;}.base_1vy4dme_bcchm3r__d3e4eaba:visited:hover{color:var(--plasma-link-color-visited-hover,var(--plasma-link-color));}.base_1vy4dme_bcchm3r__d3e4eaba:visited:hover::before{opacity:1;}.base_1vy4dme_bcchm3r__d3e4eaba:visited:active{color:var(--plasma-link-color-visited-active,var(--plasma-link-color));}.base_1vy4dme_bcchm3r__d3e4eaba:visited:active::before{opacity:1;}
89
92
 
90
93
  .base_1w750p8_b1j3f4f__d44baab5[disabled]{opacity:var(--plasma-link-disabled-opacity);cursor:not-allowed;}.base_1w750p8_b1j3f4f__d44baab5[disabled]:hover,.base_1w750p8_b1j3f4f__d44baab5[disabled]:active{color:var(--plasma-link-color);}.base_1w750p8_b1j3f4f__d44baab5[disabled]::before{opacity:1;}
package/es/index.js CHANGED
@@ -52,6 +52,7 @@ export { CellTextboxSubtitle } from './components/Cell/ui/CellTextboxSubtitle/Ce
52
52
  export { cellConfig, cellRoot } from './components/Cell/Cell.js';
53
53
  export { classes as cellClasses, tokens as cellTokens } from './components/Cell/Cell.tokens.js';
54
54
  export { CellTextbox } from './components/Cell/ui/CellTextbox/CellTextbox.js';
55
+ export { flowConfig, flowRoot } from './components/Flow/Flow.js';
55
56
  export { linkConfig, linkRoot } from './components/Link/Link.js';
56
57
  export { spinnerConfig, spinnerRoot } from './components/Spinner/Spinner.js';
57
58
  export { tokens as spinnerTokens } from './components/Spinner/Spinner.tokens.js';
package/es/index.js.map CHANGED
@@ -1 +1 @@
1
- {"version":3,"file":"index.js","sources":[],"sourcesContent":[],"names":[],"mappings":";;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;"}
1
+ {"version":3,"file":"index.js","sources":[],"sourcesContent":[],"names":[],"mappings":";;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;"}
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@salutejs/plasma-new-hope",
3
- "version": "0.237.1-dev.0",
3
+ "version": "0.238.0-dev.0",
4
4
  "description": "Salute Design System blueprint",
5
5
  "main": "./cjs/index.js",
6
6
  "module": "./es/index.js",
@@ -106,6 +106,7 @@
106
106
  "@storybook/react-vite": "7.6.17",
107
107
  "@storybook/theming": "^7.6.17",
108
108
  "@types/lodash": "^4.14.191",
109
+ "@types/lodash.chunk": "4.2.9",
109
110
  "@types/lodash.throttle": "4.1.6",
110
111
  "@types/node": "15.14.9",
111
112
  "@types/react": "18.0.28",
@@ -137,6 +138,7 @@
137
138
  "classnames": "2.5.1",
138
139
  "dayjs": "1.11.11",
139
140
  "focus-visible": "5.2.0",
141
+ "lodash.chunk": "4.2.0",
140
142
  "lodash.throttle": "4.1.1",
141
143
  "rc-tree": "5.11.0",
142
144
  "react-draggable": "4.4.3",
@@ -146,5 +148,5 @@
146
148
  "sideEffects": [
147
149
  "*.css"
148
150
  ],
149
- "gitHead": "7fc78258fe61b50aa631b3bc31dde2c029fbc909"
151
+ "gitHead": "776b4a8340b8a4ad8c82a83a7484fdac9941cf35"
150
152
  }
@@ -0,0 +1,92 @@
1
+ "use strict";
2
+
3
+ function _typeof(o) { "@babel/helpers - typeof"; return _typeof = "function" == typeof Symbol && "symbol" == typeof Symbol.iterator ? function (o) { return typeof o; } : function (o) { return o && "function" == typeof Symbol && o.constructor === Symbol && o !== Symbol.prototype ? "symbol" : typeof o; }, _typeof(o); }
4
+ Object.defineProperty(exports, "__esModule", {
5
+ value: true
6
+ });
7
+ exports.flowRoot = exports.flowConfig = void 0;
8
+ var _react = /*#__PURE__*/_interopRequireWildcard( /*#__PURE__*/require("react"));
9
+ var _classnames = /*#__PURE__*/_interopRequireDefault( /*#__PURE__*/require("classnames"));
10
+ var _lodash = /*#__PURE__*/_interopRequireDefault( /*#__PURE__*/require("lodash.chunk"));
11
+ var _Flow = /*#__PURE__*/require("./Flow.styles");
12
+ var _excluded = ["children", "className", "style", "orientation", "arrangement", "alignment", "mainAxisGap", "crossAxisGap", "minColWidth", "itemsPerLine"];
13
+ function _interopRequireDefault(obj) { return obj && obj.__esModule ? obj : { "default": obj }; }
14
+ function _getRequireWildcardCache(e) { if ("function" != typeof WeakMap) return null; var r = new WeakMap(), t = new WeakMap(); return (_getRequireWildcardCache = function _getRequireWildcardCache(e) { return e ? t : r; })(e); }
15
+ function _interopRequireWildcard(e, r) { if (!r && e && e.__esModule) return e; if (null === e || "object" != _typeof(e) && "function" != typeof e) return { "default": e }; var t = _getRequireWildcardCache(r); if (t && t.has(e)) return t.get(e); var n = { __proto__: null }, a = Object.defineProperty && Object.getOwnPropertyDescriptor; for (var u in e) if ("default" !== u && {}.hasOwnProperty.call(e, u)) { var i = a ? Object.getOwnPropertyDescriptor(e, u) : null; i && (i.get || i.set) ? Object.defineProperty(n, u, i) : n[u] = e[u]; } return n["default"] = e, t && t.set(e, n), n; }
16
+ function _extends() { _extends = Object.assign ? Object.assign.bind() : function (target) { for (var i = 1; i < arguments.length; i++) { var source = arguments[i]; for (var key in source) { if (Object.prototype.hasOwnProperty.call(source, key)) { target[key] = source[key]; } } } return target; }; return _extends.apply(this, arguments); }
17
+ function ownKeys(e, r) { var t = Object.keys(e); if (Object.getOwnPropertySymbols) { var o = Object.getOwnPropertySymbols(e); r && (o = o.filter(function (r) { return Object.getOwnPropertyDescriptor(e, r).enumerable; })), t.push.apply(t, o); } return t; }
18
+ function _objectSpread(e) { for (var r = 1; r < arguments.length; r++) { var t = null != arguments[r] ? arguments[r] : {}; r % 2 ? ownKeys(Object(t), !0).forEach(function (r) { _defineProperty(e, r, t[r]); }) : Object.getOwnPropertyDescriptors ? Object.defineProperties(e, Object.getOwnPropertyDescriptors(t)) : ownKeys(Object(t)).forEach(function (r) { Object.defineProperty(e, r, Object.getOwnPropertyDescriptor(t, r)); }); } return e; }
19
+ function _defineProperty(obj, key, value) { key = _toPropertyKey(key); if (key in obj) { Object.defineProperty(obj, key, { value: value, enumerable: true, configurable: true, writable: true }); } else { obj[key] = value; } return obj; }
20
+ function _toPropertyKey(t) { var i = _toPrimitive(t, "string"); return "symbol" == _typeof(i) ? i : i + ""; }
21
+ function _toPrimitive(t, r) { if ("object" != _typeof(t) || !t) return t; var e = t[Symbol.toPrimitive]; if (void 0 !== e) { var i = e.call(t, r || "default"); if ("object" != _typeof(i)) return i; throw new TypeError("@@toPrimitive must return a primitive value."); } return ("string" === r ? String : Number)(t); }
22
+ function _objectWithoutProperties(source, excluded) { if (source == null) return {}; var target = _objectWithoutPropertiesLoose(source, excluded); var key, i; if (Object.getOwnPropertySymbols) { var sourceSymbolKeys = Object.getOwnPropertySymbols(source); for (i = 0; i < sourceSymbolKeys.length; i++) { key = sourceSymbolKeys[i]; if (excluded.indexOf(key) >= 0) continue; if (!Object.prototype.propertyIsEnumerable.call(source, key)) continue; target[key] = source[key]; } } return target; }
23
+ function _objectWithoutPropertiesLoose(source, excluded) { if (source == null) return {}; var target = {}; var sourceKeys = Object.keys(source); var key, i; for (i = 0; i < sourceKeys.length; i++) { key = sourceKeys[i]; if (excluded.indexOf(key) >= 0) continue; target[key] = source[key]; } return target; }
24
+ var flowRoot = exports.flowRoot = function flowRoot(Root) {
25
+ return /*#__PURE__*/(0, _react.forwardRef)(function (_ref, ref) {
26
+ var children = _ref.children,
27
+ className = _ref.className,
28
+ style = _ref.style,
29
+ _ref$orientation = _ref.orientation,
30
+ orientation = _ref$orientation === void 0 ? 'horizontal' : _ref$orientation,
31
+ arrangement = _ref.arrangement,
32
+ alignment = _ref.alignment,
33
+ _ref$mainAxisGap = _ref.mainAxisGap,
34
+ mainAxisGap = _ref$mainAxisGap === void 0 ? '0' : _ref$mainAxisGap,
35
+ _ref$crossAxisGap = _ref.crossAxisGap,
36
+ crossAxisGap = _ref$crossAxisGap === void 0 ? '0' : _ref$crossAxisGap,
37
+ _ref$minColWidth = _ref.minColWidth,
38
+ minColWidth = _ref$minColWidth === void 0 ? 'auto' : _ref$minColWidth,
39
+ itemsPerLine = _ref.itemsPerLine,
40
+ rest = _objectWithoutProperties(_ref, _excluded);
41
+ var isVertical = orientation === 'vertical';
42
+ var hasMinWidth = Boolean(minColWidth && minColWidth !== 'auto');
43
+ var needGrid = Boolean(Number(itemsPerLine) > 0 || hasMinWidth);
44
+ var innerMainAxisGap = typeof mainAxisGap === 'number' || !Number.isNaN(+mainAxisGap) ? "".concat(mainAxisGap || 0, "px") : mainAxisGap;
45
+ var innerCrossAxisGap = typeof crossAxisGap === 'number' || !Number.isNaN(+crossAxisGap) ? "".concat(crossAxisGap || 0, "px") : crossAxisGap;
46
+ if (arrangement === 'spaceBetween' || arrangement === 'spaceAround') {
47
+ innerMainAxisGap = '0';
48
+ }
49
+ var hasChunks = Number(itemsPerLine) > 0;
50
+ var chunks = hasChunks ? (0, _lodash["default"])(_react["default"].Children.toArray(children), itemsPerLine) : [];
51
+ var gap = isVertical ? "".concat(innerMainAxisGap, " ").concat(innerCrossAxisGap) : "".concat(innerCrossAxisGap, " ").concat(innerMainAxisGap);
52
+ var wrapperGap = isVertical ? "0 ".concat(innerCrossAxisGap) : "".concat(innerCrossAxisGap, " 0");
53
+ var lineGap = isVertical ? "".concat(innerMainAxisGap, " 0") : "0 ".concat(innerMainAxisGap);
54
+ return /*#__PURE__*/_react["default"].createElement(Root, _extends({
55
+ ref: ref,
56
+ className: (0, _classnames["default"])(className, {
57
+ vertical: isVertical,
58
+ grid: hasMinWidth,
59
+ elastic: hasMinWidth,
60
+ hasChunks: hasChunks
61
+ }),
62
+ style: _objectSpread(_objectSpread({}, style), {}, {
63
+ '--plasma-private-gap': hasChunks ? wrapperGap : gap,
64
+ '--plasma-private-items': String(itemsPerLine),
65
+ '--plasma-private-min-width': String(minColWidth)
66
+ }),
67
+ "data-arrangement": arrangement,
68
+ "data-alignment": alignment
69
+ }, rest), hasChunks && chunks.map(function (chunkNode) {
70
+ return /*#__PURE__*/_react["default"].createElement(_Flow.Line, {
71
+ className: (0, _classnames["default"])({
72
+ vertical: isVertical,
73
+ grid: needGrid,
74
+ elastic: hasMinWidth
75
+ }),
76
+ style: {
77
+ '--plasma-private-gap': lineGap
78
+ },
79
+ "data-arrangement": arrangement,
80
+ "data-alignment": alignment
81
+ }, chunkNode);
82
+ }), !hasChunks && children);
83
+ });
84
+ };
85
+ var flowConfig = exports.flowConfig = {
86
+ name: 'Flow',
87
+ tag: 'div',
88
+ layout: flowRoot,
89
+ base: _Flow.base,
90
+ defaults: {},
91
+ variations: {}
92
+ };