@linzjs/step-ag-grid 17.4.5 → 17.4.7

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.
@@ -47,98 +47,150 @@ $grid-base-font-size: calc(#{lui.$base-font-size} - 1px);
47
47
  )
48
48
  );
49
49
 
50
+ .ag-theme-step-default,
51
+ .ag-theme-step-compact {
52
+ .ag-cell[col-id="selection"] {
53
+ display: flex; // Fix that when you click below checkbox it doesn't process a click
54
+ }
50
55
 
51
- .ag-cell[col-id="selection"] {
52
- display: flex;// Fix that when you click below checkbox it doesn't process a click
53
- }
56
+ // fix alignment of cell content when grabber is present
57
+ .ag-header-cell-comp-wrapper {
58
+ justify-content: end;
59
+ }
54
60
 
55
- // fix alignment of cell content when grabber is present
56
- .ag-header-cell-comp-wrapper {
57
- justify-content: end;
58
- }
61
+ // Fix that when you click below checkbox it doesn't process a click
62
+ .ag-cell-wrapper > *:not(.ag-cell-value, .ag-group-value) {
63
+ height: auto;
64
+ }
59
65
 
60
- // Fix that when you click below checkbox it doesn't process a click
61
- .ag-cell-wrapper > *:not(.ag-cell-value, .ag-group-value) {
62
- height: auto;
63
- }
66
+ .ag-row:last-of-type {
67
+ border-bottom: 1px solid lui.$dew;
68
+ }
64
69
 
65
- .ag-row:last-of-type {
66
- border-bottom: 1px solid lui.$dew;
67
- }
70
+ .ag-header-cell {
71
+ font-size: 14px;
72
+ font-weight: 600;
73
+
74
+ // fix: Display descender line
75
+ padding: 0 11px;
68
76
 
69
- .ag-header-cell {
70
- font-size: 14px;
71
- font-weight: 600;
77
+ .LuiIcon {
78
+ fill: lui.$surfie;
79
+ }
80
+ }
72
81
 
73
- // fix: Display descender line
74
- padding: 0 11px;
82
+ .ag-cell-label-container {
83
+ padding: 8px 0;
75
84
 
76
- .LuiIcon {
77
- fill: lui.$surfie;
85
+ // Help ag-grid to calculate column height in react portal
86
+ height: fit-content;
78
87
  }
79
- }
80
88
 
81
- .ag-cell-label-container {
82
- padding: 8px 0;
89
+ .ag-header .ag-header-cell[aria-colindex="1"] {
90
+ padding-left: 17px;
91
+ padding-right: 15px;
92
+ }
83
93
 
84
- // Help ag-grid to calculate column height in react portal
85
- height: fit-content;
86
- }
94
+ .ag-cell[role="gridcell"] {
95
+ border-right: none;
96
+ border-left: 1px var(--ag-cell-horizontal-border);
97
+ }
87
98
 
88
- .ag-header .ag-header-cell[aria-colindex="1"] {
89
- padding-left: 17px;
90
- padding-right: 15px;
91
- }
99
+ .ag-cell[aria-colindex="1"] {
100
+ border-left: 1px solid transparent;
101
+ padding-left: lui.$unit-rg;
102
+ }
92
103
 
93
- .ag-cell[role="gridcell"] {
94
- border-right: none;
95
- border-left: 1px var(--ag-cell-horizontal-border);
96
- }
104
+ .ag-cell {
105
+ padding-left: 11px;
106
+ padding-right: 11px;
107
+ display: flex;
108
+ align-items: center;
109
+ }
97
110
 
98
- .ag-cell[aria-colindex="1"] {
99
- border-left: 1px solid transparent;
100
- padding-left: lui.$unit-rg;
101
- }
111
+ .ag-cell-wrap-text {
112
+ word-break: break-word;
113
+ }
102
114
 
103
- .ag-cell {
104
- padding-left: 11px;
105
- padding-right: 11px;
106
- display: flex;
107
- align-items: center;
108
- }
115
+ .ag-cell.ag-cell-popup-editing,
116
+ .ag-cell.ag-selected-for-edit,
117
+ .ag-cell-inline-editing {
118
+ padding-left: 9px;
119
+ padding-right: 9px;
120
+ background: rgb(72 160 244 / 20%);
109
121
 
110
- .ag-cell-wrap-text {
111
- word-break: break-word;
112
- }
122
+ // These are important, it needs to override ag-grid to work
123
+ border: 3px solid #48a0f4 !important;
124
+ border-right: 3px solid #48a0f4 !important;
125
+ }
113
126
 
114
- .ag-cell.ag-cell-popup-editing,
115
- .ag-cell.ag-selected-for-edit,
116
- .ag-cell-inline-editing {
117
- padding-left: 9px;
118
- padding-right: 9px;
119
- background: rgb(72 160 244 / 20%);
127
+ .ag-row .ag-cell-data-changed {
128
+ // ag-grid natively has !important on this style so we have to use it here :(
129
+ background-color: lightgoldenrodyellow;
130
+ }
120
131
 
121
- // These are important, it needs to override ag-grid to work
122
- border: 3px solid #48a0f4 !important;
123
- border-right: 3px solid #48a0f4 !important;
124
- }
132
+ .ag-center-cols-clipper {
133
+ // when using domLayout={"autoHeight"}, ag grid has a default min-height
134
+ // set to 150px so the !important is necessary here
135
+ min-height: 40px !important;
136
+ }
125
137
 
126
- .ag-row .ag-cell-data-changed {
127
- // ag-grid natively has !important on this style so we have to use it here :(
128
- background-color: lightgoldenrodyellow;
129
- }
138
+ .ag-body-horizontal-scroll-viewport {
139
+ // It's set to scroll by default, but this causes issues with selecting the last row
140
+ overflow-x: auto;
141
+ }
130
142
 
131
- .ag-center-cols-clipper {
132
- // when using domLayout={"autoHeight"}, ag grid has a default min-height
133
- // set to 150px so the !important is necessary here
134
- min-height: 40px !important;
135
- }
143
+ .ag-cell {
144
+ font-weight: 400;
145
+ }
136
146
 
137
- .ag-body-horizontal-scroll-viewport {
138
- // It's set to scroll by default, but this causes issues with selecting the last row
139
- overflow-x: auto;
140
- }
147
+ .ag-cell-value {
148
+ display: flex;
149
+ align-items: center;
150
+ }
151
+
152
+ .ag-cell .GridCell-editableIcon {
153
+ fill: lui.$silver;
154
+ visibility: hidden;
155
+ }
156
+
157
+ .ag-cell:hover .GridCell-editableIcon,
158
+ .ag-cell.ag-cell-focus .GridCell-editableIcon {
159
+ visibility: visible;
160
+ }
161
+
162
+ .ag-drag-handle.ag-row-drag {
163
+ opacity: 0;
141
164
 
142
- .Grid-container .ag-cell {
143
- font-weight: 400;
144
- }
165
+ .ag-icon-grip {
166
+ background-image: url("data:image/svg+xml,%3Csvg viewBox='0 0 24 24' fill='%239999B3' xmlns='http://www.w3.org/2000/svg'%3E%3Cpath d='M11 18c0 1.1-.9 2-2 2s-2-.9-2-2 .9-2 2-2 2 .9 2 2Zm-2-8c-1.1 0-2 .9-2 2s.9 2 2 2 2-.9 2-2-.9-2-2-2Zm0-6c-1.1 0-2 .9-2 2s.9 2 2 2 2-.9 2-2-.9-2-2-2Zm6 4c1.1 0 2-.9 2-2s-.9-2-2-2-2 .9-2 2 .9 2 2 2Zm0 2c-1.1 0-2 .9-2 2s.9 2 2 2 2-.9 2-2-.9-2-2-2Zm0 6c-1.1 0-2 .9-2 2s.9 2 2 2 2-.9 2-2-.9-2-2-2Z' /%3E%3C/svg%3E");
167
+ background-repeat: no-repeat no-repeat;
168
+ background-position: center center;
169
+ background-size: cover;
170
+ color: transparent;
171
+ }
172
+ }
173
+
174
+ .ag-row:hover {
175
+ .ag-drag-handle.ag-row-drag {
176
+ opacity: 1;
177
+ transition: opacity 0.2s ease-in-out;
178
+ }
179
+ }
180
+
181
+ .GridCell-readonly {
182
+ color: lui.$fuscous;
183
+ }
184
+
185
+ .ag-cell:not(.ag-cell-focus) .Grid-displayWhenCellFocused {
186
+ visibility: hidden;
187
+ }
188
+
189
+ .ag-cell:hover .Grid-displayWhenCellFocused {
190
+ visibility: inherit;
191
+ }
192
+
193
+ .ag-cell-wrapper {
194
+ width: 100%;
195
+ }
196
+ }
package/dist/index.css CHANGED
@@ -383,57 +383,6 @@
383
383
  padding: 0.375rem 0.75rem;
384
384
  }
