Skip to content

Commit

Permalink
Updated docc
Browse files Browse the repository at this point in the history
  • Loading branch information
aure committed Jul 29, 2022
1 parent aadd620 commit 26c34a8
Showing 1 changed file with 2 additions and 10 deletions.
12 changes: 2 additions & 10 deletions Sources/PianoRoll/PianoRoll.docc/PianoRoll.md
Original file line number Diff line number Diff line change
Expand Up @@ -8,16 +8,14 @@ Touch-oriented piano roll.
import SwiftUI
import PianoRoll

public struct PianoRollDemoView: View {

public init() { }
struct PianoRollDemoView: View {

@State var model = PianoRollModel(notes: [
PianoRollNote(start: 1, length: 2, pitch: 3),
PianoRollNote(start: 5, length: 1, pitch: 4)
], length: 128, height: 128)

public var body: some View {
var body: some View {
ScrollView([.horizontal, .vertical], showsIndicators: true) {
PianoRoll(model: $model, noteColor: .cyan)
}.background(Color(white: 0.1))
Expand All @@ -28,9 +26,3 @@ public struct PianoRollDemoView: View {
![Screenshot](screenshot)

Note: Requires macOS 12 / iOS 15 due to SwiftUI bug (crashes in SwiftUI when deleting notes).

## Topics

### <!--@START_MENU_TOKEN@-->Group<!--@END_MENU_TOKEN@-->

- <!--@START_MENU_TOKEN@-->``Symbol``<!--@END_MENU_TOKEN@-->

0 comments on commit 26c34a8

Please sign in to comment.