Skip to content

Commit

Permalink
buttons in compents should use type=button or they will trigger submits
Browse files Browse the repository at this point in the history
  • Loading branch information
Enome committed Aug 16, 2013
1 parent 6dd5e29 commit 804f270
Show file tree
Hide file tree
Showing 10 changed files with 21 additions and 19 deletions.
18 changes: 9 additions & 9 deletions panel/client/build/build.js
Expand Up @@ -2593,7 +2593,7 @@ require.register("enome-components-angular-markdown-editor/template.js", Functio
"module.exports = '<div class=\\'markdowneditor\\'>\\n\
\\n\
<div class=\\'actionbar\\'>\\n\
<button ng-click=\\'toggleFileManager()\\' title=\\'Insert images and files\\'>Insert file</button>\\n\
<button type=\\'button\\' ng-click=\\'toggleFileManager()\\' title=\\'Insert images and files\\'>Insert file</button>\\n\
</div>\\n\
\\n\
<div class=\\'insert\\'>\\n\
Expand All @@ -2605,9 +2605,9 @@ require.register("enome-components-angular-markdown-editor/template.js", Functio
<div ng-show=\\'show_file_manager\\' class=\\'file-manager-overlay\\'>\\n\
<file-manager url=\\'fileserver\\' selected=\\'selected_files\\'></file-manager>\\n\
<div class=\\'actions\\'>\\n\
<button ng-click=\\'insertImage()\\' ng-disabled=\\'!selected_files.length\\'>Insert As Image</button>\\n\
<button ng-click=\\'insertLink()\\' ng-disabled=\\'!selected_files.length\\'>Insert As Link</button>\\n\
<button ng-click=\\'toggleFileManager()\\'>Cancel</button>\\n\
<button type=\\'button\\' ng-click=\\'insertImage()\\' ng-disabled=\\'!selected_files.length\\'>Insert As Image</button>\\n\
<button type=\\'button\\' ng-click=\\'insertLink()\\' ng-disabled=\\'!selected_files.length\\'>Insert As Link</button>\\n\
<button type=\\'button\\' ng-click=\\'toggleFileManager()\\'>Cancel</button>\\n\
</div>\\n\
</div>\\n\
\\n\
Expand Down Expand Up @@ -2850,12 +2850,12 @@ module.exports = 'markdown-textarea';\n\
require.register("enome-components-angular-markdown-textarea/template.js", Function("exports, require, module",
"module.exports = '<div class=\\'markdown-textarea\\'>\\n\
<div class=\\'textarea-container\\'>\\n\
<button ng-click=\\'toggle()\\' title=\\'Show fullscreen editor\\'><i class=\\'icon-resize-full\\'></i></button>\\n\
<button type=\\'button\\' ng-click=\\'toggle()\\' title=\\'Show fullscreen editor\\'><i class=\\'icon-resize-full\\'></i></button>\\n\
<textarea ng-model=\\'data\\'></textarea>\\n\
\\n\
</div>\\n\
<div class=\\'overlay\\' ng-show=\\'show_editor\\'>\\n\
<button ng-click=\\'toggle()\\' title=\\'Hide fullscreen editor\\'><i class=\\'icon-resize-small\\'></i></button>\\n\
<button type=\\'button\\' ng-click=\\'toggle()\\' title=\\'Hide fullscreen editor\\'><i class=\\'icon-resize-small\\'></i></button>\\n\
<markdown-editor data=\\'data\\' fileserver=\\'fileserver\\' />\\n\
</div>\\n\
</div>\\n\
Expand Down Expand Up @@ -3025,7 +3025,7 @@ require.register("enome-components-angular-arrangeable-array/template.js", Funct
<div class=\\'row\\' ng-repeat=\\'item in array\\' data-index=\\'{{$index}}\\'>\\n\
<div class=\\'col1\\'>{{item}}</div>\\n\
<div class=\\'col2\\'>\\n\
<button ng-click=\\'remove(item)\\'><i class=\\'icon-remove\\'></i></button>\\n\
<button type=\\'button\\' ng-click=\\'remove(item)\\'><i class=\\'icon-remove\\'></i></button>\\n\
</div>\\n\
</div>\\n\
\\n\
Expand Down Expand Up @@ -3066,15 +3066,15 @@ require.register("enome-components-angular-arrangeable-files/template.js", Funct
\\n\
<div class=\\'default\\' ng-show=\\'!full_screen\\'>\\n\
<div class=\\'header\\'>\\n\
<button ng-click=\\'full_screen = !full_screen\\'>Select files</button>\\n\
<button type=\\'button\\' ng-click=\\'full_screen = !full_screen\\'>Select files</button>\\n\
</div>\\n\
\\n\
<arrangeable-array array=\\'selected\\'></arrangeable-array>\\n\
</div>\\n\
\\n\
<div class=\\'overlay\\' ng-show=\\'full_screen\\'>\\n\
<file-manager selected=\\'selected\\' url=\\'fileserver\\'></file-manager>\\n\
<button ng-click=\\'full_screen = !full_screen\\'>Close</button>\\n\
<button type=\\'button\\' ng-click=\\'full_screen = !full_screen\\'>Close</button>\\n\
</div>\\n\
\\n\
</div>\\n\
Expand Down
Expand Up @@ -2,7 +2,7 @@
"name": "angular-arrangeable-array",
"repo": "enome-components/angular-arrangeable-array",
"description": "Edit the order and remove items from an array.",
"version": "1.1.3",
"version": "1.1.4",
"keywords": [
"angular",
"array",
Expand Down

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

Expand Up @@ -2,7 +2,7 @@
"name": "angular-arrangeable-files",
"repo": "enome-components/angular-arrangeable-files",
"description": "angular-file-manager + angular-arrangeable-array",
"version": "1.1.0",
"version": "1.1.1",
"keywords": [],
"dependencies": {
"enome-components/angular-arrangeable-array": "*",
Expand Down

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

Expand Up @@ -2,7 +2,7 @@
"name": "angular-markdown-editor",
"repo": "enome-components/angular-markdown-editor",
"description": "Markdown editor directive for Angular.js with angular-file-manager",
"version": "1.1.0",
"version": "1.1.1",
"keywords": [
"angular",
"markdown",
Expand Down

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

Expand Up @@ -2,7 +2,7 @@
"name": "angular-markdown-textarea",
"repo": "enome-components/angular-markdown-textarea",
"description": "textarea and angular-markdown-editor combined",
"version": "1.0.1",
"version": "1.0.2",
"keywords": [],
"dependencies": {
"timoxley/font-awesome": "*",
Expand Down

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

6 changes: 4 additions & 2 deletions panel/client/locals/jungles-panel-core/partials/popups.html
Expand Up @@ -5,8 +5,10 @@ <h2>The destination already has a content item named "{{data.name}}".</h2>
<form name='popup_form' novalidate>
<label>New name</label>
<input type='text' ng-model='new_name' required/>
<button type='submit' ng-click='rename()' ng-disabled='validate(popup_form.$invalid, new_name)'>Rename</button>
<button type='button' ng-click='close()'>Skip</button>
<div class='actions'>
<button type='submit' ng-click='rename()' ng-disabled='validate(popup_form.$invalid, new_name)'>Rename</button>
<button type='button' ng-click='close()'>Skip</button>
</div>
</form>

</div>

0 comments on commit 804f270

Please sign in to comment.