385
385
 
386
- .ag-cell-value {
387
- display: flex;
388
- align-items: center;
389
- }
390
-
391
- .ag-cell .GridCell-editableIcon {
392
- fill: #beb9b4;
393
- visibility: hidden;
394
- }
395
-
396
- .ag-cell:hover .GridCell-editableIcon, .ag-cell.ag-cell-focus .GridCell-editableIcon {
397
- visibility: visible;
398
- }
399
-
400
- .ag-drag-handle.ag-row-drag {
401
- opacity: 0;
402
- }
403
- .ag-drag-handle.ag-row-drag .ag-icon-grip {
404
- background-image: url("data:image/svg+xml,%3Csvg viewBox='0 0 24 24' fill='%239999B3' xmlns='http://www.w3.org/2000/svg'%3E%3Cpath d='M11 18c0 1.1-.9 2-2 2s-2-.9-2-2 .9-2 2-2 2 .9 2 2Zm-2-8c-1.1 0-2 .9-2 2s.9 2 2 2 2-.9 2-2-.9-2-2-2Zm0-6c-1.1 0-2 .9-2 2s.9 2 2 2 2-.9 2-2-.9-2-2-2Zm6 4c1.1 0 2-.9 2-2s-.9-2-2-2-2 .9-2 2 .9 2 2 2Zm0 2c-1.1 0-2 .9-2 2s.9 2 2 2 2-.9 2-2-.9-2-2-2Zm0 6c-1.1 0-2 .9-2 2s.9 2 2 2 2-.9 2-2-.9-2-2-2Z' /%3E%3C/svg%3E");
405
- background-repeat: no-repeat no-repeat;
406
- background-position: center center;
407
- background-size: cover;
408
- color: transparent;
409
- }
410
-
411
- .ag-row:hover .ag-drag-handle.ag-row-drag {
412
- opacity: 1;
413
- transition: opacity 0.2s ease-in-out;
414
- }
415
-
416
- .GridFormMessage-container {
417
- padding: 4px 8px;
418
- max-width: 400px;
419
- }
420
-
421
- .GridCell-readonly {
422
- color: #6b6966;
423
- }
424
-
425
- .Grid-container.ag-theme-alpine .ag-cell:not(.ag-cell-focus) .Grid-displayWhenCellFocused {
426
- visibility: hidden;
427
- }
428
-
429
- .Grid-container.ag-theme-alpine .ag-cell:hover .Grid-displayWhenCellFocused {
430
- visibility: inherit;
431
- }
432
-
433
- .Grid-container.ag-theme-alpine .ag-cell-wrapper {
434
- width: 100%;
435
- }
436
-
437
386
  .flex-col-center {
438
387
  display: flex;
439
388
  flex-direction: column;
@@ -446,6 +395,11 @@
446
395
  align-items: center;
447
396
  }
