kopia lustrzana https://github.com/wagtail/wagtail
Co-authored-by: Thibaud Colas <thibaudcolas@gmail.com>pull/12086/head
rodzic
bfd7e46496
commit
0913118da4
|
@ -89,6 +89,7 @@ Changelog
|
|||
* Docs: Replace X links with Mastodon in the README (Alex Morega)
|
||||
* Docs: Re-enable building offline formats in online documentation (Read the docs) for EPUB/PDF/HTML downloads (Joel William, Sage Abdullah)
|
||||
* Docs: Resolve multiple output errors in the documentation ePub format (Sage Abdullah)
|
||||
* Docs: Update social media examples to use LinkedIn, Reddit, Facebook (Ayaan Qadri)
|
||||
* Maintenance: Removed support for Python 3.8 (Matt Westcott)
|
||||
* Maintenance: Drop pytz dependency in favour of `zoneinfo.available_timezones` (Sage Abdullah)
|
||||
* Maintenance: Relax django-taggit dependency to allow 6.0 (Matt Westcott)
|
||||
|
|
|
@ -850,6 +850,7 @@
|
|||
* Alessandro Chitarrini
|
||||
* Joel William
|
||||
* Ataf Fazledin Ahamed
|
||||
* Ayaan Qadri
|
||||
|
||||
## Translators
|
||||
|
||||
|
|
|
@ -3,7 +3,7 @@
|
|||
# Embedded content
|
||||
|
||||
Wagtail supports generating embed code from URLs to content on external
|
||||
providers such as YouTube or Twitter. By default, Wagtail will fetch the embed
|
||||
providers such as YouTube or Reddit. By default, Wagtail will fetch the embed
|
||||
code directly from the relevant provider's site using the oEmbed protocol.
|
||||
|
||||
Wagtail has a built-in list of the most common providers and this list can be
|
||||
|
|
|
@ -178,4 +178,4 @@ You can also find more resources from the community on [Awesome Wagtail](https:/
|
|||
## Tip
|
||||
|
||||
We are working on a collection of Wagtail tutorials and best practices.
|
||||
Please tweet [\@WagtailCMS](https://twitter.com/WagtailCMS) or [contact us directly](mailto:hello@wagtail.org) to share your Wagtail HOWTOs, development notes or site launches.
|
||||
Please share your Wagtail HOWTOs, development notes, or site launches in the [Wagtail Slack workspace](https://github.com/wagtail/wagtail/wiki/Slack) in #watercooler, or feel free to reach out directly via [email](mailto:hello@wagtail.org).
|
|
@ -274,13 +274,13 @@ if you have to use multiple values from one model:
|
|||
|
||||
```html+jinja
|
||||
{% with generic_social_settings=settings("app_label.GenericSocialMediaSettings") %}
|
||||
Follow us on Twitter at @{{ generic_social_settings.facebook }},
|
||||
Follow us on Facebook at {{ generic_social_settings.facebook }},
|
||||
or Instagram at @{{ generic_social_settings.instagram }}.
|
||||
{% endwith %}
|
||||
|
||||
{% with site_social_settings=settings("app_label.SiteSpecificSocialMediaSettings") %}
|
||||
Follow us on Twitter at @{{ site_social_settings.facebook }},
|
||||
or Instagram at @{{ site_social_settings.instagram }}.
|
||||
Follow us on Facebook at {{ site_social_settings.facebook }},
|
||||
or Instagram at {{ site_social_settings.instagram }}.
|
||||
{% endwith %}
|
||||
```
|
||||
|
||||
|
|
|
@ -128,6 +128,7 @@ This feature was developed by Bart Cieliński, alexkiro, and Sage Abdullah.
|
|||
* Replace X links with Mastodon in the README (Alex Morega)
|
||||
* Re-enable building offline formats in online documentation (Read the docs) for EPUB/PDF/HTML downloads (Joel William, Sage Abdullah)
|
||||
* Resolve multiple output errors in the documentation ePub format (Sage Abdullah)
|
||||
* Update social media examples to use LinkedIn, Reddit, Facebook (Ayaan Qadri)
|
||||
|
||||
### Maintenance
|
||||
|
||||
|
|
|
@ -315,7 +315,7 @@ Same as `url`, but always returns a full absolute URL. This requires `WAGTAILADM
|
|||
This is useful for images that will be re-used outside of the current site, such as social share images:
|
||||
|
||||
```html+django
|
||||
<meta name="twitter:image" content="{{ tmp_photo.full_url }}">
|
||||
<meta name="og:image" content="{{ tmp_photo.full_url }}">
|
||||
```
|
||||
|
||||
If your site defines a custom image model using `AbstractImage`, any additional fields you add to an image (such as a copyright holder) is **not** included in the rendition.
|
||||
|
|
|
@ -29,14 +29,14 @@ from wagtail.contrib.settings.models import (
|
|||
|
||||
@register_setting
|
||||
class NavigationSettings(BaseGenericSetting):
|
||||
twitter_url = models.URLField(verbose_name="Twitter URL", blank=True)
|
||||
linkedin_url = models.URLField(verbose_name="LinkedIn URL", blank=True)
|
||||
github_url = models.URLField(verbose_name="GitHub URL", blank=True)
|
||||
mastodon_url = models.URLField(verbose_name="Mastodon URL", blank=True)
|
||||
|
||||
panels = [
|
||||
MultiFieldPanel(
|
||||
[
|
||||
FieldPanel("twitter_url"),
|
||||
FieldPanel("linkedin_url"),
|
||||
FieldPanel("github_url"),
|
||||
FieldPanel("mastodon_url"),
|
||||
],
|
||||
|
@ -100,15 +100,15 @@ Create an `includes` folder in your `mysite/templates` folder. Then in your newl
|
|||
<footer>
|
||||
<p>Built with Wagtail</p>
|
||||
|
||||
{% with twitter_url=settings.base.NavigationSettings.twitter_url github_url=settings.base.NavigationSettings.github_url mastodon_url=settings.base.NavigationSettings.mastodon_url %}
|
||||
{% if twitter_url or github_url or mastodon_url %}
|
||||
{% with linkedin_url=settings.base.NavigationSettings.linkedin_url github_url=settings.base.NavigationSettings.github_url mastodon_url=settings.base.NavigationSettings.mastodon_url %}
|
||||
{% if linkedin_url or github_url or mastodon_url %}
|
||||
<p>
|
||||
Follow me on:
|
||||
{% if github_url %}
|
||||
<a href="{{ github_url }}">GitHub</a>
|
||||
{% endif %}
|
||||
{% if twitter_url %}
|
||||
<a href="{{ twitter_url }}">Twitter</a>
|
||||
{% if linkedin_url %}
|
||||
<a href="{{ linkedin_url }}">LinkedIn</a>
|
||||
{% endif %}
|
||||
{% if mastodon_url %}
|
||||
<a href="{{ mastodon_url }}">Mastodon</a>
|
||||
|
@ -302,15 +302,15 @@ Add your `footer_text` template to your footer by modifying your `mysite/templat
|
|||
<footer>
|
||||
<p>Built with Wagtail</p>
|
||||
|
||||
{% with twitter_url=settings.base.NavigationSettings.twitter_url github_url=settings.base.NavigationSettings.github_url mastodon_url=settings.base.NavigationSettings.mastodon_url %}
|
||||
{% if twitter_url or github_url or mastodon_url %}
|
||||
{% with linkedin_url=settings.base.NavigationSettings.linkedin_url github_url=settings.base.NavigationSettings.github_url mastodon_url=settings.base.NavigationSettings.mastodon_url %}
|
||||
{% if linkedin_url or github_url or mastodon_url %}
|
||||
<p>
|
||||
Follow me on:
|
||||
{% if github_url %}
|
||||
<a href="{{ github_url }}">GitHub</a>
|
||||
{% endif %}
|
||||
{% if twitter_url %}
|
||||
<a href="{{ twitter_url }}">Twitter</a>
|
||||
{% if linkedin_url %}
|
||||
<a href="{{ linkedin_url }}">LinkedIn</a>
|
||||
{% endif %}
|
||||
{% if mastodon_url %}
|
||||
<a href="{{ mastodon_url }}">Mastodon</a>
|
||||
|
|
Ładowanie…
Reference in New Issue