Skip to content

Commit

Permalink
missed replacing a janky job picker
Browse files Browse the repository at this point in the history
  • Loading branch information
aapis committed Jan 14, 2023
1 parent b32dc91 commit 5a34efb
Show file tree
Hide file tree
Showing 2 changed files with 3 additions and 14 deletions.
4 changes: 2 additions & 2 deletions DLPrototype.xcodeproj/project.pbxproj
Original file line number Diff line number Diff line change
Expand Up @@ -912,7 +912,7 @@
"CODE_SIGN_IDENTITY[sdk=macosx*]" = "Apple Development";
CODE_SIGN_STYLE = Automatic;
COMBINE_HIDPI_IMAGES = YES;
CURRENT_PROJECT_VERSION = 61;
CURRENT_PROJECT_VERSION = 62;
DEAD_CODE_STRIPPING = YES;
DEVELOPMENT_ASSET_PATHS = "\"DLPrototype/Preview Content\"";
DEVELOPMENT_TEAM = 6DT7L2N5X6;
Expand Down Expand Up @@ -940,7 +940,7 @@
"CODE_SIGN_IDENTITY[sdk=macosx*]" = "Apple Development";
CODE_SIGN_STYLE = Automatic;
COMBINE_HIDPI_IMAGES = YES;
CURRENT_PROJECT_VERSION = 61;
CURRENT_PROJECT_VERSION = 62;
DEAD_CODE_STRIPPING = YES;
DEVELOPMENT_ASSET_PATHS = "\"DLPrototype/Preview Content\"";
DEVELOPMENT_TEAM = 6DT7L2N5X6;
Expand Down
13 changes: 1 addition & 12 deletions DLPrototype/Views/Notes/NoteCreate.swift
Original file line number Diff line number Diff line change
Expand Up @@ -21,16 +21,6 @@ struct NoteCreate: View {
CoreDataJob(moc: moc).all()
}

private var pickerItems: [CustomPickerItem] {
var items: [CustomPickerItem] = [CustomPickerItem(title: "Choose a job", tag: 0)]

for job in jobs {
items.append(CustomPickerItem(title: job.jid.string, tag: Int(job.jid)))
}

return items
}

var body: some View {
if showForm {
form
Expand All @@ -45,8 +35,7 @@ struct NoteCreate: View {
VStack(alignment: .leading) {
VStack(alignment: .leading, spacing: 22) {
Title(text: "Create a note", image: "note.text.badge.plus")

FancyPicker(onChange: pickerChange, items: pickerItems, transparent: true, labelText: "Job: \(selectedJob?.jid.string ?? "N/A")", showLabel: true)
JobPicker(onChange: pickerChange)
FancyTextField(placeholder: "Title", lineLimit: 1, onSubmit: {}, text: $title)

FancyTextField(placeholder: "Content", lineLimit: 20, onSubmit: {}, transparent: true, text: $content)
Expand Down

0 comments on commit 5a34efb

Please sign in to comment.