Skip to content

Commit

Permalink
Merge pull request #18517 from timvandermeij/viewer-button-types
Browse files Browse the repository at this point in the history
Give all HTML button elements a type
  • Loading branch information
timvandermeij committed Aug 1, 2024
2 parents 63371ea + f1f58bb commit ec0f0f3
Show file tree
Hide file tree
Showing 5 changed files with 58 additions and 58 deletions.
4 changes: 2 additions & 2 deletions examples/learning/prevnext.html
Original file line number Diff line number Diff line change
Expand Up @@ -9,8 +9,8 @@
<h1>'Previous/Next' example</h1>

<div>
<button id="prev">Previous</button>
<button id="next">Next</button>
<button id="prev" type="button">Previous</button>
<button id="next" type="button">Next</button>
&nbsp; &nbsp;
<span>Page: <span id="page_num"></span> / <span id="page_count"></span></span>
</div>
Expand Down
8 changes: 4 additions & 4 deletions examples/mobile-viewer/viewer.html
Original file line number Diff line number Diff line change
Expand Up @@ -43,13 +43,13 @@ <h1 id="title"></h1>
</div>

<footer>
<button class="toolbarButton pageUp" title="Previous Page" id="previous"></button>
<button class="toolbarButton pageDown" title="Next Page" id="next"></button>
<button class="toolbarButton pageUp" title="Previous Page" id="previous" type="button"></button>
<button class="toolbarButton pageDown" title="Next Page" id="next" type="button"></button>

<input type="number" id="pageNumber" class="toolbarField pageNumber" value="1" size="4" min="1">

<button class="toolbarButton zoomOut" title="Zoom Out" id="zoomOut"></button>
<button class="toolbarButton zoomIn" title="Zoom In" id="zoomIn"></button>
<button class="toolbarButton zoomOut" title="Zoom Out" id="zoomOut" type="button"></button>
<button class="toolbarButton zoomIn" title="Zoom In" id="zoomIn" type="button"></button>
</footer>

<script src="viewer.mjs" type="module"></script>
Expand Down
2 changes: 1 addition & 1 deletion extensions/chromium/options/options.html
Original file line number Diff line number Diff line change
Expand Up @@ -31,7 +31,7 @@
</head>
<body>
<div id="settings-boxes"></div>
<button id="reset-button">Restore default settings</button>
<button id="reset-button" type="button">Restore default settings</button>

<template id="checkbox-template">
<!-- Chromium's style: //src/extensions/renderer/resources/extension.css -->
Expand Down
6 changes: 3 additions & 3 deletions web/viewer-geckoview.html
Original file line number Diff line number Diff line change
Expand Up @@ -99,7 +99,7 @@
<div id="mainContainer">

<div id="floatingToolbar">
<button id="download" class="toolbarButton" title="Download" tabindex="31" data-l10n-id="pdfjs-download-button">
<button id="download" class="toolbarButton" type="button" title="Download" tabindex="31" data-l10n-id="pdfjs-download-button">
<span data-l10n-id="pdfjs-download-button-label">Download</span>
</button>
</div>
Expand All @@ -118,8 +118,8 @@
<input type="password" id="password" class="toolbarField">
</div>
<div class="buttonRow">
<button id="passwordCancel" class="dialogButton"><span data-l10n-id="pdfjs-password-cancel-button">Cancel</span></button>
<button id="passwordSubmit" class="dialogButton"><span data-l10n-id="pdfjs-password-ok-button">OK</span></button>
<button id="passwordCancel" class="dialogButton" type="button"><span data-l10n-id="pdfjs-password-cancel-button">Cancel</span></button>
<button id="passwordSubmit" class="dialogButton" type="button"><span data-l10n-id="pdfjs-password-ok-button">OK</span></button>
</div>
</dialog>
</div> <!-- dialogContainer -->
Expand Down
Loading

0 comments on commit ec0f0f3

Please sign in to comment.