Skip to content

Commit 1ededbf

Browse files
author
atacan
committed
wrap json input; html-swift update
1 parent 51569c1 commit 1ededbf

File tree

5 files changed

+8
-6
lines changed

5 files changed

+8
-6
lines changed

DimeADozen.xcodeproj/project.xcworkspace/xcshareddata/swiftpm/Package.resolved

Lines changed: 2 additions & 2 deletions
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

DimeADozen.xcodeproj/xcshareddata/xcschemes/DimeADozen (macOS).xcscheme

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -31,7 +31,7 @@
3131
</Testables>
3232
</TestAction>
3333
<LaunchAction
34-
buildConfiguration = "Debug"
34+
buildConfiguration = "Release"
3535
selectedDebuggerIdentifier = "Xcode.DebuggerFoundation.Debugger.LLDB"
3636
selectedLauncherIdentifier = "Xcode.DebuggerFoundation.Launcher.LLDB"
3737
launchStyle = "0"

Shared/JsonPretty/JsonPrettyView.swift

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -74,7 +74,7 @@ struct JsonPrettyView: View {
7474
WithViewStore(store, observe: { $0 }) { viewStore in
7575
VSplitView {
7676
VStack {
77-
MacEditorView(text: viewStore.binding(\.$input))
77+
MacEditorView(text: viewStore.binding(\.$input), hasHorizontalScroll: false)
7878
.shadow(radius: 2)
7979
.padding()
8080
Button("Prettify") {

Shared/Main/Views/MainSidebarView.swift

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -6,7 +6,7 @@ import SwiftUI
66

77
struct MainSidebarView: View {
88
#if DEBUG
9-
@State private var selectedTool: Tool? = swiftPrettifyTool
9+
@State private var selectedTool: Tool? = toolPrefixSuffix
1010
#else
1111
@State private var selectedTool: Tool?
1212
#endif

Shared/SwiftPretty/SwiftHighlightAsyncClient.swift

Lines changed: 3 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -36,7 +36,8 @@ extension SwiftHighlightAsyncClient: DependencyKey {
3636
rules: FormatRules.all(except: ["linebreakAtEndOfFile"]),
3737
options: FormatOptions(
3838
wrapArguments: .beforeFirst,
39-
wrapCollections: .beforeFirst
39+
wrapCollections: .beforeFirst,
40+
maxWidth: 100
4041
),
4142
lineRange: nil)
4243
let highlighter = SwiftHighlighter(inputCode: pretty)
@@ -73,3 +74,4 @@ private func render(_ tag: Tag) -> String {
7374
let doc = Document(.unspecified) { tag }
7475
return DocumentRenderer(minify: true, indent: 2).render(doc)
7576
}
77+

0 commit comments

Comments
 (0)