@itrocks/table 0.0.4 → 0.0.6

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 (3) hide show
  1. package/README.md +3 -2
  2. package/freeze.js +4 -4
  3. package/package.json +1 -1
package/README.md CHANGED
@@ -1,7 +1,8 @@
1
1
  [![view on npm](https://badgen.net/npm/v/@itrocks/table)](https://www.npmjs.org/package/@itrocks/table)
2
2
  [![npm module downloads](https://badgen.net/npm/dt/@itrocks/table)](https://www.npmjs.org/package/@itrocks/table)
3
- [![GitHub repo dependents](https://badgen.net/github/dependents-repo/itrocks-ts/table)](https://github.com/itrocks-ts/table/network/dependents?dependent_type=REPOSITORY)
4
- [![GitHub package dependents](https://badgen.net/github/dependents-pkg/itrocks-ts/table)](https://github.com/itrocks-ts/table/network/dependents?dependent_type=PACKAGE)
3
+ [![GitHub repo dependents](https://badgen.net/github/dependents-repo/itrocks-ts/table?label=dependents)](https://github.com/itrocks-ts/table/network/dependents?dependent_type=REPOSITORY)
4
+ [![Report issues on GitHub](https://badgen.net/github/open-issues/itrocks-ts/table?icon=github)](https://github.com/itrocks-ts/table/issues)
5
+ [![Get support on Discord](https://badgen.net/discord/members/kbMjUq5F?icon=discord)](https://discord.gg/kbMjUq5F)
5
6
 
6
7
  # table
7
8
 
package/freeze.js CHANGED
@@ -49,7 +49,7 @@ export default class TableFreeze extends Plugin {
49
49
  previousBottom = actualBottom;
50
50
  table.styleSheet.push(`
51
51
  ${table.selector} > tfoot > tr:nth-last-child(${counter}) > * {
52
- bottom: ${this.position(bottom, counter, row.firstElementChild, 'bottom')};
52
+ bottom: ${this.position(Math.floor(bottom), counter, row.firstElementChild, 'bottom')};
53
53
  }
54
54
  `);
55
55
  counter++;
@@ -73,7 +73,7 @@ export default class TableFreeze extends Plugin {
73
73
  previousTop = actualTop;
74
74
  table.styleSheet.push(`
75
75
  ${table.selector} > thead > tr:nth-child(${counter}) > * {
76
- top: ${this.position(top, counter, row.firstElementChild, 'top')};
76
+ top: ${this.position(Math.ceil(top), counter, row.firstElementChild, 'top')};
77
77
  }
78
78
  `);
79
79
  counter++;
@@ -99,7 +99,7 @@ export default class TableFreeze extends Plugin {
99
99
  previousLeft = actualLeft;
100
100
  table.styleSheet.push(`
101
101
  ${table.selector} > * > tr > :nth-child(${counter}) {
102
- left: ${this.position(left, counter, colCell, 'left')};
102
+ left: ${this.position(Math.ceil(left), counter, colCell, 'left')};
103
103
  }
104
104
  `);
105
105
  bodySel.push(`${table.selector} > tbody > tr > :nth-child(${counter})`);
@@ -132,7 +132,7 @@ export default class TableFreeze extends Plugin {
132
132
  previousRight = actualRight;
133
133
  table.styleSheet.push(`
134
134
  ${table.selector} > * > tr > :nth-last-child(${counter}) {
135
- right: ${this.position(right, counter, colCell, 'right')};
135
+ right: ${this.position(Math.floor(right), counter, colCell, 'right')};
136
136
  }
137
137
  `);
138
138
  bodySel.push(`${table.selector} > tbody > tr > :nth-last-child(${counter})`);
package/package.json CHANGED
@@ -46,5 +46,5 @@
46
46
  },
47
47
  "type": "module",
48
48
  "types": "./table.d.ts",
49
- "version": "0.0.4"
49
+ "version": "0.0.6"
50
50
  }