Menu icon Foundation

My Posts







My Comments

Jim Christenson commented on Jim Christenson's post almost 3 years

This is where the reflow is comming into play in foundation.slider.js

 reflow : function () {
  var self = this;
  self.S('[' + this.attr_name() + ']').each(function () {
    var handle = $(this).children('.range-slider-handle')[0],
        val = $(this).attr(self.attr_name());
    self.initialize_settings(handle);

    if (val) {
      self.set_ui($(handle), parseFloat(val));
    } else {
      self.set_initial_position($(this));
    }
  });

Jim Christenson commented on Jim Christenson's post almost 3 years

Thank you so much for the reply, Tim! So what I have tried to do is build a basic foundation 6. Just to be sure, the only thing I took was the grid. I take my functioning Foundation 5 page, and just swap out the foundation.js files. The slider from 5 is a separate js file that is still being included.

The errors I get when trying to use the page are below. It looks like "reflow" is not being recognized by the foundation.js 6, and it looks like something is deprecated, but that may or may not be related.

-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-
TypeError: Foundation.libs is undefined

reflow : function () {

foundattionslider.js (line 280, col 5)
-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-
TypeError: We're sorry, 'object' is not a valid parameter. You must use a
string representing the method you wish to invoke.

Error: "throw $continue" is deprecated, use "return" instead

-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-

Jim Christenson commented on Jim Christenson's post almost 3 years

Thanks for the reply, Rafi. I actually did have all the nessesary Foundation files loaded, but thanks for checking.

The issue was that I was firing a mouseup to post the number selected by the slider

jQuery('[data-slider]').on('mouseup.fndtn.slider', function(){
if (num_avail != jQuery(this).attr('data-slider')) {
submitForm();
}
});

Problem was when the user's mouse wasn't directly over the slider. Ended up fixing it with this:

jQuery('[data-slider]').bind('mouseleave', function(){
jQuery('body').one('mouseup', function() {
jQuery ('[data-slider]').mouseup();
});
});

Jim Christenson commented on Jim Christenson's post almost 3 years

Ah, found the answer. You can put it inline:

<div class="row" data-equalizer data-options="equalize_on_stack: true">

Jim Christenson commented on Jim Christenson's post almost 3 years

Hey April, thanks for the reply. The divs where I say "this cannot have a class or ID attributed to it" are automatically inserted because this page is being built by a database. Put simply, they are there, and they are hands off. (It's a whole separate battle, but I won't get into it :-D ) So I'm wondering what happens when you insert divs that are not part of the row column set up/layout.

Are they basically assumed to be 100% width of parent and height dependent on content inside? How does this play with Foundations row - column margins and padding? And the row row negative margin?

Also, thank you for the clarification regarding the necessity of rows.

Posts Followed



Following

    No Content

Followers

My Posts

My Comments

You commented on Jim Christenson's post almost 3 years

This is where the reflow is comming into play in foundation.slider.js

 reflow : function () {
  var self = this;
  self.S('[' + this.attr_name() + ']').each(function () {
    var handle = $(this).children('.range-slider-handle')[0],
        val = $(this).attr(self.attr_name());
    self.initialize_settings(handle);

    if (val) {
      self.set_ui($(handle), parseFloat(val));
    } else {
      self.set_initial_position($(this));
    }
  });

You commented on Jim Christenson's post almost 3 years

Thank you so much for the reply, Tim! So what I have tried to do is build a basic foundation 6. Just to be sure, the only thing I took was the grid. I take my functioning Foundation 5 page, and just swap out the foundation.js files. The slider from 5 is a separate js file that is still being included.

The errors I get when trying to use the page are below. It looks like "reflow" is not being recognized by the foundation.js 6, and it looks like something is deprecated, but that may or may not be related.

-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-
TypeError: Foundation.libs is undefined

reflow : function () {

foundattionslider.js (line 280, col 5)
-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-
TypeError: We're sorry, 'object' is not a valid parameter. You must use a
string representing the method you wish to invoke.

Error: "throw $continue" is deprecated, use "return" instead

-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-

You commented on Jim Christenson's post almost 3 years

Thanks for the reply, Rafi. I actually did have all the nessesary Foundation files loaded, but thanks for checking.

The issue was that I was firing a mouseup to post the number selected by the slider

jQuery('[data-slider]').on('mouseup.fndtn.slider', function(){
if (num_avail != jQuery(this).attr('data-slider')) {
submitForm();
}
});

Problem was when the user's mouse wasn't directly over the slider. Ended up fixing it with this:

jQuery('[data-slider]').bind('mouseleave', function(){
jQuery('body').one('mouseup', function() {
jQuery ('[data-slider]').mouseup();
});
});

You commented on Jim Christenson's post almost 3 years

Ah, found the answer. You can put it inline:

<div class="row" data-equalizer data-options="equalize_on_stack: true">

You commented on Jim Christenson's post almost 3 years

Hey April, thanks for the reply. The divs where I say "this cannot have a class or ID attributed to it" are automatically inserted because this page is being built by a database. Put simply, they are there, and they are hands off. (It's a whole separate battle, but I won't get into it :-D ) So I'm wondering what happens when you insert divs that are not part of the row column set up/layout.

Are they basically assumed to be 100% width of parent and height dependent on content inside? How does this play with Foundations row - column margins and padding? And the row row negative margin?

Also, thank you for the clarification regarding the necessity of rows.

Posts Followed

Following

  • No Content

Followers

  • No Content