448
397
 
398
+ .GridFormMessage-container {
399
+ padding: 4px 8px;
400
+ max-width: 400px;
401
+ }
402
+
449
403
  .GridCell-container {
450
404
  overflow: hidden;
451
405
  text-overflow: ellipsis;
@@ -25593,7 +25593,16 @@ const findRow = async (rowId, within) => {
25593
25593
  await waitForWrapper(async () => {
25594
25594
  expect(getAllQuick({ classes: ".ag-row" }).length > 0).toBe(true);
25595
25595
  });
25596
- return await findQuick({ tagName: `div[row-id='${rowId}']:not(:empty)` }, within);
25596
+ //if this is not wrapped in an act console errors are logged during testing
25597
+ let row;
25598
+ await act(async () => {
25599
+ row = await findQuick({ tagName: `.ag-center-cols-container div[row-id='${rowId}']:not(:empty)` }, within);
25600
+ const leftCols = await findQuick({ tagName: `.ag-pinned-left-cols-container div[row-id='${rowId}']` }, within);
25601
+ const rightCols = await findQuick({ tagName: `.ag-pinned-right-cols-container div[row-id='${rowId}']` }, within);
25602
+ const combineChildren = [...leftCols.children, ...row.children, ...rightCols.children];
25603
+ row.replaceChildren(...combineChildren);
25604
+ });
25605
+ return row;
25597
25606
  };
25598
25607
  const queryRow = async (rowId, within) => {
25599
25608
  return queryQuick({ tagName: `div[row-id='${rowId}']:not(:empty)` }, within);