Skip to content

Commit

Permalink
[#4330] Stop disabling header buttons when disabling sheet inputs
Browse files Browse the repository at this point in the history
  • Loading branch information
arbron committed Sep 19, 2024
1 parent 3e8fdbd commit 9227583
Showing 1 changed file with 3 additions and 3 deletions.
6 changes: 3 additions & 3 deletions module/applications/api/application.mjs
Original file line number Diff line number Diff line change
Expand Up @@ -112,11 +112,11 @@ export default class Application5e extends HandlebarsApplicationMixin(Applicatio
* Disable form fields that aren't marked with the `interface-only` class.
*/
_disableFields() {
const tags = [
const selector = `.window-content :is(${[
"INPUT", "SELECT", "TEXTAREA", "BUTTON", "DND5E-CHECKBOX", "COLOR-PICKER", "DOCUMENT-TAGS",
"FILE-PICKER", "HUE-SLIDER", "MULTI-SELECT", "PROSE-MIRROR", "RANGE-PICKER", "STRING-TAGS"
];
for ( const element of this.element.querySelectorAll(`:is(${tags.join(", ")}):not(.interface-only)`) ) {
].join(", ")}):not(.interface-only)`;
for ( const element of this.element.querySelectorAll(selector) ) {
if ( element.tagName === "TEXTAREA" ) element.readOnly = true;
else element.disabled = true;
}
Expand Down

0 comments on commit 9227583

Please sign in to comment.