flameresttable 1.0.60 → 1.0.62

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.
Files changed (2) hide show
  1. package/package.json +1 -1
  2. package/src/Table/Table.vue +13 -11
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "flameresttable",
3
- "version": "1.0.60",
3
+ "version": "1.0.62",
4
4
  "main": "./src/plugin.ts",
5
5
  "repository": {
6
6
  "type": "git",
@@ -24,29 +24,32 @@
24
24
  <!--<div>-->
25
25
 
26
26
  <!-- ЧЕКБОКСЫ -->
27
- <div class="w-[21px] align-middle col-span-1">
27
+ <div class="w-[21px] align-middle col-span-1" :style="'grid-column:' + 0">
28
28
  <label class="checkbox" v-if="Table.opts.rowSelectors">
29
29
  <input type='checkbox' @change="CheckboxSelectionChanged($event, true)">
30
30
  <span class='indicator'></span>
31
31
  </label>
32
32
  </div>
33
33
 
34
- <template v-for="column in Table.columns">
34
+
35
+ <template v-for="(column, key, index) in Table.columns">
35
36
  <div v-if="column.Table.isShow" :key="'cheader_' + column.name"
36
37
  :class="' defaultHeader ' + column.Table.classesHeader"
37
- class=" col-span-1 align-middle border-r border-r-slate-100 px-2">
38
+ class=" col-span-1 align-middle border-r border-r-slate-100 px-2" :style="'grid-column:' + (index + 2)">
38
39
  <span>{{ column.Table.titleCustom !== null ? (column as any).Table.titleCustom(column) : column.Table.title !==
39
40
  '' ?
40
41
  column.Table.title : column.title !== '' ? column.title :
41
42
  column.name }}</span>
42
43
  </div>
43
44
  </template>
44
- <div v-if="opts.Edit.can" class=" col-span-1 border-r border-r-slate-100 px-2">
45
- <button class="bg-green-600 invisible">
45
+ <div v-if="opts.Edit.can" class=" col-span-1 border-r border-r-slate-100 px-2"
46
+ :style="'grid-column:' + (columnCount() - 1)">
47
+ <button class=" bg-green-600 invisible">
46
48
 
47
49
  </button>
48
50
  </div>
49
- <div v-if="opts.Remove.can" class=" col-span-1 border-r border-r-slate-100 px-2">
51
+ <div v-if="opts.Remove.can" class=" col-span-1 border-r border-r-slate-100 px-2"
52
+ :style="'grid-column:' + (columnCount())">
50
53
  <button class="bg-green-600 invisible">
51
54
 
52
55
  </button>
@@ -54,7 +57,7 @@
54
57
  <!--</div>-->
55
58
 
56
59
  <!-- СТРОКИ-->
57
- <template v-for="(row) in (Table.Rows.rows)">
60
+ <template v-for="( row ) in (Table.Rows.rows) ">
58
61
  <template v-if="true">
59
62
 
60
63
  <!-- ЧЕКБОКСЫ -->
@@ -67,7 +70,7 @@
67
70
  </label>
68
71
  </div>
69
72
 
70
- <template v-for="column in Table.columns">
73
+ <template v-for=" column in Table.columns ">
71
74
  <div v-if="column.Table.isShow" :key="'tc_' + column.name + '_row_' + (row as any).id"
72
75
  :class="' defaultCell ' + column.Table.classes"
73
76
  class=" col-span-1 align-middle border-r border-r-slate-100 px-2 last:border-r-0 last:pr-0"
@@ -122,7 +125,7 @@
122
125
  <slot name="header" />
123
126
 
124
127
  <!-- КОЛОНКИ ТАБЛИЦЫ-->
125
- <label v-for="column in ColumnNames" v-show="Table.columns[column].Popup.isShow" :key="'c' + column"
128
+ <label v-for=" column in ColumnNames " v-show="Table.columns[column].Popup.isShow" :key="'c' + column"
126
129
  class="flex items-stretch justify-center w-full my-1 ml-2">
127
130
 
128
131
  <!-- Заголовок -->
@@ -149,7 +152,7 @@
149
152
  <div v-if="Table.columns[column].Popup.popupType === 'selector'"
150
153
  class="flex-1 mr-5 w-full flex flex-col self-stretch"><select v-model="Table.columns[column].Popup.model"
151
154
  class="h-full self-stretch py-1 px-2 w-full outline-none border border-slate-100">
152
- <option v-for="(selectorVal, selectorKey) in Table.columns[column].Popup.Selector.values"
155
+ <option v-for="( selectorVal, selectorKey ) in Table.columns[column].Popup.Selector.values "
153
156
  :key="'sel_' + selectorKey"
154
157
  :value="getSelector(Table.columns[column].Popup.Selector.values, selectorKey, selectorVal)[1]">{{
155
158
  getSelector(Table.columns[column].Popup.Selector.values, selectorKey, selectorVal)[0] }}</option>
@@ -454,7 +457,6 @@ export default defineComponent({
454
457
  <style scoped lang="scss">
455
458
  .grid-container {
456
459
  display: grid;
457
- grid-template-columns: repeat(var(--column-count), 1fr);
458
460
  }
459
461
 
460
462
  .no-wrap-cell {