Comparing version 0.7.0 to 0.8.0
// Split Layout Examples | ||
document.addEventListener('DOMContentLoaded', () => { | ||
new ictinus.BareSplitLayout(document.querySelector('#horizontal-example')); | ||
new ictinus.BareSplitLayout(document.querySelector('#vertical-example'), 20); | ||
new ictinus.BareSplitLayout(document.querySelector('#vertical-example')); | ||
}); |
@@ -42,3 +42,3 @@ (function (global, factory) { | ||
this.rectAxis = (this.orientation == 'horizontal') ? 'left' : 'top'; | ||
for (const element of this.container.children) { | ||
for (const element of Array.from(this.container.children)) { | ||
if (element.classList.contains('split-layout-gutter')) { | ||
@@ -56,2 +56,3 @@ this.gutter = element; | ||
if (this.onResize) { | ||
console.debug('on resize', this.onResize); | ||
this.onResize.call(this, ratio); | ||
@@ -58,0 +59,0 @@ } |
@@ -32,3 +32,3 @@ "use strict"; | ||
this.rectAxis = (this.orientation == 'horizontal') ? 'left' : 'top'; | ||
for (const element of this.container.children) { | ||
for (const element of Array.from(this.container.children)) { | ||
if (element.classList.contains('split-layout-gutter')) { | ||
@@ -46,2 +46,3 @@ this.gutter = element; | ||
if (this.onResize) { | ||
console.debug('on resize', this.onResize); | ||
this.onResize.call(this, ratio); | ||
@@ -48,0 +49,0 @@ } |
{ | ||
"name": "ictinus", | ||
"version": "0.7.0", | ||
"version": "0.8.0", | ||
"main": "dist/ictinus.js", | ||
@@ -5,0 +5,0 @@ "author": "Paris Kasidiaris <paris@sourcelair.com>", |
# Ictinus | ||
[![Build Status](https://travis-ci.com/sourcelair/ictinus.svg?branch=master)](https://travis-ci.com/sourcelair/ictinus) [![npm bundle size (minified + gzip)](https://img.shields.io/bundlephobia/minzip/ictinus.svg)](https://img.shields.io/bundlephobia/minzip/ictinus.svg) | ||
[![Build Status](https://travis-ci.com/sourcelair/ictinus.svg?branch=master)](https://travis-ci.com/sourcelair/ictinus) [![npm bundle size (minified + gzip)](https://img.shields.io/bundlephobia/minzip/ictinus.svg)](https://bundlephobia.com/result?p=ictinus) | ||
@@ -12,3 +12,3 @@ | ||
Ictinus leaves the most decisions possible to CSS. Whatever cannot be accomplished by CSS, is being delegated to JavaScript (e.g. resizing an element with drag n drop). Essentially Ictinus employes the [rule of least power](https://en.wikipedia.org/wiki/Rule_of_least_power). | ||
Ictinus leaves the most decisions possible to CSS. Whatever cannot be accomplished by CSS, is being delegated to JavaScript (e.g. resizing an element with drag n drop). Essentially Ictinus employs the [rule of least power](https://en.wikipedia.org/wiki/Rule_of_least_power). | ||
@@ -15,0 +15,0 @@ ## License |
@@ -25,3 +25,3 @@ import { BaseLayout } from './base'; | ||
// We are not using querySelector, since we require the gutter to be an immediate child. | ||
for (const element of this.container.children) { | ||
for (const element of Array.from(this.container.children)) { | ||
if (element.classList.contains('split-layout-gutter')) { | ||
@@ -61,2 +61,3 @@ this.gutter = <HTMLElement>element; | ||
if (this.onResize) { | ||
console.debug('on resize', this.onResize); | ||
this.onResize.call(this, ratio); | ||
@@ -63,0 +64,0 @@ } |
Sorry, the diff of this file is not supported yet
Sorry, the diff of this file is not supported yet
License Policy Violation
LicenseThis package is not allowed per your license policy. Review the package's license to ensure compliance.
Found 1 instance in 1 package
License Policy Violation
LicenseThis package is not allowed per your license policy. Review the package's license to ensure compliance.
Found 1 instance in 1 package
518
137269