@everchron/ec-shards 5.0.64 → 5.0.65

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": "@everchron/ec-shards",
3
- "version": "5.0.64",
3
+ "version": "5.0.65",
4
4
  "private": false,
5
5
  "description": "Everchron Shards UI Library",
6
6
  "repository": "https://github.com/everchron/ec-shards.git",
@@ -1,7 +1,7 @@
1
1
  <template>
2
2
  <div class="ecs-data-grid-head-cell" :style="[fixedStyles]" :class="[fixedLeft ? 'fixed-left' : '', fixedLeftLast ? 'fixed-left-last' : '', fixedRight ? 'fixed-right' : '']">
3
3
  <div v-if="fixedRight" class="shadow" :class="fixedRight ? 'left' : ''" />
4
- <div ref="resizer" class="ecs-data-grid-head-cell-inner" :style="[widthStyles, paddingStyles, resizeStyles]" :class="resizable ? 'resizable' : ''" :data-column="computedId" :data-test="computedId">
4
+ <div ref="resizer" class="ecs-data-grid-head-cell-inner" :style="[widthStyles, paddingStyles, resizeStyles]" :class="resizable ? 'resizable' : ''" :data-column="computedId" :data-headname="uniformName" :data-test="computedId">
5
5
  <div v-if="firstNonStaticCell" class="first-cell-spacer" />
6
6
  <ecs-icon v-if="icon" :type="icon" size="20" color="#202127" :title="name" />
7
7
  <ecs-select v-else-if="select" @change="$emit('selection', $event.target.value)" type="invisible">
@@ -47,6 +47,10 @@
47
47
  id: {
48
48
  type: String
49
49
  },
50
+ /** To target for resizing headers when multiple instances of same column exist in a table **/
51
+ uniformName: {
52
+ type: String
53
+ },
50
54
  /** Sets the minimum width of the column. It's not possible to set a resize width that's less than the minimum width. */
51
55
  minWidth: {
52
56
  type: Number,
@@ -210,7 +214,9 @@
210
214
  let headName = this.name.toLowerCase().replace(' ', '-')
211
215
  const lastIndex = headName.lastIndexOf('-')
212
216
  headName = headName.substring(0, lastIndex)
213
- let columnHeads = document.querySelectorAll('[data-column="documents-' + headName + '-column-head"]')
217
+ console.log('headName', '[data-headname=documents-' + headName + '-column-head]')
218
+ let columnHeads = document.querySelectorAll('[data-headname="documents-' + headName + '-column-head"]')
219
+ console.log('columnHeads')
214
220
  columnHeads.forEach(cell => {
215
221
  // if (cell.parentElement && cell.parentElement.__vue__ && typeof cell.parentElement.__vue__.setWidth === 'function')
216
222
  // cell.parentElement.__vue__.setWidth(currentColumnWidth)