Skip to content

Commit

Permalink
Added a small fix regarding #56
Browse files Browse the repository at this point in the history
  • Loading branch information
rstaib committed Apr 27, 2014
1 parent b96c452 commit 76465a9
Show file tree
Hide file tree
Showing 10 changed files with 16 additions and 19 deletions.
3 changes: 3 additions & 0 deletions CHANGELOG.md
Original file line number Diff line number Diff line change
@@ -1,5 +1,8 @@
# Changelog

## 1.0.6
- Small fix. Closes issue [#56](https://github.com/rstaib/jquery-steps/issues/56)

## 1.0.5

- Added a cancel button
Expand Down
Binary file removed build/jQuery.Steps.1.0.5.nupkg
Binary file not shown.
Binary file added build/jQuery.Steps.1.0.6.nupkg
Binary file not shown.
Binary file removed build/jquery.steps-1.0.5.zip
Binary file not shown.
Binary file added build/jquery.steps-1.0.6.zip
Binary file not shown.
13 changes: 5 additions & 8 deletions build/jquery.steps.js
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
/*!
* jQuery Steps v1.0.5 - 04/27/2014
* jQuery Steps v1.0.6 - 04/27/2014
* Copyright (c) 2014 Rafael Staib (http://www.jquery-steps.com)
* Licensed under MIT http://www.opensource.org/licenses/MIT
*/
Expand Down Expand Up @@ -624,7 +624,7 @@ function insertStep(wizard, options, state, index, step)
getStepPanel(wizard, (index - 1)).after(body).after(header);
}

renderBody(wizard, body, index);
renderBody(wizard, state, body, index);
renderTitle(wizard, options, state, header, index);
refreshSteps(wizard, options, state, index);
if (index === state.currentIndex)
Expand Down Expand Up @@ -1001,12 +1001,9 @@ function render(wizard, options, state)
// Add WIA-ARIA support
stepContents.each(function (index)
{
renderBody(wizard, $(this), index);
renderBody(wizard, state, $(this), index);
});

// Make the start step visible
stepContents.eq(state.currentIndex)._showAria();

stepTitles.each(function (index)
{
renderTitle(wizard, options, state, $(this), index);
Expand All @@ -1026,14 +1023,14 @@ function render(wizard, options, state)
* @param body {Object} A jQuery body object
* @param index {Integer} The position of the body
*/
function renderBody(wizard, body, index)
function renderBody(wizard, state, body, index)
{
var uniqueId = getUniqueId(wizard),
uniqueBodyId = uniqueId + _tabpanelSuffix + index,
uniqueHeaderId = uniqueId + _titleSuffix + index;

body._id(uniqueBodyId).attr("role", "tabpanel")._aria("labelledby", uniqueHeaderId)
.addClass("body")._showAria(false);
.addClass("body")._showAria(state.currentIndex === index);
}

/**
Expand Down
4 changes: 2 additions & 2 deletions build/jquery.steps.min.js

Large diffs are not rendered by default.

2 changes: 1 addition & 1 deletion package.json
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
{
"name": "jquery-steps",
"title": "jQuery Steps",
"version": "1.0.5",
"version": "1.0.6",
"description": "A powerful jQuery wizard plugin that supports accessibility and HTML5",
"homepage": "http://www.jquery-steps.com",
"author": {
Expand Down
11 changes: 4 additions & 7 deletions src/privates.js
Original file line number Diff line number Diff line change
Expand Up @@ -564,7 +564,7 @@ function insertStep(wizard, options, state, index, step)
getStepPanel(wizard, (index - 1)).after(body).after(header);
}

renderBody(wizard, body, index);
renderBody(wizard, state, body, index);
renderTitle(wizard, options, state, header, index);
refreshSteps(wizard, options, state, index);
if (index === state.currentIndex)
Expand Down Expand Up @@ -941,12 +941,9 @@ function render(wizard, options, state)
// Add WIA-ARIA support
stepContents.each(function (index)
{
renderBody(wizard, $(this), index);
renderBody(wizard, state, $(this), index);
});

// Make the start step visible
stepContents.eq(state.currentIndex)._showAria();

stepTitles.each(function (index)
{
renderTitle(wizard, options, state, $(this), index);
Expand All @@ -966,14 +963,14 @@ function render(wizard, options, state)
* @param body {Object} A jQuery body object
* @param index {Integer} The position of the body
*/
function renderBody(wizard, body, index)
function renderBody(wizard, state, body, index)
{
var uniqueId = getUniqueId(wizard),
uniqueBodyId = uniqueId + _tabpanelSuffix + index,
uniqueHeaderId = uniqueId + _titleSuffix + index;

body._id(uniqueBodyId).attr("role", "tabpanel")._aria("labelledby", uniqueHeaderId)
.addClass("body")._showAria(false);
.addClass("body")._showAria(state.currentIndex === index);
}

/**
Expand Down
2 changes: 1 addition & 1 deletion steps.jquery.json
Original file line number Diff line number Diff line change
Expand Up @@ -14,7 +14,7 @@
"tabs",
"steps"
],
"version": "1.0.5",
"version": "1.0.6",
"author": {
"name": "Rafael Staib",
"email": "me@rafaelstaib.com",
Expand Down

0 comments on commit 76465a9

Please sign in to comment.