Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

When in-line editing yaml and other files, the tab key now uses spaces #1667

Merged
merged 1 commit into from
Oct 7, 2024
Merged
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
1 change: 1 addition & 0 deletions CHANGELOG.md
Original file line number Diff line number Diff line change
Expand Up @@ -18,6 +18,7 @@
- Handle a variation in a bioformats exception ([#1656](../../pull/1656))
- Increase logging slow histograms ([#1658](../../pull/1658))
- Use paginated item lists ([#1664](../../pull/1664))
- When in-line editing yaml and other files, the tab key now uses spaces ([#1667](../../pull/1667))

### Bug Fixes

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -214,6 +214,13 @@
value: this._contents,
mode: Formats[this.mimeType].mode,
lineNumbers: true,
indentWithTabs: false,
extraKeys: {
Tab: function (cm) {
var spaces = Array(cm.getOption('tabSize') + 1).join(' ');
cm.replaceSelection(spaces);

Check warning on line 221 in girder/girder_large_image/web_client/views/itemViewCodemirror.js

View check run for this annotation

Codecov / codecov/patch

girder/girder_large_image/web_client/views/itemViewCodemirror.js#L219-L221

Added lines #L219 - L221 were not covered by tests
}
},
gutters: ['CodeMirror-lint-markers'],
lint: true,
readOnly: this.accessLevel < AccessType.WRITE
Expand Down