mirror of
https://codeberg.org/forgejo/forgejo
synced 2025-09-17 01:12:52 +02:00
Related: https://codeberg.org/forgejo/forgejo/pulls/6977/files#diff-fd05eba523810d46c7763db938ad5839372a074a, https://codeberg.org/forgejo/forgejo/pulls/3949, https://codeberg.org/forgejo/forgejo/pulls/7906 * use the new noJS dropdown for extra actions in org view (currently only includes report button) * this required some refactoring of the area because the said dropdown was not built to be placed in an area where `font-size:36px` is forced onto everything * this greatly improves consistently with user profiles which now use this type of dropdown * I decided against making the opener button mimicrate an actual button because it looks ok as is and is consitent with menu in user profiles and because I don't think this is a good design language to make a kebab menu opener look this way * add icon to the entry * add atom entry Reviewed-on: https://codeberg.org/forgejo/forgejo/pulls/8572 Reviewed-by: Gusted <gusted@noreply.codeberg.org> Reviewed-by: Beowulf <beowulf@beocode.eu> Co-authored-by: 0ko <0ko@noreply.codeberg.org> Co-committed-by: 0ko <0ko@noreply.codeberg.org>
53 lines
2.5 KiB
Go HTML Template
53 lines
2.5 KiB
Go HTML Template
<div class="ui container tw-flex tw-gap-x-4">
|
|
{{ctx.AvatarUtils.Avatar .Org 100 "org-avatar"}}
|
|
<div id="org-info" class="tw-flex tw-flex-col">
|
|
<div class="org-header tw-flex">
|
|
<div class="org-title">
|
|
<h1>{{.Org.DisplayName}}</h1>
|
|
<span class="org-visibility">
|
|
{{if .Org.Visibility.IsLimited}}<span class="ui large horizontal label">{{ctx.Locale.Tr "org.settings.visibility.limited_shortname"}}</span>{{end}}
|
|
{{if .Org.Visibility.IsPrivate}}<span class="ui large horizontal label">{{ctx.Locale.Tr "org.settings.visibility.private_shortname"}}</span>{{end}}
|
|
</span>
|
|
</div>
|
|
<span class="button-sequence tw-items-center tw-ml-auto tw-whitespace-nowrap">
|
|
{{if .IsSigned}}
|
|
{{template "org/follow_unfollow" .}}
|
|
{{end}}
|
|
{{if .IsOrganizationMember}}
|
|
<a class="ui basic button" href="{{.OrgLink}}/dashboard">{{ctx.Locale.Tr "org.open_dashboard"}}</a>
|
|
{{end}}
|
|
{{$moderationEntryNeeded := and .IsModerationEnabled .IsSigned (not .IsOrganizationOwner)}}
|
|
{{if or .EnableFeed $moderationEntryNeeded}}
|
|
<details class="dropdown dir-rtl">
|
|
<summary data-tooltip-content="{{ctx.Locale.Tr "profile.actions.tooltip"}}">{{svg "octicon-kebab-horizontal" 20}}</summary>
|
|
<ul>
|
|
{{if .EnableFeed}}
|
|
<li>
|
|
<a class="item" href="{{.Org.HomeLink}}.rss">{{svg "octicon-rss"}}{{ctx.Locale.Tr "rss_feed"}}</a>
|
|
</li>
|
|
<li>
|
|
<a class="item" href="{{.Org.HomeLink}}.atom">{{svg "octicon-rss"}}{{ctx.Locale.Tr "feed.atom.link"}}</a>
|
|
</li>
|
|
{{end}}
|
|
{{if $moderationEntryNeeded}}
|
|
<li>
|
|
<a class="item orange text" href="{{AppSubUrl}}/report_abuse?type=org&id={{$.Org.ID}}">{{svg "octicon-stop"}}{{ctx.Locale.Tr "moderation.report_abuse"}}</a>
|
|
</li>
|
|
{{end}}
|
|
</ul>
|
|
</details>
|
|
{{end}}
|
|
</span>
|
|
</div>
|
|
{{if .RenderedDescription}}<div class="render-content markup">{{.RenderedDescription}}</div>{{end}}
|
|
<div class="text light meta tw-mt-1">
|
|
{{if .Org.Location}}<div class="flex-text-block">{{svg "octicon-location"}} <span>{{.Org.Location}}</span></div>{{end}}
|
|
{{if .Org.Website}}<div class="flex-text-block">{{svg "octicon-link"}} <a class="muted" target="_blank" rel="noopener noreferrer me" href="{{.Org.Website}}">{{.Org.Website}}</a></div>{{end}}
|
|
{{if .IsSigned}}
|
|
{{if .Org.Email}}<div class="flex-text-block">{{svg "octicon-mail"}} <a class="muted" href="mailto:{{.Org.Email}}">{{.Org.Email}}</a></div>{{end}}
|
|
{{end}}
|
|
</div>
|
|
</div>
|
|
</div>
|
|
|
|
{{template "org/menu" .}}
|