@linzjs/step-ag-grid 31.2.2 → 31.2.4
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/README.md +2 -1
- package/dist/GridTheme.scss +5 -1
- package/dist/src/lui/ActionButton.d.ts +2 -1
- package/dist/step-ag-grid.cjs +2 -2
- package/dist/step-ag-grid.cjs.map +1 -1
- package/dist/step-ag-grid.esm.js +2 -2
- package/dist/step-ag-grid.esm.js.map +1 -1
- package/package.json +2 -2
- package/src/lui/ActionButton.tsx +3 -0
- package/src/styles/GridTheme.scss +5 -1
package/README.md
CHANGED
|
@@ -199,7 +199,7 @@ If you are editing a cell and tab out of the cell, the grid will edit the next e
|
|
|
199
199
|
|
|
200
200
|
At this point you can send the change to the back-end immediately and then wait for an update response
|
|
201
201
|
_OR_
|
|
202
|
-
you could cache the required change, update then cell locally, and then wait for the callback
|
|
202
|
+
you could cache the required change, update then cell locally, and then wait for the callback.
|
|
203
203
|
```<Grid onCellEditingComplete={fn}/>``` which will get invoked when the grid cannot find any
|
|
204
204
|
more editable cells on the grid row, which will speed up editing.
|
|
205
205
|
|
|
@@ -270,6 +270,7 @@ test("click Delete menu option removes row from the table", async () => {
|
|
|
270
270
|
});
|
|
271
271
|
```
|
|
272
272
|
|
|
273
|
+
|
|
273
274
|
## Playwright support
|
|
274
275
|
|
|
275
276
|
If your grid has a data-testid a global will be exposed in window with the helper scrollRowIntoViewById.
|
package/dist/GridTheme.scss
CHANGED
|
@@ -59,7 +59,11 @@ $grid-base-font-size: calc(#{lui.$base-font-size} - 1px);
|
|
|
59
59
|
);
|
|
60
60
|
|
|
61
61
|
.ag-theme-step-view-list-default,
|
|
62
|
-
.ag-theme-step-default.theme-specific
|
|
62
|
+
.ag-theme-step-default.theme-specific {
|
|
63
|
+
.ag-tooltip {
|
|
64
|
+
background-color: white !important;
|
|
65
|
+
}
|
|
66
|
+
}
|
|
63
67
|
.ag-theme-step-compact.theme-specific {
|
|
64
68
|
// Don't hide the drag handle
|
|
65
69
|
.ag-drag-handle.ag-row-drag {
|
|
@@ -14,7 +14,8 @@ export interface ActionButtonProps {
|
|
|
14
14
|
className?: 'ActionButton-fill' | 'ActionButton-tight' | string;
|
|
15
15
|
onClick: () => Promise<void> | void;
|
|
16
16
|
level?: LuiButtonProps['level'];
|
|
17
|
+
intent?: LuiButtonProps['intent'];
|
|
17
18
|
style?: CSSProperties;
|
|
18
19
|
disabled?: boolean;
|
|
19
20
|
}
|
|
20
|
-
export declare const ActionButton: ({ icon, name, inProgressName, disabled, dataTestId, style, className, title, onClick, size, iconPosition, level, "aria-label": ariaLabel, }: ActionButtonProps) => ReactElement;
|
|
21
|
+
export declare const ActionButton: ({ icon, name, inProgressName, disabled, dataTestId, style, className, title, onClick, size, iconPosition, level, intent, "aria-label": ariaLabel, }: ActionButtonProps) => ReactElement;
|
package/dist/step-ag-grid.cjs
CHANGED
|
@@ -64867,7 +64867,7 @@ styleInject(css_248z);
|
|
|
64867
64867
|
|
|
64868
64868
|
// Kept this less than one second, so I don't have issues with waitFor as it defaults to 1s
|
|
64869
64869
|
const minimumInProgressTimeMs = 950;
|
|
64870
|
-
const ActionButton = ({ icon, name, inProgressName, disabled, dataTestId, style, className, title, onClick, size = 'sm', iconPosition = 'left', level = 'tertiary', 'aria-label': ariaLabel, }) => {
|
|
64870
|
+
const ActionButton = ({ icon, name, inProgressName, disabled, dataTestId, style, className, title, onClick, size = 'sm', iconPosition = 'left', level = 'tertiary', intent, 'aria-label': ariaLabel, }) => {
|
|
64871
64871
|
const [inProgress, setInProgress] = React13.useState(false);
|
|
64872
64872
|
const lastInProgress = usePrevious(inProgress ?? false);
|
|
64873
64873
|
const [localInProgress, setLocalInProgress, setLocalInProgressDeferred] = useStateDeferred(inProgress);
|
|
@@ -64882,7 +64882,7 @@ const ActionButton = ({ icon, name, inProgressName, disabled, dataTestId, style,
|
|
|
64882
64882
|
}
|
|
64883
64883
|
}, [inProgress, lastInProgress, setLocalInProgress, setLocalInProgressDeferred]);
|
|
64884
64884
|
const buttonText = (jsxRuntime.jsxs("span", { className: 'ActionButton-minimalArea', children: [jsxRuntime.jsx("span", { className: 'ActionButton-minimalAreaDisplay', children: (localInProgress ? inProgressName : name) ?? name }), jsxRuntime.jsx("span", { className: 'ActionButton-minimalAreaExpand', children: name })] }));
|
|
64885
|
-
return (jsxRuntime.jsxs(lui.LuiButton, { "data-testid": dataTestId, type: 'button', level: level, title: title ?? ariaLabel ?? name, buttonProps: { 'aria-label': ariaLabel ?? name }, className: clsx('lui-button-icon-right', 'ActionButton', className, localInProgress && 'ActionButton-inProgress', name != null && !className?.includes('ActionButton-fill') && 'ActionButton-minimal', name == null && 'ActionButton-iconOnly'), size: 'lg', style: style, onClick: () => {
|
|
64885
|
+
return (jsxRuntime.jsxs(lui.LuiButton, { "data-testid": dataTestId, type: 'button', level: level, intent: intent, title: title ?? ariaLabel ?? name, buttonProps: { 'aria-label': ariaLabel ?? name }, className: clsx('lui-button-icon-right', 'ActionButton', className, localInProgress && 'ActionButton-inProgress', name != null && !className?.includes('ActionButton-fill') && 'ActionButton-minimal', name == null && 'ActionButton-iconOnly'), size: 'lg', style: style, onClick: () => {
|
|
64886
64886
|
const promise = onClick();
|
|
64887
64887
|
const isPromise = typeof promise !== 'undefined';
|
|
64888
64888
|
if (isPromise) {
|