@dataloop-ai/components 0.20.286 → 0.20.287

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/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@dataloop-ai/components",
3
- "version": "0.20.286",
3
+ "version": "0.20.287",
4
4
  "exports": {
5
5
  ".": "./index.ts",
6
6
  "./models": "./models.ts",
@@ -611,9 +611,8 @@ export default defineComponent({
611
611
  row,
612
612
  rowIndex: index,
613
613
  rowKey: props.rowKey,
614
- isRowSelected: isRowSelected(props.rowKey, getRowKey.value(row))
615
- ? 'selected'
616
- : '',
614
+ isRowSelected:
615
+ isRowSelected(props.rowKey, getRowKey.value(row)) === true,
617
616
  isRowHighlighted:
618
617
  props.highlightedRow &&
619
618
  (typeof props.rowKey === 'string'
@@ -1,6 +1,9 @@
1
1
  <template>
2
2
  <DlTrTree
3
- :class="rowClass()"
3
+ :class="{
4
+ 'dl-tr--selected': isRowSelected,
5
+ highlighted: isRowHighlighted
6
+ }"
4
7
  :no-hover="noHover"
5
8
  :children="childrenCount"
6
9
  :props="{ row }"
@@ -10,15 +13,13 @@
10
13
  @mouseenter="onRowHoverStart($event, row, rowIndex)"
11
14
  @mouseleave="onRowHoverEnd($event, row, rowIndex)"
12
15
  >
13
- <td
14
- :style="`opacity: ${
15
- isDragIconVisible || isRowHighlighted ? '1' : '0'
16
- }`"
17
- class="dl-draggable-container"
18
- >
16
+ <td class="dl-draggable-container">
19
17
  <dl-icon
20
18
  v-if="hasDraggableRows && !row.disableDraggable"
21
19
  class="draggable-icon"
20
+ :style="`opacity: ${
21
+ isDragIconVisible || isRowHighlighted ? '1' : '0'
22
+ }`"
22
23
  icon="icon-dl-drag"
23
24
  size="12px"
24
25
  :color="
@@ -138,8 +139,8 @@ export default defineComponent({
138
139
  type: [String, Function]
139
140
  },
140
141
  isRowSelected: {
141
- type: [Boolean, String],
142
- default: null
142
+ type: Boolean,
143
+ default: false
143
144
  },
144
145
  hasAnyAction: {
145
146
  type: Boolean,
@@ -342,12 +343,6 @@ export default defineComponent({
342
343
  : 'body-cell'
343
344
  }
344
345
 
345
- const rowClass = (): string => {
346
- if (props.isRowHighlighted) {
347
- return 'highlighted'
348
- }
349
- }
350
-
351
346
  const getExpandedvisibleChildren = (): void => {
352
347
  visibleChildren.value = 1
353
348
  updateExpandedvisibleChildren(row.value)
@@ -419,7 +414,6 @@ export default defineComponent({
419
414
  emitUpdateExpandedRow,
420
415
  getCellValue,
421
416
  hasSlotByName,
422
- rowClass,
423
417
  getSlotByName,
424
418
  getExpandedvisibleChildren,
425
419
  updateExpandedvisibleChildren,
@@ -456,4 +450,14 @@ export default defineComponent({
456
450
  .dl-draggable-container {
457
451
  width: 25px;
458
452
  }
453
+ .dl-table tbody tr.dl-tr--selected td {
454
+ background-color: var(--dell-blue-100);
455
+ }
456
+ .dl-table--horizontal-separator,
457
+ .dl-table--cell-separator {
458
+ .dl-table tbody tr.dl-tr > td {
459
+ border-bottom-width: 0;
460
+ box-shadow: inset 0 -1px 0 var(--dell-gray-300);
461
+ }
462
+ }
459
463
  </style>