Rename MediaHypha to NonEmptyHypha

This commit is contained in:
Timur Ismagilov
2022-02-19 11:31:54 +03:00
committed by Timur Ismagilov
parent 002e9f7a93
commit 6fc5cf994e
18 changed files with 86 additions and 86 deletions
+2 -2
View File
@@ -75,9 +75,9 @@
</h1>
{% endfunc %}
{% func AttachmentHTMLRaw(h *hyphae.MediaHypha) %}{%= AttachmentHTML(h, l18n.New("en", "en")) %}{% endfunc %}
{% func AttachmentHTMLRaw(h *hyphae.NonEmptyHypha) %}{%= AttachmentHTML(h, l18n.New("en", "en")) %}{% endfunc %}
{% func AttachmentHTML(h *hyphae.MediaHypha, lc *l18n.Localizer) %}
{% func AttachmentHTML(h *hyphae.NonEmptyHypha, lc *l18n.Localizer) %}
{% switch filepath.Ext(h.BinaryPath()) %}
{% case ".jpg", ".gif", ".png", ".webp", ".svg", ".ico" %}
+6 -6
View File
@@ -349,14 +349,14 @@ func NaviTitleHTML(h hyphae.Hypher) string {
}
//line views/hypha.qtpl:78
func StreamAttachmentHTMLRaw(qw422016 *qt422016.Writer, h *hyphae.MediaHypha) {
func StreamAttachmentHTMLRaw(qw422016 *qt422016.Writer, h *hyphae.NonEmptyHypha) {
//line views/hypha.qtpl:78
StreamAttachmentHTML(qw422016, h, l18n.New("en", "en"))
//line views/hypha.qtpl:78
}
//line views/hypha.qtpl:78
func WriteAttachmentHTMLRaw(qq422016 qtio422016.Writer, h *hyphae.MediaHypha) {
func WriteAttachmentHTMLRaw(qq422016 qtio422016.Writer, h *hyphae.NonEmptyHypha) {
//line views/hypha.qtpl:78
qw422016 := qt422016.AcquireWriter(qq422016)
//line views/hypha.qtpl:78
@@ -367,7 +367,7 @@ func WriteAttachmentHTMLRaw(qq422016 qtio422016.Writer, h *hyphae.MediaHypha) {
}
//line views/hypha.qtpl:78
func AttachmentHTMLRaw(h *hyphae.MediaHypha) string {
func AttachmentHTMLRaw(h *hyphae.NonEmptyHypha) string {
//line views/hypha.qtpl:78
qb422016 := qt422016.AcquireByteBuffer()
//line views/hypha.qtpl:78
@@ -382,7 +382,7 @@ func AttachmentHTMLRaw(h *hyphae.MediaHypha) string {
}
//line views/hypha.qtpl:80
func StreamAttachmentHTML(qw422016 *qt422016.Writer, h *hyphae.MediaHypha, lc *l18n.Localizer) {
func StreamAttachmentHTML(qw422016 *qt422016.Writer, h *hyphae.NonEmptyHypha, lc *l18n.Localizer) {
//line views/hypha.qtpl:80
qw422016.N().S(`
`)
@@ -486,7 +486,7 @@ func StreamAttachmentHTML(qw422016 *qt422016.Writer, h *hyphae.MediaHypha, lc *l
}
//line views/hypha.qtpl:109
func WriteAttachmentHTML(qq422016 qtio422016.Writer, h *hyphae.MediaHypha, lc *l18n.Localizer) {
func WriteAttachmentHTML(qq422016 qtio422016.Writer, h *hyphae.NonEmptyHypha, lc *l18n.Localizer) {
//line views/hypha.qtpl:109
qw422016 := qt422016.AcquireWriter(qq422016)
//line views/hypha.qtpl:109
@@ -497,7 +497,7 @@ func WriteAttachmentHTML(qq422016 qtio422016.Writer, h *hyphae.MediaHypha, lc *l
}
//line views/hypha.qtpl:109
func AttachmentHTML(h *hyphae.MediaHypha, lc *l18n.Localizer) string {
func AttachmentHTML(h *hyphae.NonEmptyHypha, lc *l18n.Localizer) string {
//line views/hypha.qtpl:109
qb422016 := qt422016.AcquireByteBuffer()
//line views/hypha.qtpl:109
+1 -1
View File
@@ -11,7 +11,7 @@
{% import "github.com/bouncepaw/mycorrhiza/user" %}
{% import "github.com/bouncepaw/mycorrhiza/util" %}
{% func AttachmentMenuHTML(rq *http.Request, h *hyphae.MediaHypha, u *user.User) %}
{% func AttachmentMenuHTML(rq *http.Request, h *hyphae.NonEmptyHypha, u *user.User) %}
{% code
lc := l18n.FromRequest(rq)
%}
+1 -1
View File
@@ -262,7 +262,7 @@ sort.Strings(editors)
close(hyphaNames)
%}
{% for hyphaName := range sortedHypha %}
{% code hypha := hyphae.ByName(hyphaName).(*hyphae.MediaHypha) %}
{% code hypha := hyphae.ByName(hyphaName).(*hyphae.NonEmptyHypha) %}
<li class="hypha-list__entry">
<a class="hypha-list__link" href="/hypha/{%s hypha.CanonicalName() %}">
{%s util.BeautifulName(hypha.CanonicalName()) %}