Repository navigation
fix(lint): reset inline styles without static style assignments - #668
Merged
Merged
Conversation
The Obsidian review action raises obsidianmd/no-static-styles-assignment
to an error, and it flags assigning a string literal to element.style.*,
including the empty string used to clear a value.
- SettingsModal: settings search hides sidebar groups with
group.toggle(); restore them with group.show() instead of writing
style.display = "".
- InlineEditor: clear the textarea's inline height with
style.removeProperty("height") before measuring scrollHeight.
This was referenced Nov 28, 2026
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to subscribe to this conversation on GitHub.
Already have an account?
Sign in.
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Description
The Obsidian review action (
obsidianmd/obsidian-workflows@v1, #626) raisesobsidianmd/no-static-styles-assignmentto an error. Assigning a string literal toelement.style.*triggers it, and that includes the empty string used to clear a value. Two sites on master still did this.In advisory mode these errors are downgraded to warnings. GitHub shows at most 10 warning annotations per step, so they were hidden. They are among the errors that fail strict mode (#667).
Changes
SettingsModal.ts: settings search hides sidebar groups withgroup.toggle(). Clearing the search now restores them withgroup.show()instead ofgroup.style.display = "".InlineEditor.ts:autoResizeTextareaclears the inline height withstyle.removeProperty("height")before it measuresscrollHeight, instead ofstyle.height = "".Both are behaviour-preserving:
show()andremoveProperty()clear the same inline declaration.Verification
src/has 0 error-level findings.tscpasses.Type of Change
Checklist