vueless 0.0.205 → 0.0.207

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": "vueless",
3
- "version": "0.0.205",
3
+ "version": "0.0.207",
4
4
  "license": "MIT",
5
5
  "description": "Vue Styleless Component Framework.",
6
6
  "homepage": "https://vueless.com",
@@ -43,7 +43,7 @@
43
43
 
44
44
  <div v-if="value?.hasOwnProperty('secondary')">
45
45
  <slot :name="`cell-${key}`" :value="value" :row="row">
46
- <div :data-cy="`${dataCy}-${key}-cell`">
46
+ <div :data-cy="`${dataCy}-${key}-cell`" v-bind="attrs.bodyCellPrimaryAttrs">
47
47
  {{ value.primary || HYPHEN_SYMBOL }}
48
48
  </div>
49
49
 
@@ -114,6 +114,7 @@ export function useAttrs(
114
114
  const bodyRowBeforeCellAttrsRaw = getAttrs("bodyRowBeforeCell");
115
115
  const bodyRowAfterAttrs = getAttrs("bodyRowAfter");
116
116
  const bodyRowAfterCellAttrsRaw = getAttrs("bodyRowAfterCell");
117
+ const bodyCellPrimaryAttrs = getAttrs("bodyCellPrimary");
117
118
 
118
119
  const bodyRowAttrsRaw = getAttrs("bodyRow");
119
120
 
@@ -259,5 +260,6 @@ export function useAttrs(
259
260
  stickyFooterRowAttrs,
260
261
  hasSlotContent,
261
262
  headerAttrs,
263
+ bodyCellPrimaryAttrs,
262
264
  };
263
265
  }
@@ -26,7 +26,7 @@ export default /*tw*/ {
26
26
  stickyHeaderActionsCheckbox: "",
27
27
  stickyHeaderActionsCounter: "-ml-2",
28
28
  tableWrapper: "border border-gray-200 rounded-lg bg-white",
29
- table: "min-w-full border-none text-sm w-full",
29
+ table: "min-w-full border-none text-sm w-full table-fixed",
30
30
  header: "border-b border-gray-200",
31
31
  headerRow: "",
32
32
  headerCell: "",
@@ -57,7 +57,8 @@ export default /*tw*/ {
57
57
  },
58
58
  },
59
59
  },
60
- bodyCellSecondary: "mt-1 text-xs text-gray-500",
60
+ bodyCellPrimary: "text-ellipsis overflow-hidden",
61
+ bodyCellSecondary: "mt-1 text-xs text-gray-500 overflow-hidden text-ellipsis",
61
62
  bodyCellSecondaryEmpty: "inline-block",
62
63
  bodyCellCheckbox: "first:px-4", // try to remove first
63
64
  bodyCellDateSeparator: "",
@@ -169,6 +169,7 @@
169
169
  bodyCellNestedCollapseIconAttrs,
170
170
  bodyCellNestedExpandIconAttrs,
171
171
  bodyCellNestedAttrs,
172
+ bodyCellPrimaryAttrs,
172
173
  }"
173
174
  @click="onClickRow"
174
175
  @toggle-row-visibility="onToggleRowVisibility"
@@ -469,6 +470,7 @@ const {
469
470
  stickyFooterRowAttrs,
470
471
  hasSlotContent,
471
472
  headerAttrs,
473
+ bodyCellPrimaryAttrs,
472
474
  } = useAttrs(props, {
473
475
  tableRows,
474
476
  isShownActionsHeader,
@@ -93,7 +93,7 @@ export default class SelectService {
93
93
  return this.getGroupOption(item, options, groupValueKey, valueKey);
94
94
  }
95
95
 
96
- const value = item[valueKey] || item;
96
+ const value = (item && item[valueKey]) || item;
97
97
 
98
98
  return options.find((option) => option[valueKey] === value);
99
99
  }
package/web-types.json CHANGED
@@ -1,7 +1,7 @@
1
1
  {
2
2
  "framework": "vue",
3
3
  "name": "vueless",
4
- "version": "0.0.205",
4
+ "version": "0.0.207",
5
5
  "contributions": {
6
6
  "html": {
7
7
  "description-markup": "markdown",