3 Polymer('core-splitter', {
6 * Possible values are "left", "right", "up" and "down".
15 * Minimum width to which the splitter target can be sized
24 * Locks the split bar so it can't be dragged.
33 * By default the parent and siblings of the splitter are set to overflow hidden. This helps
34 * avoid elements bleeding outside the splitter regions. Set this property to true to allow
35 * these elements to overflow.
37 * @attribute allowOverflow
44 this.directionChanged();
47 domReady: function() {
48 if (!this.allowOverflow) {
49 this.parentNode.style.overflow = this.nextElementSibling.style.overflow =
50 this.previousElementSibling.style.overflow = 'hidden';
54 directionChanged: function() {
55 this.isNext = this.direction === 'right' || this.direction === 'down';
56 this.horizontal = this.direction === 'up' || this.direction === 'down';
61 this.target = this.isNext ? this.nextElementSibling : this.previousElementSibling;
62 this.dimension = this.horizontal ? 'height' : 'width';
63 this.classList.toggle('horizontal', this.horizontal);
66 targetChanged: function(old) {
68 old.style[old.__splitterMinSize] = '';
70 var min = this.target.__splitterMinSize = this.horizontal ? 'minHeight' : 'minWidth';
71 this.target.style[min] = this.minSize + 'px';
74 trackStart: function() {
76 this.size = parseInt(getComputedStyle(this.target)[this.dimension]);
83 var d = e[this.horizontal ? 'dy' : 'dx'];
84 this.target.style[this.dimension] =
85 this.size + (this.isNext ? -d : d) + 'px';
88 preventSelection: function(e) {