Skip to content
Closed
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
5 changes: 5 additions & 0 deletions .editorconfig
Original file line number Diff line number Diff line change
Expand Up @@ -15,3 +15,8 @@ charset = utf-8

trim_trailing_whitespace = true
insert_final_newline = true

# Don't mess with stuff in inc.
[app/inc/**]
trim_trailing_whitespace = false
insert_final_newline = false
2 changes: 1 addition & 1 deletion app/inc/behave.js
Original file line number Diff line number Diff line change
Expand Up @@ -438,7 +438,7 @@

if(!utils.fenceRange()){ return; }

if (e.keyCode == 13 && e.shiftKey !== true) {
if (e.keyCode == 13 && e.shiftKey !== true) { // NOTE: EDITED

utils.preventDefaultEvent(e);
utils._callHook('enter:before');
Expand Down
2 changes: 1 addition & 1 deletion app/scripts/template/sidebar.htm
Original file line number Diff line number Diff line change
Expand Up @@ -11,7 +11,7 @@
</li>
<li class="nav-header examples">Examples</li>
<li class="nav-header">Resources</li>
<li><a href="https://github.com/CPAN-API/cpan-api/wiki/API-docs">API Documentation</a></li>
<li><a href="https://github.com/CPAN-API/cpan-api/blob/master/docs/API-docs.md">API Documentation</a></li>
<li><a href="https://github.com/CPAN-API/metacpan-explorer/issues">Report Issue</a></li>
<li><a href="https://github.com/CPAN-API/metacpan-explorer">Fork Me</a></li>
</ul>
6 changes: 6 additions & 0 deletions app/scripts/view/request.js
Original file line number Diff line number Diff line change
Expand Up @@ -12,9 +12,15 @@ define([
return View.extend({
name: "request",
template: template,

events: {
"keydown textarea": function(e) {
// Shift + Enter to send request.
// NOTE: Our copy of behave has an edit on line 441 to disable behave's
// enterKey functionality when shift is pressed.
// Behave offers hooks for keydown as well as enter:before but they both
// fire after behave's enterKey function has started, so I think it's
// too late... I think we're stuck with the edit.
if((e.keyCode || e.which) === 13 && e.shiftKey === true) {
this.model.request();
return false;
Expand Down
2 changes: 1 addition & 1 deletion app/scripts/view/settings.js
Original file line number Diff line number Diff line change
Expand Up @@ -16,7 +16,7 @@ define([
item: function() {
return [
'<li class="list-group-item"><label>',
_.toArray(arguments).join(''),
_.toArray(arguments).join(' '),
'</label></li>'
].join('');
}
Expand Down
2 changes: 1 addition & 1 deletion build/app.js

Large diffs are not rendered by default.

4 changes: 2 additions & 2 deletions build/index.html
Original file line number Diff line number Diff line change
Expand Up @@ -4,8 +4,8 @@
<meta charset="utf-8">
<title>MetaCPAN Explorer</title>
<link rel="shortcut icon" href="//metacpan.org/static/icons/favicon.ico">
<link rel="stylesheet" type="text/css" href="styles.css?bust=i1a6yapo">
<script type="text/javascript" src="app.js?bust=i1a6yapo"></script>
<link rel="stylesheet" type="text/css" href="styles.css?bust=ib58mx88">
<script type="text/javascript" src="app.js?bust=ib58mx88"></script>
</head>
<body>
<noscript>This page requires JavaScript.</noscript>
Expand Down