Skip to content

Commit

Permalink
button used in checkbox implementation should be type=button so as no…
Browse files Browse the repository at this point in the history
…t to behave like submit button
  • Loading branch information
simonfox committed May 2, 2017
1 parent c5f6ab4 commit 3f0e94c
Show file tree
Hide file tree
Showing 8 changed files with 28 additions and 29 deletions.
36 changes: 16 additions & 20 deletions config.js
Original file line number Diff line number Diff line change
Expand Up @@ -11,13 +11,13 @@ System.config({
map: {
"aurelia-animator-velocity": "npm:aurelia-animator-velocity@1.1.0",
"aurelia-binding": "npm:aurelia-binding@1.2.1",
"aurelia-dependency-injection": "npm:aurelia-dependency-injection@1.3.0",
"aurelia-dependency-injection": "npm:aurelia-dependency-injection@1.3.1",
"aurelia-event-aggregator": "npm:aurelia-event-aggregator@1.0.1",
"aurelia-metadata": "npm:aurelia-metadata@1.0.3",
"aurelia-pal": "npm:aurelia-pal@1.3.0",
"aurelia-pal-browser": "npm:aurelia-pal-browser@1.2.0",
"aurelia-pal-browser": "npm:aurelia-pal-browser@1.2.1",
"aurelia-polyfills": "npm:aurelia-polyfills@1.2.1",
"aurelia-templating": "npm:aurelia-templating@1.4.0",
"aurelia-templating": "npm:aurelia-templating@1.4.2",
"bootstrap": "github:twbs/bootstrap@3.3.7",
"bootstrap-toggle": "npm:bootstrap-toggle@2.2.2",
"css": "github:systemjs/plugin-css@0.1.26",
Expand All @@ -26,11 +26,11 @@ System.config({
"github:jspm/nodelibs-assert@0.1.0": {
"assert": "npm:assert@1.4.1"
},
"github:jspm/nodelibs-buffer@0.1.0": {
"buffer": "npm:buffer@3.6.0"
"github:jspm/nodelibs-buffer@0.1.1": {
"buffer": "npm:buffer@5.0.6"
},
"github:jspm/nodelibs-process@0.1.2": {
"process": "npm:process@0.11.9"
"process": "npm:process@0.11.10"
},
"github:jspm/nodelibs-util@0.1.0": {
"util": "npm:util@0.10.3"
Expand All @@ -43,14 +43,14 @@ System.config({
},
"npm:assert@1.4.1": {
"assert": "github:jspm/nodelibs-assert@0.1.0",
"buffer": "github:jspm/nodelibs-buffer@0.1.0",
"buffer": "github:jspm/nodelibs-buffer@0.1.1",
"process": "github:jspm/nodelibs-process@0.1.2",
"util": "npm:util@0.10.3"
},
"npm:aurelia-animator-velocity@1.1.0": {
"aurelia-metadata": "npm:aurelia-metadata@1.0.3",
"aurelia-pal": "npm:aurelia-pal@1.3.0",
"aurelia-templating": "npm:aurelia-templating@1.4.0",
"aurelia-templating": "npm:aurelia-templating@1.4.2",
"velocity-animate": "npm:velocity-animate@1.5.0"
},
"npm:aurelia-binding@1.2.1": {
Expand All @@ -59,7 +59,7 @@ System.config({
"aurelia-pal": "npm:aurelia-pal@1.3.0",
"aurelia-task-queue": "npm:aurelia-task-queue@1.2.0"
},
"npm:aurelia-dependency-injection@1.3.0": {
"npm:aurelia-dependency-injection@1.3.1": {
"aurelia-metadata": "npm:aurelia-metadata@1.0.3",
"aurelia-pal": "npm:aurelia-pal@1.3.0"
},
Expand All @@ -73,7 +73,7 @@ System.config({
"npm:aurelia-metadata@1.0.3": {
"aurelia-pal": "npm:aurelia-pal@1.3.0"
},
"npm:aurelia-pal-browser@1.2.0": {
"npm:aurelia-pal-browser@1.2.1": {
"aurelia-pal": "npm:aurelia-pal@1.3.0"
},
"npm:aurelia-polyfills@1.2.1": {
Expand All @@ -82,31 +82,27 @@ System.config({
"npm:aurelia-task-queue@1.2.0": {
"aurelia-pal": "npm:aurelia-pal@1.3.0"
},
"npm:aurelia-templating@1.4.0": {
"npm:aurelia-templating@1.4.2": {
"aurelia-binding": "npm:aurelia-binding@1.2.1",
"aurelia-dependency-injection": "npm:aurelia-dependency-injection@1.3.0",
"aurelia-dependency-injection": "npm:aurelia-dependency-injection@1.3.1",
"aurelia-loader": "npm:aurelia-loader@1.0.0",
"aurelia-logging": "npm:aurelia-logging@1.3.1",
"aurelia-metadata": "npm:aurelia-metadata@1.0.3",
"aurelia-pal": "npm:aurelia-pal@1.3.0",
"aurelia-path": "npm:aurelia-path@1.1.1",
"aurelia-task-queue": "npm:aurelia-task-queue@1.2.0"
},
"npm:buffer@3.6.0": {
"base64-js": "npm:base64-js@0.0.8",
"child_process": "github:jspm/nodelibs-child_process@0.1.0",
"fs": "github:jspm/nodelibs-fs@0.1.2",
"ieee754": "npm:ieee754@1.1.8",
"isarray": "npm:isarray@1.0.0",
"process": "github:jspm/nodelibs-process@0.1.2"
"npm:buffer@5.0.6": {
"base64-js": "npm:base64-js@1.2.0",
"ieee754": "npm:ieee754@1.1.8"
},
"npm:inherits@2.0.1": {
"util": "github:jspm/nodelibs-util@0.1.0"
},
"npm:numeral@1.5.3": {
"fs": "github:jspm/nodelibs-fs@0.1.2"
},
"npm:process@0.11.9": {
"npm:process@0.11.10": {
"assert": "github:jspm/nodelibs-assert@0.1.0",
"fs": "github:jspm/nodelibs-fs@0.1.2",
"vm": "github:jspm/nodelibs-vm@0.1.0"
Expand Down
2 changes: 1 addition & 1 deletion dist/amd/checkbox.html
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
<template>
<div class-name.bind="'form-group ' + (small ? 'form-group-sm' : '')">
<button click.delegate="checkboxSelected()" focus.bind="grabFocus" disabled.bind="!enabled" class="btn btn-link form-control checkbox noselect">
<button click.delegate="checkboxSelected()" focus.bind="grabFocus" disabled.bind="!enabled" type="button" class="btn btn-link form-control checkbox noselect">
<div class="checkbox-selector ${enabled ? 'checkbox-selector-enabled' : 'checkbox-disabled'}">
<i class="${iconFamilyClass} ${ checked ? checkedIconClass : '' }"></i>
</div>
Expand Down
2 changes: 1 addition & 1 deletion dist/commonjs/checkbox.html
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
<template>
<div class-name.bind="'form-group ' + (small ? 'form-group-sm' : '')">
<button click.delegate="checkboxSelected()" focus.bind="grabFocus" disabled.bind="!enabled" class="btn btn-link form-control checkbox noselect">
<button click.delegate="checkboxSelected()" focus.bind="grabFocus" disabled.bind="!enabled" type="button" class="btn btn-link form-control checkbox noselect">
<div class="checkbox-selector ${enabled ? 'checkbox-selector-enabled' : 'checkbox-disabled'}">
<i class="${iconFamilyClass} ${ checked ? checkedIconClass : '' }"></i>
</div>
Expand Down
2 changes: 1 addition & 1 deletion dist/es2015/checkbox.html
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
<template>
<div class-name.bind="'form-group ' + (small ? 'form-group-sm' : '')">
<button click.delegate="checkboxSelected()" focus.bind="grabFocus" disabled.bind="!enabled" class="btn btn-link form-control checkbox noselect">
<button click.delegate="checkboxSelected()" focus.bind="grabFocus" disabled.bind="!enabled" type="button" class="btn btn-link form-control checkbox noselect">
<div class="checkbox-selector ${enabled ? 'checkbox-selector-enabled' : 'checkbox-disabled'}">
<i class="${iconFamilyClass} ${ checked ? checkedIconClass : '' }"></i>
</div>
Expand Down
2 changes: 1 addition & 1 deletion dist/system/checkbox.html
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
<template>
<div class-name.bind="'form-group ' + (small ? 'form-group-sm' : '')">
<button click.delegate="checkboxSelected()" focus.bind="grabFocus" disabled.bind="!enabled" class="btn btn-link form-control checkbox noselect">
<button click.delegate="checkboxSelected()" focus.bind="grabFocus" disabled.bind="!enabled" type="button" class="btn btn-link form-control checkbox noselect">
<div class="checkbox-selector ${enabled ? 'checkbox-selector-enabled' : 'checkbox-disabled'}">
<i class="${iconFamilyClass} ${ checked ? checkedIconClass : '' }"></i>
</div>
Expand Down
3 changes: 3 additions & 0 deletions doc/CHANGELOG.md
Original file line number Diff line number Diff line change
@@ -1,3 +1,6 @@
### 2.0.2 (2017-05-02)


### 2.0.1 (2017-04-12)


Expand Down
8 changes: 4 additions & 4 deletions package.json
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
{
"name": "aurelia-widgets",
"version": "2.0.1",
"version": "2.0.2",
"description": "A Collection of UI Widgets for use in Aurelia applications",
"homepage": "http://drivesoftware.co.nz",
"main": "index",
Expand Down Expand Up @@ -67,12 +67,12 @@
"dependencies": {
"aurelia-animator-velocity": "npm:aurelia-animator-velocity@^1.1.0",
"aurelia-binding": "npm:aurelia-binding@^1.2.1",
"aurelia-dependency-injection": "npm:aurelia-dependency-injection@^1.3.0",
"aurelia-dependency-injection": "npm:aurelia-dependency-injection@^1.3.1",
"aurelia-event-aggregator": "npm:aurelia-event-aggregator@^1.0.1",
"aurelia-metadata": "npm:aurelia-metadata@^1.0.3",
"aurelia-pal": "npm:aurelia-pal@^1.3.0",
"aurelia-pal-browser": "npm:aurelia-pal-browser@^1.2.0",
"aurelia-templating": "npm:aurelia-templating@^1.4.0",
"aurelia-pal-browser": "npm:aurelia-pal-browser@^1.2.1",
"aurelia-templating": "npm:aurelia-templating@^1.4.2",
"bootstrap": "github:twbs/bootstrap@^3.3.6",
"bootstrap-toggle": "npm:bootstrap-toggle@^2.2.2",
"css": "github:systemjs/plugin-css@^0.1.25",
Expand Down
2 changes: 1 addition & 1 deletion src/checkbox.html
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
<template>
<div class-name.bind="'form-group ' + (small ? 'form-group-sm' : '')">
<button click.delegate="checkboxSelected()" focus.bind="grabFocus" disabled.bind="!enabled" class="btn btn-link form-control checkbox noselect">
<button click.delegate="checkboxSelected()" focus.bind="grabFocus" disabled.bind="!enabled" type="button" class="btn btn-link form-control checkbox noselect">
<div class="checkbox-selector ${enabled ? 'checkbox-selector-enabled' : 'checkbox-disabled'}">
<i class="${iconFamilyClass} ${ checked ? checkedIconClass : '' }"></i>
</div>
Expand Down

0 comments on commit 3f0e94c

Please sign in to comment.