schummar-table 0.46.6 → 0.46.8

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/dist/index.js CHANGED
@@ -3042,13 +3042,7 @@ import { useEffect as useEffect8 } from "react";
3042
3042
  function filterColumns(state) {
3043
3043
  useEffect8(
3044
3044
  () => state.addReaction(
3045
- (state2) => [
3046
- state2.props.columns,
3047
- state2.hiddenColumns,
3048
- state2.columnOrder,
3049
- state2.displaySize,
3050
- state2.displaySizePx
3051
- ],
3045
+ (state2) => [state2.props.columns, state2.hiddenColumns, state2.columnOrder, state2.displaySize],
3052
3046
  ([columns, hiddenColumns, columnOrder, displaySize], draft) => {
3053
3047
  draft.activeColumns = orderBy(
3054
3048
  columns.filter((column) => {
@@ -3659,7 +3653,7 @@ function ColumnHeader({ index }) {
3659
3653
  defaultClasses.headerCell,
3660
3654
  {
3661
3655
  gridRow: 1,
3662
- gridColumn: index + 2,
3656
+ gridColumn: index + 3,
3663
3657
  position: "relative",
3664
3658
  userSelect: "none"
3665
3659
  },
@@ -3699,7 +3693,11 @@ function ColumnSelection() {
3699
3693
  const cssVariables = useCssVariables();
3700
3694
  const table = useTableContext();
3701
3695
  const reset = useContext7(TableResetContext);
3702
- const columns = table.useState((state) => state.props.columns);
3696
+ const columns = table.useState(
3697
+ (state) => state.props.columns.filter(
3698
+ (column) => state.displaySize === void 0 || column.displaySize === void 0 || column.displaySize.includes(state.displaySize)
3699
+ )
3700
+ );
3703
3701
  const hiddenColumns = table.useState((state) => state.hiddenColumns);
3704
3702
  const [anchorElement, setAnchorElement] = useState12(null);
3705
3703
  const toggle2 = (column, state) => {