Sha256: 68ae73a44775d53a71cf52c36096b9c7b403a7a9b53fe335ca5dec75d5cf3b16

Contents?: true

Size: 513 Bytes

Versions: 10

Compression:

Stored size: 513 Bytes

Contents

import Split from "split-grid";

export default function (element, props) {
  Split({
    [`${props.direction === "vertical" ? "row" : "column"}Gutters`]: [
      { track: 1, element },
    ],
    minSize: props.minSize,
    writeStyle() {},
    onDrag(dir, track, style) {
      const splits = style.split(" ").map((num) => parseInt(num));
      props.onDrag(splits);
    },
    // onDragStart() {
    //   this.reflowing = true;
    // },
    // onDragEnd() {
    //   this.reflowing = false;
    // },
  });
}

Version data entries

10 entries across 10 versions & 1 rubygems

Version Path
lookbook-0.6.1 app/assets/lookbook/js/lib/split.js
lookbook-0.6.0 app/assets/lookbook/js/lib/split.js
lookbook-0.5.2 app/assets/lookbook/js/lib/split.js
lookbook-0.5.1 app/assets/lookbook/js/lib/split.js
lookbook-0.5.0 app/assets/lookbook/js/lib/split.js
lookbook-0.5.0.beta.2 app/assets/lookbook/js/lib/split.js
lookbook-0.5.0.beta.1 app/assets/lookbook/js/lib/split.js
lookbook-0.5.0.beta.0 app/assets/lookbook/js/lib/split.js
lookbook-0.4.8 app/assets/lookbook/js/lib/split.js
lookbook-0.4.7 app/assets/lookbook/js/lib/split.js