baseui 11.1.1 → 11.2.1
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/accordion/index.d.ts +7 -7
- package/app-nav-bar/styled-components.js +43 -9
- package/app-nav-bar/styled-components.js.flow +41 -8
- package/avatar/index.d.ts +3 -3
- package/badge/index.d.ts +20 -25
- package/banner/index.d.ts +22 -27
- package/breadcrumbs/index.d.ts +2 -2
- package/button/index.d.ts +6 -6
- package/button-group/index.d.ts +1 -1
- package/card/index.d.ts +8 -8
- package/checkbox/index.d.ts +7 -7
- package/dnd-list/index.d.ts +6 -6
- package/drawer/index.d.ts +5 -5
- package/es/app-nav-bar/styled-components.js +41 -9
- package/es/file-uploader/file-uploader.js +8 -5
- package/es/map-marker/index.js +1 -1
- package/es/themes/shared/borders.js +1 -1
- package/esm/app-nav-bar/styled-components.js +42 -9
- package/esm/file-uploader/file-uploader.js +23 -8
- package/esm/map-marker/index.js +1 -1
- package/esm/themes/shared/borders.js +1 -1
- package/file-uploader/file-uploader.js +23 -8
- package/file-uploader/file-uploader.js.flow +18 -5
- package/file-uploader/index.d.ts +5 -5
- package/file-uploader/types.js.flow +3 -0
- package/form-control/index.d.ts +3 -3
- package/header-navigation/index.d.ts +3 -3
- package/helper/index.d.ts +2 -2
- package/icon/index.d.ts +1 -1
- package/input/index.d.ts +6 -6
- package/layout-grid/index.d.ts +2 -2
- package/link/index.d.ts +1 -1
- package/list/index.d.ts +14 -11
- package/map-marker/index.js +6 -0
- package/map-marker/index.js.flow +1 -0
- package/menu/index.d.ts +10 -10
- package/modal/index.d.ts +7 -7
- package/package.json +4 -7
- package/pagination/index.d.ts +3 -3
- package/payment-card/index.d.ts +1 -1
- package/phone-input/index.d.ts +9 -9
- package/popover/index.d.ts +4 -4
- package/progress-bar/index.d.ts +6 -6
- package/progress-steps/index.d.ts +11 -11
- package/radio/index.d.ts +7 -7
- package/rating/index.d.ts +3 -3
- package/select/index.d.ts +16 -16
- package/side-navigation/index.d.ts +5 -5
- package/slider/index.d.ts +8 -8
- package/spinner/index.d.ts +1 -1
- package/styles/index.d.ts +8 -12
- package/table/index.d.ts +12 -12
- package/table-grid/index.d.ts +3 -3
- package/table-semantic/index.d.ts +14 -14
- package/tabs/index.d.ts +4 -4
- package/tabs-motion/index.d.ts +7 -7
- package/tag/index.d.ts +3 -3
- package/textarea/index.d.ts +2 -2
- package/themes/shared/borders.js +1 -1
- package/themes/shared/borders.js.flow +1 -1
- package/toast/index.d.ts +3 -3
- package/tooltip/index.d.ts +3 -3
- package/tree-view/index.d.ts +4 -4
package/accordion/index.d.ts
CHANGED
|
@@ -123,10 +123,10 @@ export class StatefulPanelContainer extends React.Component<
|
|
|
123
123
|
): void;
|
|
124
124
|
}
|
|
125
125
|
|
|
126
|
-
export declare const StyledRoot: StyletronComponent<any>;
|
|
127
|
-
export declare const StyledPanelContainer: StyletronComponent<any>;
|
|
128
|
-
export declare const StyledHeader: StyletronComponent<any>;
|
|
129
|
-
export declare const StyledContent: StyletronComponent<any>;
|
|
130
|
-
export declare const StyledContentAnimationContainer: StyletronComponent<any>;
|
|
131
|
-
export declare const StyledToggleIcon: StyletronComponent<any>;
|
|
132
|
-
export declare const StyledToggleIconGroup: StyletronComponent<any>;
|
|
126
|
+
export declare const StyledRoot: StyletronComponent<any, any>;
|
|
127
|
+
export declare const StyledPanelContainer: StyletronComponent<any, any>;
|
|
128
|
+
export declare const StyledHeader: StyletronComponent<any, any>;
|
|
129
|
+
export declare const StyledContent: StyletronComponent<any, any>;
|
|
130
|
+
export declare const StyledContentAnimationContainer: StyletronComponent<any, any>;
|
|
131
|
+
export declare const StyledToggleIcon: StyletronComponent<any, any>;
|
|
132
|
+
export declare const StyledToggleIconGroup: StyletronComponent<any, any>;
|
|
@@ -7,6 +7,8 @@ exports.StyledDesktopMenu = exports.StyledDesktopMenuContainer = exports.StyledU
|
|
|
7
7
|
|
|
8
8
|
var _index = require("../styles/index.js");
|
|
9
9
|
|
|
10
|
+
var _responsiveHelpers = require("../helpers/responsive-helpers.js");
|
|
11
|
+
|
|
10
12
|
var _index2 = require("../menu/index.js");
|
|
11
13
|
|
|
12
14
|
var _constants = require("./constants.js");
|
|
@@ -50,10 +52,46 @@ var StyledButton = (0, _index.styled)('button', function (_ref) {
|
|
|
50
52
|
StyledButton.displayName = "StyledButton";
|
|
51
53
|
var StyledRoot = (0, _index.styled)('div', function (props) {
|
|
52
54
|
var $theme = props.$theme;
|
|
53
|
-
|
|
55
|
+
var mediaQueries = (0, _responsiveHelpers.getMediaQueries)($theme.breakpoints);
|
|
56
|
+
var breakpoints = Object.values($theme.breakpoints).sort();
|
|
57
|
+
var margins = [];
|
|
58
|
+
|
|
59
|
+
if (Array.isArray($theme.grid.margins)) {
|
|
60
|
+
for (var i = 0; i < breakpoints.length; i++) {
|
|
61
|
+
var margin = $theme.grid.margins[i];
|
|
62
|
+
|
|
63
|
+
if (margin == null) {
|
|
64
|
+
margins.push($theme.grid.margins[$theme.grid.margins.length - 1]);
|
|
65
|
+
} else {
|
|
66
|
+
margins.push(margin);
|
|
67
|
+
}
|
|
68
|
+
}
|
|
69
|
+
} else {
|
|
70
|
+
for (var _i = 0; _i < breakpoints.length; _i++) {
|
|
71
|
+
margins.push($theme.grid.margins);
|
|
72
|
+
}
|
|
73
|
+
}
|
|
74
|
+
|
|
75
|
+
var style = _objectSpread(_objectSpread({}, $theme.typography.font300), {}, {
|
|
54
76
|
boxSizing: 'border-box',
|
|
55
|
-
backgroundColor: $theme.colors.backgroundPrimary
|
|
77
|
+
backgroundColor: $theme.colors.backgroundPrimary,
|
|
78
|
+
borderBottomWidth: '1px',
|
|
79
|
+
borderBottomStyle: 'solid',
|
|
80
|
+
borderBottomColor: "".concat($theme.colors.borderOpaque),
|
|
81
|
+
paddingInlineStart: margins[0] + 'px',
|
|
82
|
+
paddingInlineEnd: margins[0] + 'px'
|
|
56
83
|
});
|
|
84
|
+
|
|
85
|
+
for (var _i2 = 1; _i2 < mediaQueries.length; _i2++) {
|
|
86
|
+
var _margin = Array.isArray($theme.grid.margins) ? $theme.grid.margins[_i2] : $theme.grid.margins;
|
|
87
|
+
|
|
88
|
+
style[mediaQueries[_i2]] = {
|
|
89
|
+
paddingInlineStart: _margin + 'px',
|
|
90
|
+
paddingInlineEnd: _margin + 'px'
|
|
91
|
+
};
|
|
92
|
+
}
|
|
93
|
+
|
|
94
|
+
return style;
|
|
57
95
|
});
|
|
58
96
|
exports.StyledRoot = StyledRoot;
|
|
59
97
|
StyledRoot.displayName = "StyledRoot";
|
|
@@ -167,7 +205,7 @@ var StyledSecondaryMenuContainer = (0, _index.styled)('div', function (_ref6) {
|
|
|
167
205
|
flexWrap: 'nowrap',
|
|
168
206
|
justifyContent: 'flex-start',
|
|
169
207
|
margin: 'auto',
|
|
170
|
-
maxWidth: "".concat($theme.
|
|
208
|
+
maxWidth: "".concat($theme.grid.maxWidth, "px"),
|
|
171
209
|
alignItems: 'stretch',
|
|
172
210
|
overflow: 'auto'
|
|
173
211
|
};
|
|
@@ -225,11 +263,7 @@ exports.StyledUserProfileInfoContainer = StyledUserProfileInfoContainer;
|
|
|
225
263
|
StyledUserProfileInfoContainer.displayName = "StyledUserProfileInfoContainer";
|
|
226
264
|
var StyledDesktopMenuContainer = (0, _index.styled)('div', function (_ref11) {
|
|
227
265
|
var $theme = _ref11.$theme;
|
|
228
|
-
return {
|
|
229
|
-
borderBottomWidth: '1px',
|
|
230
|
-
borderBottomStyle: 'solid',
|
|
231
|
-
borderBottomColor: "".concat($theme.colors.borderOpaque)
|
|
232
|
-
};
|
|
266
|
+
return {};
|
|
233
267
|
});
|
|
234
268
|
exports.StyledDesktopMenuContainer = StyledDesktopMenuContainer;
|
|
235
269
|
StyledDesktopMenuContainer.displayName = "StyledDesktopMenuContainer";
|
|
@@ -240,7 +274,7 @@ var StyledDesktopMenu = (0, _index.styled)('div', function (_ref12) {
|
|
|
240
274
|
display: 'flex',
|
|
241
275
|
justifyContent: 'space-between',
|
|
242
276
|
margin: 'auto',
|
|
243
|
-
maxWidth: "".concat($theme.
|
|
277
|
+
maxWidth: "".concat($theme.grid.maxWidth, "px"),
|
|
244
278
|
paddingBlockStart: '18px',
|
|
245
279
|
paddingBlockEnd: '18px'
|
|
246
280
|
};
|
|
@@ -7,6 +7,7 @@ LICENSE file in the root directory of this source tree.
|
|
|
7
7
|
// @flow
|
|
8
8
|
|
|
9
9
|
import { styled, withStyle } from '../styles/index.js';
|
|
10
|
+
import { getMediaQueries } from '../helpers/responsive-helpers.js';
|
|
10
11
|
import { StyledListItem } from '../menu/index.js';
|
|
11
12
|
import { KIND } from './constants.js';
|
|
12
13
|
|
|
@@ -42,11 +43,47 @@ const StyledButton = styled<{ $isFocusVisible: boolean }>(
|
|
|
42
43
|
|
|
43
44
|
export const StyledRoot = styled<{}>('div', (props) => {
|
|
44
45
|
const { $theme } = props;
|
|
45
|
-
|
|
46
|
+
const mediaQueries = getMediaQueries($theme.breakpoints);
|
|
47
|
+
const breakpoints = Object.values($theme.breakpoints).sort();
|
|
48
|
+
const margins = [];
|
|
49
|
+
if (Array.isArray($theme.grid.margins)) {
|
|
50
|
+
for (let i = 0; i < breakpoints.length; i++) {
|
|
51
|
+
const margin = $theme.grid.margins[i];
|
|
52
|
+
if (margin == null) {
|
|
53
|
+
margins.push($theme.grid.margins[$theme.grid.margins.length - 1]);
|
|
54
|
+
} else {
|
|
55
|
+
margins.push(margin);
|
|
56
|
+
}
|
|
57
|
+
}
|
|
58
|
+
} else {
|
|
59
|
+
for (let i = 0; i < breakpoints.length; i++) {
|
|
60
|
+
margins.push($theme.grid.margins);
|
|
61
|
+
}
|
|
62
|
+
}
|
|
63
|
+
|
|
64
|
+
const style = {
|
|
46
65
|
...$theme.typography.font300,
|
|
47
66
|
boxSizing: 'border-box',
|
|
48
67
|
backgroundColor: $theme.colors.backgroundPrimary,
|
|
68
|
+
borderBottomWidth: '1px',
|
|
69
|
+
borderBottomStyle: 'solid',
|
|
70
|
+
borderBottomColor: `${$theme.colors.borderOpaque}`,
|
|
71
|
+
paddingInlineStart: margins[0] + 'px',
|
|
72
|
+
paddingInlineEnd: margins[0] + 'px',
|
|
49
73
|
};
|
|
74
|
+
|
|
75
|
+
for (let i = 1; i < mediaQueries.length; i++) {
|
|
76
|
+
const margin = Array.isArray($theme.grid.margins)
|
|
77
|
+
? $theme.grid.margins[i]
|
|
78
|
+
: $theme.grid.margins;
|
|
79
|
+
|
|
80
|
+
style[mediaQueries[i]] = {
|
|
81
|
+
paddingInlineStart: margin + 'px',
|
|
82
|
+
paddingInlineEnd: margin + 'px',
|
|
83
|
+
};
|
|
84
|
+
}
|
|
85
|
+
|
|
86
|
+
return style;
|
|
50
87
|
});
|
|
51
88
|
|
|
52
89
|
export const StyledSubnavContainer = styled('div', {});
|
|
@@ -151,7 +188,7 @@ export const StyledSecondaryMenuContainer = styled<{}>('div', ({ $theme }) => {
|
|
|
151
188
|
flexWrap: 'nowrap',
|
|
152
189
|
justifyContent: 'flex-start',
|
|
153
190
|
margin: 'auto',
|
|
154
|
-
maxWidth: `${$theme.
|
|
191
|
+
maxWidth: `${$theme.grid.maxWidth}px`,
|
|
155
192
|
alignItems: 'stretch',
|
|
156
193
|
overflow: 'auto',
|
|
157
194
|
};
|
|
@@ -197,11 +234,7 @@ export const StyledUserProfileInfoContainer = styled<{}>('div', ({ $theme }) =>
|
|
|
197
234
|
});
|
|
198
235
|
|
|
199
236
|
export const StyledDesktopMenuContainer = styled<{}>('div', ({ $theme }) => {
|
|
200
|
-
return {
|
|
201
|
-
borderBottomWidth: '1px',
|
|
202
|
-
borderBottomStyle: 'solid',
|
|
203
|
-
borderBottomColor: `${$theme.colors.borderOpaque}`,
|
|
204
|
-
};
|
|
237
|
+
return {};
|
|
205
238
|
});
|
|
206
239
|
|
|
207
240
|
export const StyledDesktopMenu = styled<{}>('div', ({ $theme }) => {
|
|
@@ -210,7 +243,7 @@ export const StyledDesktopMenu = styled<{}>('div', ({ $theme }) => {
|
|
|
210
243
|
display: 'flex',
|
|
211
244
|
justifyContent: 'space-between',
|
|
212
245
|
margin: 'auto',
|
|
213
|
-
maxWidth: `${$theme.
|
|
246
|
+
maxWidth: `${$theme.grid.maxWidth}px`,
|
|
214
247
|
paddingBlockStart: '18px',
|
|
215
248
|
paddingBlockEnd: '18px',
|
|
216
249
|
};
|
package/avatar/index.d.ts
CHANGED
|
@@ -22,6 +22,6 @@ export interface AvatarProps {
|
|
|
22
22
|
|
|
23
23
|
export declare const Avatar: React.FC<AvatarProps>;
|
|
24
24
|
|
|
25
|
-
export declare const StyledAvatar: StyletronComponent<any>;
|
|
26
|
-
export declare const StyledInitials: StyletronComponent<any>;
|
|
27
|
-
export declare const StyledRoot: StyletronComponent<any>;
|
|
25
|
+
export declare const StyledAvatar: StyletronComponent<any, any>;
|
|
26
|
+
export declare const StyledInitials: StyletronComponent<any, any>;
|
|
27
|
+
export declare const StyledRoot: StyletronComponent<any, any>;
|
package/badge/index.d.ts
CHANGED
|
@@ -2,25 +2,25 @@ import * as React from 'react';
|
|
|
2
2
|
import { StyletronComponent } from 'styletron-react';
|
|
3
3
|
import { Override } from '../overrides';
|
|
4
4
|
|
|
5
|
-
export
|
|
5
|
+
export declare const HIERARCHY: {
|
|
6
6
|
primary: 'primary';
|
|
7
7
|
secondary: 'secondary';
|
|
8
|
-
}
|
|
8
|
+
};
|
|
9
9
|
|
|
10
|
-
export
|
|
10
|
+
export declare const SHAPE: {
|
|
11
11
|
pill: 'pill';
|
|
12
12
|
rectangle: 'rectangle';
|
|
13
|
-
}
|
|
13
|
+
};
|
|
14
14
|
|
|
15
|
-
export
|
|
15
|
+
export declare const COLOR: {
|
|
16
16
|
accent: 'accent';
|
|
17
17
|
primary: 'primary';
|
|
18
18
|
positive: 'positive';
|
|
19
19
|
negative: 'negative';
|
|
20
20
|
warning: 'warning';
|
|
21
|
-
}
|
|
21
|
+
};
|
|
22
22
|
|
|
23
|
-
export
|
|
23
|
+
export declare const PLACEMENT: {
|
|
24
24
|
topLeft: 'topLeft';
|
|
25
25
|
topRight: 'topRight';
|
|
26
26
|
bottomRight: 'bottomRight';
|
|
@@ -35,12 +35,12 @@ export interface PLACEMENT {
|
|
|
35
35
|
rightTopEdge: 'rightTopEdge';
|
|
36
36
|
rightBottomEdge: 'rightBottomEdge';
|
|
37
37
|
leftBottomEdge: 'leftBottomEdge';
|
|
38
|
-
}
|
|
38
|
+
};
|
|
39
39
|
|
|
40
|
-
export type HierarchyT = HIERARCHY[keyof HIERARCHY];
|
|
41
|
-
export type ShapeT = SHAPE[keyof SHAPE];
|
|
42
|
-
export type ColorT = COLOR[keyof COLOR];
|
|
43
|
-
export type PlacementT = PLACEMENT[keyof PLACEMENT];
|
|
40
|
+
export type HierarchyT = typeof HIERARCHY[keyof typeof HIERARCHY];
|
|
41
|
+
export type ShapeT = typeof SHAPE[keyof typeof SHAPE];
|
|
42
|
+
export type ColorT = typeof COLOR[keyof typeof COLOR];
|
|
43
|
+
export type PlacementT = typeof PLACEMENT[keyof typeof PLACEMENT];
|
|
44
44
|
|
|
45
45
|
export type BadgeOverridesT = {
|
|
46
46
|
Root?: Override<any>;
|
|
@@ -81,17 +81,12 @@ export type HintDotPropsT = {
|
|
|
81
81
|
children?: React.ReactNode;
|
|
82
82
|
};
|
|
83
83
|
|
|
84
|
-
export const StyledRoot: StyletronComponent<any>;
|
|
85
|
-
export const StyledPositioner: StyletronComponent<any>;
|
|
86
|
-
export const StyledBadge: StyletronComponent<any>;
|
|
87
|
-
export const StyledNotificationCircle: StyletronComponent<any>;
|
|
88
|
-
export const StyledHintDot: StyletronComponent<any>;
|
|
89
|
-
|
|
90
|
-
export const Badge: React.FC<BadgePropsT>;
|
|
91
|
-
export const NotificationCircle: React.FC<NotificationCirclePropsT>;
|
|
92
|
-
export const HintDot: React.FC<HintDotPropsT>;
|
|
84
|
+
export declare const StyledRoot: StyletronComponent<any, any>;
|
|
85
|
+
export declare const StyledPositioner: StyletronComponent<any, any>;
|
|
86
|
+
export declare const StyledBadge: StyletronComponent<any, any>;
|
|
87
|
+
export declare const StyledNotificationCircle: StyletronComponent<any, any>;
|
|
88
|
+
export declare const StyledHintDot: StyletronComponent<any, any>;
|
|
93
89
|
|
|
94
|
-
export const
|
|
95
|
-
export const
|
|
96
|
-
export const
|
|
97
|
-
export const PLACEMENT: PLACEMENT;
|
|
90
|
+
export declare const Badge: React.FC<BadgePropsT>;
|
|
91
|
+
export declare const NotificationCircle: React.FC<NotificationCirclePropsT>;
|
|
92
|
+
export declare const HintDot: React.FC<HintDotPropsT>;
|
package/banner/index.d.ts
CHANGED
|
@@ -2,46 +2,46 @@ import * as React from 'react';
|
|
|
2
2
|
import { StyletronComponent } from 'styletron-react';
|
|
3
3
|
import { Override } from '../overrides';
|
|
4
4
|
|
|
5
|
-
export
|
|
5
|
+
export declare const ACTION_POSITION: {
|
|
6
6
|
below: 'below';
|
|
7
7
|
trailing: 'trailing';
|
|
8
|
-
}
|
|
8
|
+
};
|
|
9
9
|
|
|
10
|
-
export
|
|
10
|
+
export declare const ARTWORK_TYPE: {
|
|
11
11
|
badge: 'badge';
|
|
12
12
|
icon: 'icon';
|
|
13
|
-
}
|
|
13
|
+
};
|
|
14
14
|
|
|
15
|
-
export
|
|
15
|
+
export declare const HIERARCHY: {
|
|
16
16
|
high: 'high';
|
|
17
17
|
low: 'low';
|
|
18
|
-
}
|
|
18
|
+
};
|
|
19
19
|
|
|
20
|
-
export
|
|
20
|
+
export declare const KIND: {
|
|
21
21
|
info: 'info';
|
|
22
22
|
negative: 'negative';
|
|
23
23
|
positive: 'positive';
|
|
24
24
|
warning: 'warning';
|
|
25
|
-
}
|
|
25
|
+
};
|
|
26
26
|
|
|
27
27
|
export interface ActionContentT {
|
|
28
28
|
label: string;
|
|
29
29
|
icon?: (iconProps: { size: string }) => React.ReactNode;
|
|
30
30
|
onClick: (event: React.MouseEvent<HTMLButtonElement>) => any;
|
|
31
|
-
position?: ACTION_POSITION[keyof ACTION_POSITION];
|
|
31
|
+
position?: typeof ACTION_POSITION[keyof typeof ACTION_POSITION];
|
|
32
32
|
}
|
|
33
33
|
|
|
34
34
|
export interface ArtworkContentT {
|
|
35
35
|
icon: (iconProps: { size: string }) => React.ReactNode;
|
|
36
|
-
type?: ARTWORK_TYPE[keyof ARTWORK_TYPE];
|
|
36
|
+
type?: typeof ARTWORK_TYPE[keyof typeof ARTWORK_TYPE];
|
|
37
37
|
}
|
|
38
38
|
|
|
39
39
|
export interface PropsT {
|
|
40
40
|
action?: ActionContentT;
|
|
41
41
|
artwork?: ArtworkContentT;
|
|
42
42
|
children: React.ReactNode;
|
|
43
|
-
hierarchy?: HIERARCHY[keyof HIERARCHY];
|
|
44
|
-
kind?: KIND[keyof KIND];
|
|
43
|
+
hierarchy?: typeof HIERARCHY[keyof typeof HIERARCHY];
|
|
44
|
+
kind?: typeof KIND[keyof typeof KIND];
|
|
45
45
|
overrides?: {
|
|
46
46
|
BelowContent?: Override<any>;
|
|
47
47
|
LeadingContent?: Override<any>;
|
|
@@ -57,19 +57,14 @@ export interface PropsT {
|
|
|
57
57
|
title?: React.ReactNode;
|
|
58
58
|
}
|
|
59
59
|
|
|
60
|
-
export const StyledBelowContent: StyletronComponent<any>;
|
|
61
|
-
export const StyledLeadingContent: StyletronComponent<any>;
|
|
62
|
-
export const StyledMessage: StyletronComponent<any>;
|
|
63
|
-
export const StyledMessageContent: StyletronComponent<any>;
|
|
64
|
-
export const StyledRoot: StyletronComponent<any>;
|
|
65
|
-
export const StyledTitle: StyletronComponent<any>;
|
|
66
|
-
export const StyledTrailingContent: StyletronComponent<any>;
|
|
67
|
-
export const StyledTrailingButtonContainer: StyletronComponent<any>;
|
|
68
|
-
export const StyledTrailingIconButton: StyletronComponent<any>;
|
|
69
|
-
|
|
70
|
-
export const ACTION_POSITION: ACTION_POSITION;
|
|
71
|
-
export const ARTWORK_TYPE: ARTWORK_TYPE;
|
|
72
|
-
export const HIERARCHY: HIERARCHY;
|
|
73
|
-
export const KIND: KIND;
|
|
60
|
+
export declare const StyledBelowContent: StyletronComponent<any, any>;
|
|
61
|
+
export declare const StyledLeadingContent: StyletronComponent<any, any>;
|
|
62
|
+
export declare const StyledMessage: StyletronComponent<any, any>;
|
|
63
|
+
export declare const StyledMessageContent: StyletronComponent<any, any>;
|
|
64
|
+
export declare const StyledRoot: StyletronComponent<any, any>;
|
|
65
|
+
export declare const StyledTitle: StyletronComponent<any, any>;
|
|
66
|
+
export declare const StyledTrailingContent: StyletronComponent<any, any>;
|
|
67
|
+
export declare const StyledTrailingButtonContainer: StyletronComponent<any, any>;
|
|
68
|
+
export declare const StyledTrailingIconButton: StyletronComponent<any, any>;
|
|
74
69
|
|
|
75
|
-
export const Banner: React.FC<PropsT>;
|
|
70
|
+
export declare const Banner: React.FC<PropsT>;
|
package/breadcrumbs/index.d.ts
CHANGED
|
@@ -20,5 +20,5 @@ export interface BreadcrumbsProps {
|
|
|
20
20
|
|
|
21
21
|
export declare const Breadcrumbs: React.FC<BreadcrumbsProps>;
|
|
22
22
|
|
|
23
|
-
export declare const StyledRoot: StyletronComponent<any>;
|
|
24
|
-
export declare const StyledSeparator: StyletronComponent<any>;
|
|
23
|
+
export declare const StyledRoot: StyletronComponent<any, any>;
|
|
24
|
+
export declare const StyledSeparator: StyletronComponent<any, any>;
|
package/button/index.d.ts
CHANGED
|
@@ -56,10 +56,10 @@ export interface ButtonProps {
|
|
|
56
56
|
type?: 'submit' | 'reset' | 'button';
|
|
57
57
|
}
|
|
58
58
|
|
|
59
|
-
export declare const StyledBaseButton: StyletronComponent<any>;
|
|
60
|
-
export declare const StyledStartEnhancer: StyletronComponent<any>;
|
|
61
|
-
export declare const StyledEndEnhancer: StyletronComponent<any>;
|
|
62
|
-
export declare const StyledLoadingSpinner: StyletronComponent<any>;
|
|
63
|
-
export declare const StyledLoadingSpinnerContainer: StyletronComponent<any>;
|
|
59
|
+
export declare const StyledBaseButton: StyletronComponent<any, any>;
|
|
60
|
+
export declare const StyledStartEnhancer: StyletronComponent<any, any>;
|
|
61
|
+
export declare const StyledEndEnhancer: StyletronComponent<any, any>;
|
|
62
|
+
export declare const StyledLoadingSpinner: StyletronComponent<any, any>;
|
|
63
|
+
export declare const StyledLoadingSpinnerContainer: StyletronComponent<any, any>;
|
|
64
64
|
|
|
65
|
-
export declare const Button: StyletronComponent<ButtonProps>;
|
|
65
|
+
export declare const Button: StyletronComponent<any, ButtonProps>;
|
package/button-group/index.d.ts
CHANGED
|
@@ -14,7 +14,7 @@ export declare const STATE_CHANGE_TYPE: {
|
|
|
14
14
|
change: 'change';
|
|
15
15
|
};
|
|
16
16
|
|
|
17
|
-
export declare const StyledRoot: StyletronComponent<any>;
|
|
17
|
+
export declare const StyledRoot: StyletronComponent<any, any>;
|
|
18
18
|
|
|
19
19
|
export interface ButtonGroupOverrides {
|
|
20
20
|
Root?: Override<any>;
|
package/card/index.d.ts
CHANGED
|
@@ -25,11 +25,11 @@ export interface CardProps {
|
|
|
25
25
|
export declare const Card: React.FC<CardProps>;
|
|
26
26
|
export type hasThumbnail = (props: { readonly thumbnail?: string }) => boolean;
|
|
27
27
|
|
|
28
|
-
export declare const StyledAction: StyletronComponent<any>;
|
|
29
|
-
export declare const StyledBody: StyletronComponent<any>;
|
|
30
|
-
export declare const StyledContents: StyletronComponent<any>;
|
|
31
|
-
export declare const StyledHeaderImage: StyletronComponent<any>;
|
|
32
|
-
export declare const StyledThumbnail: StyletronComponent<any>;
|
|
33
|
-
export declare const StyledTitle: StyletronComponent<any>;
|
|
34
|
-
export declare const StyledRoot: StyletronComponent<any>;
|
|
35
|
-
export declare const StyledWrapper: StyletronComponent<any>;
|
|
28
|
+
export declare const StyledAction: StyletronComponent<any, any>;
|
|
29
|
+
export declare const StyledBody: StyletronComponent<any, any>;
|
|
30
|
+
export declare const StyledContents: StyletronComponent<any, any>;
|
|
31
|
+
export declare const StyledHeaderImage: StyletronComponent<any, any>;
|
|
32
|
+
export declare const StyledThumbnail: StyletronComponent<any, any>;
|
|
33
|
+
export declare const StyledTitle: StyletronComponent<any, any>;
|
|
34
|
+
export declare const StyledRoot: StyletronComponent<any, any>;
|
|
35
|
+
export declare const StyledWrapper: StyletronComponent<any, any>;
|
package/checkbox/index.d.ts
CHANGED
|
@@ -23,13 +23,13 @@ type initialState = {
|
|
|
23
23
|
isIndeterminate?: boolean;
|
|
24
24
|
};
|
|
25
25
|
|
|
26
|
-
export declare const StyledRoot: StyletronComponent<any>;
|
|
27
|
-
export declare const StyledCheckmark: StyletronComponent<any>;
|
|
28
|
-
export declare const StyledLabel: StyletronComponent<any>;
|
|
29
|
-
export declare const StyledInput: StyletronComponent<any>;
|
|
30
|
-
export declare const StyledToggle: StyletronComponent<any>;
|
|
31
|
-
export declare const StyledToggleInner: StyletronComponent<any>;
|
|
32
|
-
export declare const StyledToggleTrack: StyletronComponent<any>;
|
|
26
|
+
export declare const StyledRoot: StyletronComponent<any, any>;
|
|
27
|
+
export declare const StyledCheckmark: StyletronComponent<any, any>;
|
|
28
|
+
export declare const StyledLabel: StyletronComponent<any, any>;
|
|
29
|
+
export declare const StyledInput: StyletronComponent<any, any>;
|
|
30
|
+
export declare const StyledToggle: StyletronComponent<any, any>;
|
|
31
|
+
export declare const StyledToggleInner: StyletronComponent<any, any>;
|
|
32
|
+
export declare const StyledToggleTrack: StyletronComponent<any, any>;
|
|
33
33
|
|
|
34
34
|
export type StateReducer = (
|
|
35
35
|
stateType: string,
|
package/dnd-list/index.d.ts
CHANGED
|
@@ -69,12 +69,12 @@ export interface ListProps {
|
|
|
69
69
|
|
|
70
70
|
export class List extends React.Component<ListProps> {}
|
|
71
71
|
|
|
72
|
-
export declare const StyledRoot: StyletronComponent<any>;
|
|
73
|
-
export declare const StyledList: StyletronComponent<any>;
|
|
74
|
-
export declare const StyledItem: StyletronComponent<any>;
|
|
75
|
-
export declare const StyledDragHandle: StyletronComponent<any>;
|
|
76
|
-
export declare const StyledCloseHandle: StyletronComponent<any>;
|
|
77
|
-
export declare const StyledLabel: StyletronComponent<any>;
|
|
72
|
+
export declare const StyledRoot: StyletronComponent<any, any>;
|
|
73
|
+
export declare const StyledList: StyletronComponent<any, any>;
|
|
74
|
+
export declare const StyledItem: StyletronComponent<any, any>;
|
|
75
|
+
export declare const StyledDragHandle: StyletronComponent<any, any>;
|
|
76
|
+
export declare const StyledCloseHandle: StyletronComponent<any, any>;
|
|
77
|
+
export declare const StyledLabel: StyletronComponent<any, any>;
|
|
78
78
|
|
|
79
79
|
export declare const arrayMove: typeof arrayMoveT;
|
|
80
80
|
export declare const arrayRemove: typeof arrayRemoveT;
|
package/drawer/index.d.ts
CHANGED
|
@@ -84,8 +84,8 @@ export class Drawer extends React.Component<DrawerProps, DrawerState> {
|
|
|
84
84
|
renderDrawer(): React.ReactNode;
|
|
85
85
|
}
|
|
86
86
|
|
|
87
|
-
export declare const StyledRoot: StyletronComponent<any>;
|
|
88
|
-
export declare const StyledBackdrop: StyletronComponent<any>;
|
|
89
|
-
export declare const StyledDrawerContainer: StyletronComponent<any>;
|
|
90
|
-
export declare const StyledDrawerBody: StyletronComponent<any>;
|
|
91
|
-
export declare const StyledClose: StyletronComponent<any>;
|
|
87
|
+
export declare const StyledRoot: StyletronComponent<any, any>;
|
|
88
|
+
export declare const StyledBackdrop: StyletronComponent<any, any>;
|
|
89
|
+
export declare const StyledDrawerContainer: StyletronComponent<any, any>;
|
|
90
|
+
export declare const StyledDrawerBody: StyletronComponent<any, any>;
|
|
91
|
+
export declare const StyledClose: StyletronComponent<any, any>;
|
|
@@ -5,6 +5,7 @@ This source code is licensed under the MIT license found in the
|
|
|
5
5
|
LICENSE file in the root directory of this source tree.
|
|
6
6
|
*/
|
|
7
7
|
import { styled, withStyle } from '../styles/index.js';
|
|
8
|
+
import { getMediaQueries } from '../helpers/responsive-helpers.js';
|
|
8
9
|
import { StyledListItem } from '../menu/index.js';
|
|
9
10
|
import { KIND } from './constants.js';
|
|
10
11
|
const StyledButton = styled('button', ({
|
|
@@ -41,10 +42,45 @@ export const StyledRoot = styled('div', props => {
|
|
|
41
42
|
const {
|
|
42
43
|
$theme
|
|
43
44
|
} = props;
|
|
44
|
-
|
|
45
|
+
const mediaQueries = getMediaQueries($theme.breakpoints);
|
|
46
|
+
const breakpoints = Object.values($theme.breakpoints).sort();
|
|
47
|
+
const margins = [];
|
|
48
|
+
|
|
49
|
+
if (Array.isArray($theme.grid.margins)) {
|
|
50
|
+
for (let i = 0; i < breakpoints.length; i++) {
|
|
51
|
+
const margin = $theme.grid.margins[i];
|
|
52
|
+
|
|
53
|
+
if (margin == null) {
|
|
54
|
+
margins.push($theme.grid.margins[$theme.grid.margins.length - 1]);
|
|
55
|
+
} else {
|
|
56
|
+
margins.push(margin);
|
|
57
|
+
}
|
|
58
|
+
}
|
|
59
|
+
} else {
|
|
60
|
+
for (let i = 0; i < breakpoints.length; i++) {
|
|
61
|
+
margins.push($theme.grid.margins);
|
|
62
|
+
}
|
|
63
|
+
}
|
|
64
|
+
|
|
65
|
+
const style = { ...$theme.typography.font300,
|
|
45
66
|
boxSizing: 'border-box',
|
|
46
|
-
backgroundColor: $theme.colors.backgroundPrimary
|
|
67
|
+
backgroundColor: $theme.colors.backgroundPrimary,
|
|
68
|
+
borderBottomWidth: '1px',
|
|
69
|
+
borderBottomStyle: 'solid',
|
|
70
|
+
borderBottomColor: `${$theme.colors.borderOpaque}`,
|
|
71
|
+
paddingInlineStart: margins[0] + 'px',
|
|
72
|
+
paddingInlineEnd: margins[0] + 'px'
|
|
47
73
|
};
|
|
74
|
+
|
|
75
|
+
for (let i = 1; i < mediaQueries.length; i++) {
|
|
76
|
+
const margin = Array.isArray($theme.grid.margins) ? $theme.grid.margins[i] : $theme.grid.margins;
|
|
77
|
+
style[mediaQueries[i]] = {
|
|
78
|
+
paddingInlineStart: margin + 'px',
|
|
79
|
+
paddingInlineEnd: margin + 'px'
|
|
80
|
+
};
|
|
81
|
+
}
|
|
82
|
+
|
|
83
|
+
return style;
|
|
48
84
|
});
|
|
49
85
|
StyledRoot.displayName = "StyledRoot";
|
|
50
86
|
export const StyledSubnavContainer = styled('div', {});
|
|
@@ -161,7 +197,7 @@ export const StyledSecondaryMenuContainer = styled('div', ({
|
|
|
161
197
|
flexWrap: 'nowrap',
|
|
162
198
|
justifyContent: 'flex-start',
|
|
163
199
|
margin: 'auto',
|
|
164
|
-
maxWidth: `${$theme.
|
|
200
|
+
maxWidth: `${$theme.grid.maxWidth}px`,
|
|
165
201
|
alignItems: 'stretch',
|
|
166
202
|
overflow: 'auto'
|
|
167
203
|
};
|
|
@@ -218,11 +254,7 @@ StyledUserProfileInfoContainer.displayName = "StyledUserProfileInfoContainer";
|
|
|
218
254
|
export const StyledDesktopMenuContainer = styled('div', ({
|
|
219
255
|
$theme
|
|
220
256
|
}) => {
|
|
221
|
-
return {
|
|
222
|
-
borderBottomWidth: '1px',
|
|
223
|
-
borderBottomStyle: 'solid',
|
|
224
|
-
borderBottomColor: `${$theme.colors.borderOpaque}`
|
|
225
|
-
};
|
|
257
|
+
return {};
|
|
226
258
|
});
|
|
227
259
|
StyledDesktopMenuContainer.displayName = "StyledDesktopMenuContainer";
|
|
228
260
|
export const StyledDesktopMenu = styled('div', ({
|
|
@@ -233,7 +265,7 @@ export const StyledDesktopMenu = styled('div', ({
|
|
|
233
265
|
display: 'flex',
|
|
234
266
|
justifyContent: 'space-between',
|
|
235
267
|
margin: 'auto',
|
|
236
|
-
maxWidth: `${$theme.
|
|
268
|
+
maxWidth: `${$theme.grid.maxWidth}px`,
|
|
237
269
|
paddingBlockStart: '18px',
|
|
238
270
|
paddingBlockEnd: '18px'
|
|
239
271
|
};
|
|
@@ -35,7 +35,10 @@ function FileUploader(props) {
|
|
|
35
35
|
const [ErrorMessage, errorMessageProps] = getOverrides(overrides.ErrorMessage, StyledErrorMessage);
|
|
36
36
|
const [HiddenInput, hiddenInputProps] = getOverrides(overrides.HiddenInput, StyledHiddenInput);
|
|
37
37
|
const [ButtonComponent, buttonProps] = getOverrides(overrides.ButtonComponent, Button);
|
|
38
|
+
const [RetryButtonComponent, retryButtonProps] = getOverrides(overrides.RetryButtonComponent, Button);
|
|
39
|
+
const [CancelButtonComponent, cancelButtonProps] = getOverrides(overrides.CancelButtonComponent, Button);
|
|
38
40
|
const [SpinnerComponent, spinnerProps] = getOverrides(overrides.Spinner, Spinner);
|
|
41
|
+
const [ProgressBarComponent, progressBarProps] = getOverrides(overrides.ProgressBar, ProgressBar);
|
|
39
42
|
const afterFileDrop = !!(props.progressAmount || props.progressMessage || props.errorMessage);
|
|
40
43
|
return /*#__PURE__*/React.createElement(Dropzone, _extends({}, props, {
|
|
41
44
|
disabled: props.disabled || afterFileDrop
|
|
@@ -73,7 +76,7 @@ function FileUploader(props) {
|
|
|
73
76
|
})
|
|
74
77
|
}
|
|
75
78
|
}
|
|
76
|
-
}, prefixedStyledProps, buttonProps), locale.fileuploader.browseFiles)), afterFileDrop && /*#__PURE__*/React.createElement(React.Fragment, null, typeof props.progressAmount === 'number' ? /*#__PURE__*/React.createElement(
|
|
79
|
+
}, prefixedStyledProps, buttonProps), locale.fileuploader.browseFiles)), afterFileDrop && /*#__PURE__*/React.createElement(React.Fragment, null, typeof props.progressAmount === 'number' ? /*#__PURE__*/React.createElement(ProgressBarComponent, _extends({
|
|
77
80
|
value: props.progressAmount,
|
|
78
81
|
overrides: {
|
|
79
82
|
BarProgress: {
|
|
@@ -84,12 +87,12 @@ function FileUploader(props) {
|
|
|
84
87
|
})
|
|
85
88
|
}
|
|
86
89
|
}
|
|
87
|
-
}) : props.errorMessage ? null : /*#__PURE__*/React.createElement(SpinnerComponent, _extends({
|
|
90
|
+
}, progressBarProps)) : props.errorMessage ? null : /*#__PURE__*/React.createElement(SpinnerComponent, _extends({
|
|
88
91
|
$size: SPINNER_SIZE.medium,
|
|
89
92
|
$style: {
|
|
90
93
|
marginBottom: theme.sizing.scale300
|
|
91
94
|
}
|
|
92
|
-
}, spinnerProps)), (props.errorMessage || props.progressMessage) && props.errorMessage ? /*#__PURE__*/React.createElement(ErrorMessage, _extends({}, prefixedStyledProps, errorMessageProps), props.errorMessage) : /*#__PURE__*/React.createElement(ContentMessage, _extends({}, prefixedStyledProps, contentMessageProps), props.progressMessage), props.errorMessage ? /*#__PURE__*/React.createElement(
|
|
95
|
+
}, spinnerProps)), (props.errorMessage || props.progressMessage) && props.errorMessage ? /*#__PURE__*/React.createElement(ErrorMessage, _extends({}, prefixedStyledProps, errorMessageProps), props.errorMessage) : /*#__PURE__*/React.createElement(ContentMessage, _extends({}, prefixedStyledProps, contentMessageProps), props.progressMessage), props.errorMessage ? /*#__PURE__*/React.createElement(RetryButtonComponent, _extends({
|
|
93
96
|
kind: KIND.tertiary,
|
|
94
97
|
onClick: () => {
|
|
95
98
|
props.onRetry && props.onRetry();
|
|
@@ -97,7 +100,7 @@ function FileUploader(props) {
|
|
|
97
100
|
"aria-invalid": Boolean(props.errorMessage),
|
|
98
101
|
"aria-describedby": props['aria-describedby'],
|
|
99
102
|
"aria-errormessage": props.errorMessage
|
|
100
|
-
}, locale.fileuploader.retry) : /*#__PURE__*/React.createElement(
|
|
103
|
+
}, retryButtonProps), locale.fileuploader.retry) : /*#__PURE__*/React.createElement(CancelButtonComponent, _extends({
|
|
101
104
|
kind: KIND.tertiary,
|
|
102
105
|
onClick: () => {
|
|
103
106
|
props.onCancel && props.onCancel();
|
|
@@ -112,7 +115,7 @@ function FileUploader(props) {
|
|
|
112
115
|
})
|
|
113
116
|
}
|
|
114
117
|
}
|
|
115
|
-
}, locale.fileuploader.cancel))), /*#__PURE__*/React.createElement(HiddenInput, _extends({
|
|
118
|
+
}, cancelButtonProps), locale.fileuploader.cancel))), /*#__PURE__*/React.createElement(HiddenInput, _extends({
|
|
116
119
|
"aria-invalid": Boolean(props.errorMessage) || null,
|
|
117
120
|
"aria-describedby": props['aria-describedby'],
|
|
118
121
|
"aria-errormessage": props.errorMessage || null
|
package/es/map-marker/index.js
CHANGED
|
@@ -6,4 +6,4 @@ LICENSE file in the root directory of this source tree.
|
|
|
6
6
|
*/
|
|
7
7
|
export { default as FixedMarker } from './fixed-marker.js';
|
|
8
8
|
export { default as FloatingMarker } from './floating-marker.js';
|
|
9
|
-
export { FLOATING_MARKER_ANCHOR_POSITIONS, FLOATING_MARKER_SIZES, FLOATING_MARKER_ANCHOR_TYPES, NEEDLE_SIZES, PINHEAD_SIZES_SHAPES, BADGE_ENHANCER_SIZES, LABEL_ENHANCER_POSITIONS, KIND } from './constants.js';
|
|
9
|
+
export { FLOATING_MARKER_ANCHOR_POSITIONS, FLOATING_MARKER_SIZES, FLOATING_MARKER_ANCHOR_TYPES, NEEDLE_SIZES, PINHEAD_SIZES_SHAPES, BADGE_ENHANCER_SIZES, LABEL_ENHANCER_POSITIONS, KIND, PINHEAD_DIMENSIONS } from './constants.js';
|