Mostly cosmetic changes

This commit is contained in:
Eduard Urbach 2017-10-13 00:44:19 +02:00
parent 37a9e6cbf4
commit 0021ff17df
5 changed files with 44 additions and 32 deletions

View File

@ -49,8 +49,10 @@ func EditForm(obj interface{}, title string) string {
endpoint := `/api/` + lowerCaseTypeName + `/` + id.String() endpoint := `/api/` + lowerCaseTypeName + `/` + id.String()
var b bytes.Buffer var b bytes.Buffer
b.WriteString(`<div class="widget-form">`) b.WriteString(`<div class="widget-form">`)
b.WriteString(`<div class="widget" data-api="` + endpoint + `">`) b.WriteString(`<div class="widget" data-api="` + endpoint + `">`)
b.WriteString(`<h1>`) b.WriteString(`<h1>`)
b.WriteString(title) b.WriteString(title)
b.WriteString(`</h1>`) b.WriteString(`</h1>`)

View File

@ -1,27 +1,32 @@
component Track(track *arn.SoundTrack) component Track(track *arn.SoundTrack)
SoundTrackTabs(track) SoundTrackTabs(track)
if track.Title == "" .sound-track-full-page
h1 untitled if track.Title == ""
else h1.mountable untitled
h1= track.Title
.sound-tracks
SoundTrackAllMedia(track)
.footer.text-center
if track.EditedBy != ""
span Edited
span.utc-date(data-date=track.Edited)
span by
span= track.EditedByUser().Nick
else else
span Posted h1.mountable= track.Title
span.utc-date(data-date=track.Created)
span by .widget-form.sound-track-media-list
span= track.CreatedByUser().Nick each media in track.Media
.widget.mountable
span . h3.widget-title= media.Service
.sound-track-media
ExternalMedia(media)
.footer.text-center.mountable
if track.EditedBy != ""
span Edited
span.utc-date(data-date=track.Edited)
span by
span= track.EditedByUser().Nick
else
span Posted
span.utc-date(data-date=track.Created)
span by
span= track.CreatedByUser().Nick
span .
component SoundTrackTabs(track *arn.SoundTrack) component SoundTrackTabs(track *arn.SoundTrack)
.tabs .tabs

View File

@ -0,0 +1,6 @@
.sound-track-media-list
vertical
.sound-track-media
iframe
width 100%

View File

@ -8,7 +8,6 @@
flex-basis 500px flex-basis 500px
padding 1rem padding 1rem
.sound-track-content .sound-track-content
horizontal horizontal

View File

@ -20,6 +20,17 @@
margin-bottom 1rem margin-bottom 1rem
overflow hidden overflow hidden
.widget-section
vertical
width 100%
.widget-title
text-align left
padding-bottom 0.5rem
border-bottom 1px solid rgba(0, 0, 0, 0.1)
// We need !important here to overwrite the h3:first-child rule
margin 1rem 0 !important
.widget-ui-element .widget-ui-element
vertical-wrap vertical-wrap
ui-element ui-element
@ -36,17 +47,6 @@
align-items center align-items center
width 100% width 100%
.widget-section
vertical
width 100%
.widget-title
text-align left
padding-bottom 0.5rem
border-bottom 1px solid rgba(0, 0, 0, 0.1)
// We need !important here to overwrite the h3:first-child rule
margin 1rem 0 !important
.widget-form .widget-form
width 100% width 100%
max-width 650px max-width 650px