@pingux/astro 2.121.0-alpha.0 → 2.121.0-alpha.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/lib/cjs/components/Icon/Icon.js +13 -10
- package/lib/cjs/components/IconButton/IconButton.styles.d.ts +37 -0
- package/lib/cjs/components/IconButton/IconButton.styles.js +6 -1
- package/lib/cjs/components/IconWrapper/iconWrapperAttributes.js +1 -1
- package/lib/cjs/components/ListView/ListView.js +5 -0
- package/lib/cjs/components/ListView/ListView.stories.d.ts +3 -3
- package/lib/cjs/components/ListView/ListView.stories.js +27 -458
- package/lib/cjs/components/ListView/ListViewExpandableItem.js +1 -0
- package/lib/cjs/components/ListView/ListViewItem.js +4 -1
- package/lib/cjs/{styles/themes/next-gen/stories/NextGenListView.chromatic.stories.js → components/ListView/stories/ListView.chromatic.stories.js} +2 -2
- package/lib/cjs/components/ListView/stories/ListViewNextGenComponent.js +144 -0
- package/lib/cjs/{styles/themeOverrides/nextGenDarkMode/stories/NextGenDarkListView.chromatic.stories.js → components/ListView/stories/ListViewOnyxDark.stories.js} +3 -3
- package/lib/cjs/components/ListViewItem/ListViewItem.js +16 -5
- package/lib/cjs/components/ListViewItem/ListViewItem.stories.js +40 -3
- package/lib/cjs/components/ListViewItem/ListViewItem.styles.js +15 -1
- package/lib/cjs/components/ListViewItem/controls/ListViewItemEditButton.js +1 -1
- package/lib/cjs/components/ListViewItem/controls/ListViewItemMenu.js +9 -3
- package/lib/cjs/components/ListViewItem/controls/ListViewItemMenu.test.js +1 -0
- package/lib/cjs/components/ListViewItem/controls/chart/ListViewItemChart.js +5 -1
- package/lib/cjs/components/Pagination/Pagination.stories.js +3 -3
- package/lib/cjs/components/SearchField/SearchField.js +2 -8
- package/lib/cjs/hooks/useExpandableListViewItem/useExpandableListViewItem.js +9 -3
- package/lib/cjs/hooks/useGetTheme/useGetTheme.d.ts +2 -0
- package/lib/cjs/styles/themeOverrides/nextGenDarkMode/colors.d.ts +4 -0
- package/lib/cjs/styles/themeOverrides/nextGenDarkMode/colors.js +4 -0
- package/lib/cjs/styles/themeOverrides/nextGenDarkMode/customProperties/icons.d.ts +1 -0
- package/lib/cjs/styles/themeOverrides/nextGenDarkMode/customProperties/index.d.ts +1 -0
- package/lib/cjs/styles/themeOverrides/nextGenDarkMode/nextGenDarkModeOverride.js +2 -0
- package/lib/cjs/styles/themeOverrides/nextGenDarkMode/variants/listview.d.ts +58 -0
- package/lib/cjs/styles/themeOverrides/nextGenDarkMode/variants/{lsitview.js → listview.js} +37 -2
- package/lib/cjs/styles/themeOverrides/nextGenDarkMode/variants/text.d.ts +15 -0
- package/lib/cjs/styles/themeOverrides/nextGenDarkMode/variants/text.js +23 -0
- package/lib/cjs/styles/themeOverrides/nextGenDarkMode/variants/variants.d.ts +34 -0
- package/lib/cjs/styles/themeOverrides/nextGenDarkMode/variants/variants.js +4 -3
- package/lib/cjs/styles/themes/astro/customProperties/icons.d.ts +1 -0
- package/lib/cjs/styles/themes/astro/customProperties/icons.js +2 -1
- package/lib/cjs/styles/themes/astro/customProperties/index.d.ts +1 -0
- package/lib/cjs/styles/themes/next-gen/colors/colors.d.ts +4 -0
- package/lib/cjs/styles/themes/next-gen/colors/iconWrapper.d.ts +4 -0
- package/lib/cjs/styles/themes/next-gen/colors/iconWrapper.js +4 -0
- package/lib/cjs/styles/themes/next-gen/convertedComponentList.js +1 -1
- package/lib/cjs/styles/themes/next-gen/customProperties/icons.d.ts +1 -0
- package/lib/cjs/styles/themes/next-gen/customProperties/icons.js +2 -1
- package/lib/cjs/styles/themes/next-gen/customProperties/index.d.ts +1 -0
- package/lib/cjs/styles/themes/next-gen/next-gen.d.ts +123 -18
- package/lib/cjs/styles/themes/next-gen/variants/button.d.ts +24 -0
- package/lib/cjs/styles/themes/next-gen/variants/button.js +12 -1
- package/lib/cjs/styles/themes/next-gen/variants/listview.d.ts +79 -17
- package/lib/cjs/styles/themes/next-gen/variants/listview.js +89 -24
- package/lib/cjs/styles/themes/next-gen/variants/text.d.ts +13 -1
- package/lib/cjs/styles/themes/next-gen/variants/text.js +16 -4
- package/lib/cjs/styles/themes/next-gen/variants/variants.d.ts +82 -17
- package/lib/cjs/styles/themes/next-gen/variants/variants.js +8 -1
- package/lib/cjs/types/iconWrapper.d.ts +1 -1
- package/lib/cjs/utils/devUtils/constants/animals.js +449 -1
- package/lib/components/Icon/Icon.js +13 -10
- package/lib/components/IconButton/IconButton.styles.js +6 -1
- package/lib/components/IconWrapper/iconWrapperAttributes.js +1 -1
- package/lib/components/ListView/ListView.js +5 -0
- package/lib/components/ListView/ListView.stories.js +25 -455
- package/lib/components/ListView/ListViewExpandableItem.js +1 -0
- package/lib/components/ListView/ListViewItem.js +4 -1
- package/lib/{styles/themes/next-gen/stories/NextGenListView.chromatic.stories.js → components/ListView/stories/ListView.chromatic.stories.js} +2 -2
- package/lib/components/ListView/stories/ListViewNextGenComponent.js +130 -0
- package/lib/{styles/themeOverrides/nextGenDarkMode/stories/NextGenDarkListView.chromatic.stories.js → components/ListView/stories/ListViewOnyxDark.stories.js} +3 -3
- package/lib/components/ListViewItem/ListViewItem.js +18 -7
- package/lib/components/ListViewItem/ListViewItem.stories.js +40 -3
- package/lib/components/ListViewItem/ListViewItem.styles.js +15 -1
- package/lib/components/ListViewItem/controls/ListViewItemEditButton.js +1 -1
- package/lib/components/ListViewItem/controls/ListViewItemMenu.js +9 -3
- package/lib/components/ListViewItem/controls/ListViewItemMenu.test.js +1 -0
- package/lib/components/ListViewItem/controls/chart/ListViewItemChart.js +5 -1
- package/lib/components/Pagination/Pagination.stories.js +1 -1
- package/lib/components/SearchField/SearchField.js +2 -8
- package/lib/hooks/useExpandableListViewItem/useExpandableListViewItem.js +9 -3
- package/lib/styles/themeOverrides/nextGenDarkMode/colors.js +4 -0
- package/lib/styles/themeOverrides/nextGenDarkMode/nextGenDarkModeOverride.js +2 -0
- package/lib/styles/themeOverrides/nextGenDarkMode/variants/listview.js +58 -0
- package/lib/styles/themeOverrides/nextGenDarkMode/variants/text.js +15 -0
- package/lib/styles/themeOverrides/nextGenDarkMode/variants/variants.js +2 -1
- package/lib/styles/themes/astro/customProperties/icons.js +2 -1
- package/lib/styles/themes/next-gen/colors/iconWrapper.js +4 -0
- package/lib/styles/themes/next-gen/convertedComponentList.js +1 -1
- package/lib/styles/themes/next-gen/customProperties/icons.js +2 -1
- package/lib/styles/themes/next-gen/variants/button.js +12 -1
- package/lib/styles/themes/next-gen/variants/listview.js +84 -22
- package/lib/styles/themes/next-gen/variants/text.js +16 -4
- package/lib/styles/themes/next-gen/variants/variants.js +9 -2
- package/lib/utils/devUtils/constants/animals.js +449 -1
- package/package.json +1 -1
- package/lib/cjs/recipes/NextGen/ListViewNextGen.stories.js +0 -23
- package/lib/cjs/styles/themeOverrides/nextGenDarkMode/variants/lsitview.d.ts +0 -24
- package/lib/cjs/styles/themes/next-gen/stories/ListViewItemNextGen.d.ts +0 -29
- package/lib/cjs/styles/themes/next-gen/stories/ListViewItemNextGen.js +0 -84
- package/lib/cjs/styles/themes/next-gen/stories/ListViewNextGenComponent.js +0 -67
- package/lib/cjs/styles/themes/next-gen/stories/NextGenListViewItem.stories.d.ts +0 -6
- package/lib/cjs/styles/themes/next-gen/stories/NextGenListViewItem.stories.js +0 -35
- package/lib/recipes/NextGen/ListViewNextGen.stories.js +0 -13
- package/lib/styles/themeOverrides/nextGenDarkMode/variants/lsitview.js +0 -24
- package/lib/styles/themes/next-gen/stories/ListViewItemNextGen.js +0 -75
- package/lib/styles/themes/next-gen/stories/ListViewNextGenComponent.js +0 -58
- package/lib/styles/themes/next-gen/stories/NextGenListViewItem.stories.js +0 -25
- /package/lib/cjs/{styles/themeOverrides/nextGenDarkMode/stories/NextGenDarkListView.chromatic.stories.d.ts → components/ListView/stories/ListView.chromatic.stories.d.ts} +0 -0
- /package/lib/cjs/{styles/themes/next-gen → components/ListView}/stories/ListViewNextGenComponent.d.ts +0 -0
- /package/lib/cjs/{styles/themes/next-gen/stories/NextGenListView.chromatic.stories.d.ts → components/ListView/stories/ListViewOnyxDark.stories.d.ts} +0 -0
@@ -1,22 +1,23 @@
|
|
1
1
|
import _extends from "@babel/runtime-corejs3/helpers/esm/extends";
|
2
2
|
import _objectWithoutProperties from "@babel/runtime-corejs3/helpers/esm/objectWithoutProperties";
|
3
|
-
var _excluded = ["children", "className", "data", "iconProps", "isHovered", "isSelected", "linkProps", "onHoverChange", "onHoverEnd", "onHoverStart", "slots"];
|
3
|
+
var _excluded = ["children", "className", "data", "iconProps", "iconWrapperProps", "isHovered", "isSelected", "linkProps", "onHoverChange", "onHoverEnd", "onHoverStart", "slots"];
|
4
4
|
import _concatInstanceProperty from "@babel/runtime-corejs3/core-js-stable/instance/concat";
|
5
5
|
import React, { forwardRef } from 'react';
|
6
6
|
import { useHover } from '@react-aria/interactions';
|
7
|
-
import { Box, Icon, Image, Text } from '../..';
|
8
|
-
import { useStatusClasses } from '../../hooks';
|
7
|
+
import { Box, Icon, IconWrapper, Image, Text } from '../..';
|
8
|
+
import { useGetTheme, useStatusClasses } from '../../hooks';
|
9
9
|
import { getPendoID } from '../../utils/devUtils/constants/pendoID';
|
10
10
|
import { listViewItemPropTypes } from './listViewItemAttributes';
|
11
11
|
import { jsx as ___EmotionJSX } from "@emotion/react";
|
12
12
|
export var LIST_ITEM_ICON = '-list-item-icon';
|
13
13
|
var displayName = 'ListViewItem';
|
14
14
|
var ListViewItem = /*#__PURE__*/forwardRef(function (_ref, ref) {
|
15
|
-
var _context;
|
15
|
+
var _context, _context2;
|
16
16
|
var children = _ref.children,
|
17
17
|
className = _ref.className,
|
18
18
|
data = _ref.data,
|
19
19
|
iconProps = _ref.iconProps,
|
20
|
+
iconWrapperProps = _ref.iconWrapperProps,
|
20
21
|
isHovered = _ref.isHovered,
|
21
22
|
isSelected = _ref.isSelected,
|
22
23
|
linkProps = _ref.linkProps,
|
@@ -47,7 +48,17 @@ var ListViewItem = /*#__PURE__*/forwardRef(function (_ref, ref) {
|
|
47
48
|
if (image && !icon) return 'listViewItem.imageWrapper';
|
48
49
|
return 'listViewItem.iconWrapper';
|
49
50
|
};
|
50
|
-
var
|
51
|
+
var _useGetTheme = useGetTheme(),
|
52
|
+
isOnyx = _useGetTheme.themeState.isOnyx;
|
53
|
+
var renderIcon = icon && (isOnyx ? ___EmotionJSX(IconWrapper, _extends({
|
54
|
+
icon: icon,
|
55
|
+
size: "sm",
|
56
|
+
title: {
|
57
|
+
name: _concatInstanceProperty(_context = "".concat(text)).call(_context, LIST_ITEM_ICON)
|
58
|
+
},
|
59
|
+
isCircle: true,
|
60
|
+
color: "cyan"
|
61
|
+
}, iconWrapperProps)) : ___EmotionJSX(Box, {
|
51
62
|
width: "25px",
|
52
63
|
variant: "listViewItem.iconContainer"
|
53
64
|
}, ___EmotionJSX(Icon, _extends({
|
@@ -55,9 +66,9 @@ var ListViewItem = /*#__PURE__*/forwardRef(function (_ref, ref) {
|
|
55
66
|
icon: icon,
|
56
67
|
size: "md",
|
57
68
|
title: {
|
58
|
-
name: _concatInstanceProperty(
|
69
|
+
name: _concatInstanceProperty(_context2 = "".concat(text)).call(_context2, LIST_ITEM_ICON)
|
59
70
|
}
|
60
|
-
}, iconProps)));
|
71
|
+
}, iconProps))));
|
61
72
|
var renderImage = !icon && image && ___EmotionJSX(Box, {
|
62
73
|
width: "35px"
|
63
74
|
}, ___EmotionJSX(Image, {
|
@@ -4,6 +4,7 @@ import AccountIcon from '@pingux/mdi-react/AccountIcon';
|
|
4
4
|
import FormSelectIcon from '@pingux/mdi-react/FormSelectIcon';
|
5
5
|
import DocsLayout from '../../../.storybook/storybookDocsLayout';
|
6
6
|
import { Badge, Box, ListViewItem, ListViewItemChart, ListViewItemEditButton, ListViewItemMenu, ListViewItemSwitchField, Separator, Text } from '../..';
|
7
|
+
import { useGetTheme } from '../../hooks';
|
7
8
|
import { FIGMA_LINKS } from '../../utils/designUtils/figmaLinks';
|
8
9
|
import { pingImg } from '../../utils/devUtils/constants/images';
|
9
10
|
import { chartData } from './controls/chart/chartData';
|
@@ -27,13 +28,21 @@ export default {
|
|
27
28
|
};
|
28
29
|
var Wrapper = function Wrapper(_ref) {
|
29
30
|
var children = _ref.children;
|
31
|
+
var _useGetTheme = useGetTheme(),
|
32
|
+
isOnyx = _useGetTheme.themeState.isOnyx;
|
30
33
|
return ___EmotionJSX(Box, {
|
31
|
-
sx: {
|
34
|
+
sx: isOnyx ? {
|
35
|
+
bg: 'transparent',
|
36
|
+
border: '1px solid',
|
37
|
+
borderColor: 'border.base',
|
38
|
+
borderRadius: '1rem',
|
39
|
+
p: '0'
|
40
|
+
} : {
|
32
41
|
bg: 'accent.99'
|
33
42
|
}
|
34
|
-
}, ___EmotionJSX(Separator, {
|
43
|
+
}, !isOnyx && ___EmotionJSX(Separator, {
|
35
44
|
margin: 0
|
36
|
-
}), children, ___EmotionJSX(Separator, {
|
45
|
+
}), children, !isOnyx && ___EmotionJSX(Separator, {
|
37
46
|
margin: 0
|
38
47
|
}));
|
39
48
|
};
|
@@ -42,6 +51,10 @@ export var Default = function Default() {
|
|
42
51
|
data: {
|
43
52
|
icon: AccountIcon,
|
44
53
|
text: 'Fons Vernall'
|
54
|
+
},
|
55
|
+
iconWrapperProps: {
|
56
|
+
size: 'sm',
|
57
|
+
color: 'green'
|
45
58
|
}
|
46
59
|
}));
|
47
60
|
};
|
@@ -57,6 +70,10 @@ export var WithSubtext = function WithSubtext() {
|
|
57
70
|
icon: AccountIcon,
|
58
71
|
subtext: 'rad_developer@pingidentity.com',
|
59
72
|
text: 'Fons Vernall'
|
73
|
+
},
|
74
|
+
iconWrapperProps: {
|
75
|
+
size: 'sm',
|
76
|
+
color: 'pink'
|
60
77
|
}
|
61
78
|
}));
|
62
79
|
};
|
@@ -90,6 +107,10 @@ export var WithControls = function WithControls() {
|
|
90
107
|
data: {
|
91
108
|
icon: FormSelectIcon,
|
92
109
|
text: 'Fons Vernall'
|
110
|
+
},
|
111
|
+
iconWrapperProps: {
|
112
|
+
size: 'sm',
|
113
|
+
color: 'orange'
|
93
114
|
}
|
94
115
|
}, ___EmotionJSX(ListViewItemEditButton, {
|
95
116
|
"aria-label": "edit-icon"
|
@@ -126,6 +147,10 @@ export var WithRightOfDataSlot = function WithRightOfDataSlot() {
|
|
126
147
|
text: 'Fons Vernall',
|
127
148
|
subtext: 'verylongemailaddress@email.com'
|
128
149
|
},
|
150
|
+
iconWrapperProps: {
|
151
|
+
size: 'sm',
|
152
|
+
color: 'teal'
|
153
|
+
},
|
129
154
|
slots: {
|
130
155
|
rightOfData: renderRightOfData
|
131
156
|
}
|
@@ -156,6 +181,10 @@ export var WithLeftOfDataSlot = function WithLeftOfDataSlot() {
|
|
156
181
|
icon: AccountIcon,
|
157
182
|
text: 'Fons Vernall',
|
158
183
|
subtext: 'verylongemailaddress@email.com'
|
184
|
+
},
|
185
|
+
iconWrapperProps: {
|
186
|
+
size: 'sm',
|
187
|
+
color: 'orange'
|
159
188
|
}
|
160
189
|
// Note that when the leftOfData slot is used, it overrides the provided icon and
|
161
190
|
// removes all margins and padding on the left of data
|
@@ -185,6 +214,10 @@ export var WithCharts = function WithCharts() {
|
|
185
214
|
text: 'Kangaroo',
|
186
215
|
subtext: 'kangaroo@example.com',
|
187
216
|
icon: FormSelectIcon
|
217
|
+
},
|
218
|
+
iconWrapperProps: {
|
219
|
+
size: 'sm',
|
220
|
+
color: 'purple'
|
188
221
|
}
|
189
222
|
}, ___EmotionJSX(ListViewItemChart, {
|
190
223
|
containerRef: containerRef,
|
@@ -229,6 +262,10 @@ export var WithExtraLongText = function WithExtraLongText() {
|
|
229
262
|
text: longText,
|
230
263
|
subtext: longText
|
231
264
|
},
|
265
|
+
iconWrapperProps: {
|
266
|
+
size: 'sm',
|
267
|
+
color: 'orange'
|
268
|
+
},
|
232
269
|
slots: {
|
233
270
|
rightOfData: renderRightOfData
|
234
271
|
}
|
@@ -145,6 +145,17 @@ var expandableRow = {
|
|
145
145
|
borderBottomColor: 'line.light'
|
146
146
|
}
|
147
147
|
};
|
148
|
+
var expandIcon = {
|
149
|
+
color: 'gray-900'
|
150
|
+
};
|
151
|
+
var editIcon = {
|
152
|
+
width: '25px !important',
|
153
|
+
height: '25px !important'
|
154
|
+
};
|
155
|
+
var menuIcon = {
|
156
|
+
width: '25px !important',
|
157
|
+
height: '25px !important'
|
158
|
+
};
|
148
159
|
export default {
|
149
160
|
container: container,
|
150
161
|
controls: controls,
|
@@ -159,5 +170,8 @@ export default {
|
|
159
170
|
expandableFocusContainer: expandableFocusContainer,
|
160
171
|
expandableItemBody: expandableItemBody,
|
161
172
|
expandableStyledListItem: expandableStyledListItem,
|
162
|
-
expandableRow: expandableRow
|
173
|
+
expandableRow: expandableRow,
|
174
|
+
expandIcon: expandIcon,
|
175
|
+
editIcon: editIcon,
|
176
|
+
menuIcon: menuIcon
|
163
177
|
};
|
@@ -17,7 +17,7 @@ var ListViewItemEditButton = /*#__PURE__*/forwardRef(function (props, ref) {
|
|
17
17
|
ml: "sm"
|
18
18
|
}, ___EmotionJSX(IconButton, props, ___EmotionJSX(Icon, {
|
19
19
|
icon: CreateIcon,
|
20
|
-
|
20
|
+
variant: "listViewItem.editIcon"
|
21
21
|
})));
|
22
22
|
});
|
23
23
|
ListViewItemEditButton.propTypes = iconButtonPropTypes;
|
@@ -2,8 +2,8 @@ import _extends from "@babel/runtime-corejs3/helpers/esm/extends";
|
|
2
2
|
import _objectWithoutProperties from "@babel/runtime-corejs3/helpers/esm/objectWithoutProperties";
|
3
3
|
var _excluded = ["children", "iconButtonProps"];
|
4
4
|
import React, { forwardRef } from 'react';
|
5
|
-
import MoreVertIcon from '@pingux/mdi-react/MoreVertIcon';
|
6
5
|
import { Icon, IconButton, Menu, PopoverMenu } from '../../..';
|
6
|
+
import { useGetTheme } from '../../../hooks';
|
7
7
|
import { menuPropTypes } from '../../Menu/menuAttributes';
|
8
8
|
|
9
9
|
/**
|
@@ -18,12 +18,18 @@ var ListViewItemMenu = /*#__PURE__*/forwardRef(function (_ref, ref) {
|
|
18
18
|
var children = _ref.children,
|
19
19
|
iconButtonProps = _ref.iconButtonProps,
|
20
20
|
others = _objectWithoutProperties(_ref, _excluded);
|
21
|
+
var _useGetTheme = useGetTheme(),
|
22
|
+
icons = _useGetTheme.icons;
|
23
|
+
var listViewMenu = icons.listViewMenu;
|
21
24
|
return ___EmotionJSX(PopoverMenu, null, ___EmotionJSX(IconButton, _extends({
|
22
25
|
"aria-label": "more",
|
23
26
|
ref: ref
|
24
27
|
}, iconButtonProps), ___EmotionJSX(Icon, {
|
25
|
-
icon:
|
26
|
-
|
28
|
+
icon: listViewMenu,
|
29
|
+
variant: "listViewItem.menuIcon",
|
30
|
+
title: {
|
31
|
+
name: 'Menu Icon'
|
32
|
+
}
|
27
33
|
})), ___EmotionJSX(Menu, others, children));
|
28
34
|
});
|
29
35
|
ListViewItemMenu.propTypes = menuPropTypes;
|
@@ -20,6 +20,7 @@ var getComponent = function getComponent() {
|
|
20
20
|
var props = arguments.length > 0 && arguments[0] !== undefined ? arguments[0] : {};
|
21
21
|
return render(___EmotionJSX(ListViewItemMenu, props, ___EmotionJSX(Item, null, "testItem")));
|
22
22
|
};
|
23
|
+
|
23
24
|
// Needs to be added to each components test file
|
24
25
|
universalComponentTests({
|
25
26
|
renderComponent: function renderComponent(props) {
|
@@ -16,8 +16,10 @@ import React, { forwardRef, useCallback, useEffect, useMemo } from 'react';
|
|
16
16
|
import { useVisuallyHidden } from 'react-aria';
|
17
17
|
import { Line, LineChart, ResponsiveContainer } from 'recharts';
|
18
18
|
import useResizeObserver from 'use-resize-observer';
|
19
|
+
import { useGetTheme } from '../../../../hooks';
|
19
20
|
import { Box, Button, Text, Tooltip, TooltipTrigger } from '../../../../index';
|
20
21
|
import { neutral } from '../../../../styles/colors';
|
22
|
+
import { nextGenColors } from '../../../../styles/themes/next-gen/tokens/colorTokens';
|
21
23
|
import { listViewItemChartPropTypes } from './ListViewItemChartAttributes';
|
22
24
|
import { jsx as ___EmotionJSX } from "@emotion/react";
|
23
25
|
var ListViewItemChart = /*#__PURE__*/forwardRef(function (props, ref) {
|
@@ -85,6 +87,8 @@ var ListViewItemChart = /*#__PURE__*/forwardRef(function (props, ref) {
|
|
85
87
|
}
|
86
88
|
setAriaLabel();
|
87
89
|
}, [ariaLabel, containerRef]);
|
90
|
+
var _useGetTheme = useGetTheme(),
|
91
|
+
isOnyxDark = _useGetTheme.themeState.isOnyxDark;
|
88
92
|
return ___EmotionJSX(Box, {
|
89
93
|
isRow: true,
|
90
94
|
alignItems: "center",
|
@@ -120,7 +124,7 @@ var ListViewItemChart = /*#__PURE__*/forwardRef(function (props, ref) {
|
|
120
124
|
type: "monotone",
|
121
125
|
dataKey: chartDataKey,
|
122
126
|
dot: false,
|
123
|
-
stroke: neutral[20]
|
127
|
+
stroke: isOnyxDark ? nextGenColors['gray-100'] : neutral[20]
|
124
128
|
})))), ___EmotionJSX(Text, {
|
125
129
|
variant: "variants.lisViewItemChart.chartLabel"
|
126
130
|
}, chartLabel)), ___EmotionJSX(Box, {
|
@@ -6,7 +6,7 @@ import React, { useState } from 'react';
|
|
6
6
|
import FormSelectIcon from '@pingux/mdi-react/FormSelectIcon';
|
7
7
|
import usePaginationState from '../../hooks/usePaginationState';
|
8
8
|
import { Box, Button, Item, ListView, ListViewItem, Pagination, PaginationProvider, ScrollBox } from '../../index';
|
9
|
-
import
|
9
|
+
import animals from '../../utils/devUtils/constants/animals';
|
10
10
|
import PaginationReadme from './Pagination.mdx';
|
11
11
|
import { jsx as ___EmotionJSX } from "@emotion/react";
|
12
12
|
export default {
|
@@ -72,14 +72,8 @@ var SearchField = /*#__PURE__*/forwardRef(function (props, ref) {
|
|
72
72
|
}, iconProps)), !hasNoClearButton && state.value !== '' && ___EmotionJSX(IconButton, _extends({
|
73
73
|
tabIndex: 0,
|
74
74
|
onKeyDown: handleKeyDownEvent,
|
75
|
-
|
76
|
-
|
77
|
-
top: 8,
|
78
|
-
right: 10,
|
79
|
-
path: {
|
80
|
-
fill: 'text.secondary'
|
81
|
-
}
|
82
|
-
}
|
75
|
+
color: "text.secondary",
|
76
|
+
variant: "searchClearButton"
|
83
77
|
}, clearButtonProps), ___EmotionJSX(Icon, {
|
84
78
|
icon: CloseIcon,
|
85
79
|
title: {
|
@@ -158,15 +158,21 @@ var useExpandableListViewItem = function useExpandableListViewItem(props) {
|
|
158
158
|
isHovered: isSelectable && item.key === state.hover.hoveredItem,
|
159
159
|
isSelected: isSelected,
|
160
160
|
isExpanded: isExpanded,
|
161
|
-
isFocused: isDisabled ? false : isFocusVisible || isFocusVisibleWithin && !isFocusEscaped && !isFocusVisibleContainer
|
161
|
+
isFocused: isDisabled ? false : isFocusVisible || isFocusVisibleWithin && !isFocusEscaped && !isFocusVisibleContainer,
|
162
|
+
isFirstItem: item.index === 0,
|
163
|
+
isLastItem: item.index === state.collection.size - 1
|
162
164
|
}),
|
163
165
|
classNames = _useStatusClasses.classNames;
|
164
166
|
var _useStatusClasses2 = useStatusClasses('', {
|
165
|
-
isFocused: isFocusVisibleContainer
|
167
|
+
isFocused: isFocusVisibleContainer,
|
168
|
+
isFirstItemBody: item.index === 0,
|
169
|
+
isLastItemBody: item.index === state.collection.size - 1
|
166
170
|
}),
|
167
171
|
focusContainerClassName = _useStatusClasses2.classNames;
|
168
172
|
var _useStatusClasses3 = useStatusClasses('', {
|
169
|
-
hasSeparator: hasSeparator
|
173
|
+
hasSeparator: hasSeparator,
|
174
|
+
isFirstRow: item.index === 0,
|
175
|
+
isLastRow: item.index === state.collection.size - 1
|
170
176
|
}),
|
171
177
|
rowClassName = _useStatusClasses3.classNames;
|
172
178
|
var expandableRowProps = _objectSpread(_objectSpread(_objectSpread(_objectSpread(_objectSpread({
|
@@ -35,6 +35,8 @@ var iconWrapper = {
|
|
35
35
|
red: nextGenColors['red-500'],
|
36
36
|
yellow: nextGenColors['yellow-500'],
|
37
37
|
teal: nextGenColors['teal-500'],
|
38
|
+
blue: nextGenColors['blue-500'],
|
39
|
+
indigo: nextGenColors['indigo-500'],
|
38
40
|
lightBlue: nextGenColors['blue-600'],
|
39
41
|
lightPink: nextGenColors['pink-600'],
|
40
42
|
lightGreen: nextGenColors['green-800'],
|
@@ -50,6 +52,8 @@ var iconWrapper = {
|
|
50
52
|
red: 'black',
|
51
53
|
yellow: 'black',
|
52
54
|
teal: 'black',
|
55
|
+
blue: 'black',
|
56
|
+
indigo: 'black',
|
53
57
|
lightBlue: nextGenColors['blue-100'],
|
54
58
|
lightPink: nextGenColors['pink-100'],
|
55
59
|
lightGreen: nextGenColors['green-100'],
|
@@ -6,6 +6,7 @@ import buttons from './variants/buttons';
|
|
6
6
|
import cards from './variants/cards';
|
7
7
|
import forms from './variants/forms';
|
8
8
|
import links from './variants/links';
|
9
|
+
import { text } from './variants/text';
|
9
10
|
import variants from './variants/variants';
|
10
11
|
import { colors } from './colors';
|
11
12
|
var override = {
|
@@ -16,6 +17,7 @@ var override = {
|
|
16
17
|
badges: badges,
|
17
18
|
links: links,
|
18
19
|
cards: cards,
|
20
|
+
text: text,
|
19
21
|
name: themes.NEXT_GEN_DARK
|
20
22
|
};
|
21
23
|
var NextGenDarkTheme = merge(NextGenTheme, override);
|
@@ -0,0 +1,58 @@
|
|
1
|
+
export var listViewItem = {
|
2
|
+
styledListItem: {
|
3
|
+
'&.has-separator': {
|
4
|
+
borderBottom: '1px solid',
|
5
|
+
borderBottomColor: 'border.base'
|
6
|
+
},
|
7
|
+
bg: 'background.base',
|
8
|
+
'&.is-selected': {
|
9
|
+
bg: 'background.hover'
|
10
|
+
},
|
11
|
+
'&.is-hovered': {
|
12
|
+
bg: 'background.hover'
|
13
|
+
},
|
14
|
+
'&.is-focused': {
|
15
|
+
boxShadow: '0 0 0 3px inset #1a73e8',
|
16
|
+
bg: 'background.hover'
|
17
|
+
}
|
18
|
+
},
|
19
|
+
expandableStyledListItem: {
|
20
|
+
'&.is-hovered': {
|
21
|
+
bg: 'background.hover'
|
22
|
+
},
|
23
|
+
'&.is-selected': {
|
24
|
+
bg: 'background.hover'
|
25
|
+
},
|
26
|
+
'&.is-focused': {
|
27
|
+
bg: 'background.hover'
|
28
|
+
}
|
29
|
+
},
|
30
|
+
expandIcon: {
|
31
|
+
color: 'gray-400'
|
32
|
+
}
|
33
|
+
};
|
34
|
+
export var listView = {
|
35
|
+
container: {
|
36
|
+
borderColor: 'border.base'
|
37
|
+
}
|
38
|
+
};
|
39
|
+
export var lisViewItemChart = {
|
40
|
+
title: {
|
41
|
+
color: 'gray-100'
|
42
|
+
},
|
43
|
+
count: {
|
44
|
+
color: 'gray-100'
|
45
|
+
},
|
46
|
+
countLabel: {
|
47
|
+
color: 'gray-100'
|
48
|
+
},
|
49
|
+
chartLabel: {
|
50
|
+
color: 'gray-100'
|
51
|
+
},
|
52
|
+
trend: {
|
53
|
+
color: 'gray-100'
|
54
|
+
},
|
55
|
+
chartButton: {
|
56
|
+
color: 'gray-100'
|
57
|
+
}
|
58
|
+
};
|
@@ -1,6 +1,6 @@
|
|
1
1
|
import { avatar } from './avatar';
|
2
2
|
import iconBadge from './iconBadge';
|
3
|
-
import { listView, listViewItem } from './
|
3
|
+
import { listView, listViewItem, lisViewItemChart } from './listview';
|
4
4
|
import { menu, menuItem } from './menu';
|
5
5
|
import { message } from './message';
|
6
6
|
import { navBar } from './navbar';
|
@@ -68,6 +68,7 @@ export default {
|
|
68
68
|
menuItem: menuItem,
|
69
69
|
listViewItem: listViewItem,
|
70
70
|
listView: listView,
|
71
|
+
lisViewItemChart: lisViewItemChart,
|
71
72
|
navBar: navBar,
|
72
73
|
listBox: listBox,
|
73
74
|
modal: modal,
|
@@ -6,9 +6,10 @@ import CheckCircleIcon from '@pingux/mdi-react/CheckCircleIcon';
|
|
6
6
|
import InformationIcon from '@pingux/mdi-react/InformationIcon';
|
7
7
|
import MenuDown from '@pingux/mdi-react/MenuDownIcon';
|
8
8
|
import MenuUp from '@pingux/mdi-react/MenuUpIcon';
|
9
|
+
import MoreVertIcon from '@pingux/mdi-react/MoreVertIcon';
|
9
10
|
import { pingLogoHorizontalSmallWhite } from '../../../../utils/devUtils/constants/logos';
|
10
11
|
import statuses from '../../../../utils/devUtils/constants/statuses';
|
11
12
|
export default (_MenuDown$MenuUp$stat = {
|
12
13
|
MenuDown: MenuDown,
|
13
14
|
MenuUp: MenuUp
|
14
|
-
}, _defineProperty(_MenuDown$MenuUp$stat, statuses.DEFAULT, InformationIcon), _defineProperty(_MenuDown$MenuUp$stat, statuses.ERROR, AlertCircleIcon), _defineProperty(_MenuDown$MenuUp$stat, statuses.SUCCESS, CheckCircleIcon), _defineProperty(_MenuDown$MenuUp$stat, statuses.WARNING, AlertIcon), _defineProperty(_MenuDown$MenuUp$stat, "pingLogoHorizontalSmall", pingLogoHorizontalSmallWhite), _MenuDown$MenuUp$stat);
|
15
|
+
}, _defineProperty(_MenuDown$MenuUp$stat, statuses.DEFAULT, InformationIcon), _defineProperty(_MenuDown$MenuUp$stat, statuses.ERROR, AlertCircleIcon), _defineProperty(_MenuDown$MenuUp$stat, statuses.SUCCESS, CheckCircleIcon), _defineProperty(_MenuDown$MenuUp$stat, statuses.WARNING, AlertIcon), _defineProperty(_MenuDown$MenuUp$stat, "pingLogoHorizontalSmall", pingLogoHorizontalSmallWhite), _defineProperty(_MenuDown$MenuUp$stat, "listViewMenu", MoreVertIcon), _MenuDown$MenuUp$stat);
|
@@ -9,6 +9,8 @@ export var iconWrapper = {
|
|
9
9
|
red: nextGenColors['red-100'],
|
10
10
|
yellow: nextGenColors['yellow-100'],
|
11
11
|
teal: nextGenColors['teal-100'],
|
12
|
+
blue: nextGenColors['blue-100'],
|
13
|
+
indigo: nextGenColors['indigo-100'],
|
12
14
|
lightBlue: nextGenColors['blue-100'],
|
13
15
|
lightPink: nextGenColors['pink-100'],
|
14
16
|
lightGreen: nextGenColors['green-100'],
|
@@ -24,6 +26,8 @@ export var iconWrapper = {
|
|
24
26
|
red: nextGenColors['red-800'],
|
25
27
|
yellow: nextGenColors['yellow-800'],
|
26
28
|
teal: nextGenColors['teal-800'],
|
29
|
+
blue: nextGenColors['blue-600'],
|
30
|
+
indigo: nextGenColors['indigo-700'],
|
27
31
|
lightBlue: nextGenColors['blue-500'],
|
28
32
|
lightPink: nextGenColors['pink-600'],
|
29
33
|
lightGreen: nextGenColors['green-800'],
|
@@ -1,4 +1,4 @@
|
|
1
|
-
var nextGenConvertedComponents = ['DataTable', 'Message', 'Button', 'Badge', 'IconButton', 'CheckboxField', 'Messages', 'PopoverMenu', 'TextField', 'PasswordField', 'SearchField', 'SelectField', 'Modal', 'RadioField', 'MultiValuesField', 'TextAreaField', 'RadioGroupField', 'Tabs', 'ProgressBar', 'NavBar', 'OverlayPanel', 'AstroProvider', 'ListView', 'NavigationHeader', 'Avatar', 'MultivaluesField', 'Text', 'Link', 'Card', 'IconWrapper', 'ComboBoxField', 'CodeView', 'Sticker Sheet', 'NextGen ListViewItem', 'Skeleton', 'Pagination'];
|
1
|
+
var nextGenConvertedComponents = ['DataTable', 'Message', 'Button', 'Badge', 'IconButton', 'CheckboxField', 'Messages', 'PopoverMenu', 'TextField', 'PasswordField', 'SearchField', 'SelectField', 'Modal', 'RadioField', 'MultiValuesField', 'TextAreaField', 'RadioGroupField', 'Tabs', 'ProgressBar', 'NavBar', 'OverlayPanel', 'AstroProvider', 'ListView', 'NavigationHeader', 'Avatar', 'MultivaluesField', 'Text', 'Link', 'Card', 'IconWrapper', 'ComboBoxField', 'CodeView', 'Sticker Sheet', 'NextGen ListViewItem', 'Skeleton', 'ListViewItem', 'Pagination'];
|
2
2
|
export var componentSpecificNextGenBlacklist = {
|
3
3
|
AstroProvider: ['Default', 'With Custom Theme Override'],
|
4
4
|
Badge: ['Status Badge Variants', 'Badge With Left Slot And Icon', 'Callout Badges', 'Removable'],
|
@@ -5,10 +5,11 @@ import AlertOutlineIcon from '@pingux/mdi-react/AlertOutlineIcon';
|
|
5
5
|
import CheckCircleOutlineIcon from '@pingux/mdi-react/CheckCircleOutlineIcon';
|
6
6
|
import ChevronDownIcon from '@pingux/mdi-react/ChevronDownIcon';
|
7
7
|
import ChevronUpIcon from '@pingux/mdi-react/ChevronUpIcon';
|
8
|
+
import DotsHorizontalIcon from '@pingux/mdi-react/DotsHorizontalIcon';
|
8
9
|
import InformationOutlineIcon from '@pingux/mdi-react/InformationOutlineIcon';
|
9
10
|
import { pingLogoHorizontalSmall } from '../../../../utils/devUtils/constants/logos';
|
10
11
|
import statuses from '../../../../utils/devUtils/constants/statuses';
|
11
12
|
export default (_MenuDown$MenuUp$stat = {
|
12
13
|
MenuDown: ChevronDownIcon,
|
13
14
|
MenuUp: ChevronUpIcon
|
14
|
-
}, _defineProperty(_MenuDown$MenuUp$stat, statuses.DEFAULT, InformationOutlineIcon), _defineProperty(_MenuDown$MenuUp$stat, statuses.ERROR, AlertCircleOutlineIcon), _defineProperty(_MenuDown$MenuUp$stat, statuses.SUCCESS, CheckCircleOutlineIcon), _defineProperty(_MenuDown$MenuUp$stat, statuses.WARNING, AlertOutlineIcon), _defineProperty(_MenuDown$MenuUp$stat, "pingLogoHorizontalSmall", pingLogoHorizontalSmall), _MenuDown$MenuUp$stat);
|
15
|
+
}, _defineProperty(_MenuDown$MenuUp$stat, statuses.DEFAULT, InformationOutlineIcon), _defineProperty(_MenuDown$MenuUp$stat, statuses.ERROR, AlertCircleOutlineIcon), _defineProperty(_MenuDown$MenuUp$stat, statuses.SUCCESS, CheckCircleOutlineIcon), _defineProperty(_MenuDown$MenuUp$stat, statuses.WARNING, AlertOutlineIcon), _defineProperty(_MenuDown$MenuUp$stat, "pingLogoHorizontalSmall", pingLogoHorizontalSmall), _defineProperty(_MenuDown$MenuUp$stat, "listViewMenu", DotsHorizontalIcon), _MenuDown$MenuUp$stat);
|
@@ -334,7 +334,18 @@ var iconButtons = {
|
|
334
334
|
'&.is-disabled': {
|
335
335
|
backgroundColor: 'gray-300'
|
336
336
|
}
|
337
|
-
}
|
337
|
+
},
|
338
|
+
searchClearButton: _objectSpread(_objectSpread({}, baseIconButton), {}, {
|
339
|
+
border: 'none',
|
340
|
+
'&.is-hovered': {
|
341
|
+
bg: 'background.hover'
|
342
|
+
},
|
343
|
+
'&.is-pressed': {
|
344
|
+
bg: 'background.hover'
|
345
|
+
},
|
346
|
+
position: 'absolute',
|
347
|
+
right: 10
|
348
|
+
})
|
338
349
|
};
|
339
350
|
var buttons = {
|
340
351
|
neutral: neutral,
|