Saravanan666/pypi-org huggingface dataset:
Package: wagtailmakeup
Wagtail MakeupTired of having no images locally when you need them? Don't want to fill your computer up with images?
Use Wagtail Makeup ;)InstallationWagtail makeup depends on python unsplash:pipinstallpython-unsplashwagtailmakeupConfigurationSign up for an Unsplash api key and add this to your settings:# settings.pyWAGTAIL_UNSPLASH={"CLIENT_ID":"","CLIENT_SECRET":""}The API is rate limited to 50 request/hour... you can apply for ahigher rate limit.UsingYou probably don't want this in your production settings, so add the following to you local.py settings:INSTALLED_APPS.append('wagtailmakeup')Wagtail Makeup works by providing a new management command:pythonmanage.pymake_up[searchquery][amountofimages]So you want to replace all your broken images on your site with dogs (who wouldn't)
you can do it like this:pythonmanage.pymake_updogs10Note: the amount value is the number of images to download, the higher this is, the more variance you will get 😎ContributingContributions are welcome, please see ourcontributing guidefor more details.
Package: wagtail-managed404
wagtail_managed404Easily manage 404s from the wagtail adminFree software: MIT licenseDocumentation:https://wagtail-managed404.readthedocs.io.FeaturesMonitor 404 responses served by your wagtail projectAdd permanent or non-permanent redirects, as neededCreditsThis package was created withCookiecutterand theaudreyr/cookiecutter-pypackageproject template.History0.1.2 (2018-10-02)Don’t use parentalkey to refer to page from entry0.1.1 (2018-08-27)Fix configuration issue (add migrations to pip package)0.1.0 (2018-08-27)First release on PyPI.
Package: wagtail-maps
wagtail-mapsCreate and display maps with points in Wagtail.Warning!This project is still early on in its development lifecycle. It is
possible for breaking changes to occur between versions until reaching a stable
1.0. Feedback and pull requests are welcome.This package extend Wagtail to add a new Map model, which is composed by one or
more points. Each point may have a title, some content and link to an internal
or external URL. Once you have configured your map from the Wagtail admin, you
will be able to display it in a page - e.g. as a StreamField block.RequirementsThis package requires the following:Wagtail(4.1 LTS, 5.0)Django(3.2 LTS, 4.2 LTS)Python 3(3.8, 3.9, 3.10, 3.11)InstallationInstall usingpip:pipinstallwagtail-mapsAddwagtail_mapsto yourINSTALLED_APPSsetting:INSTALLED_APPS=[# ...'wagtail_maps',# ...]Include the URL ofwagtail-mapsto yoururls.pyfile:fromwagtail_mapsimporturlsaswagtailmaps_urlsurlpatterns=[# ...path('maps/',include(wagtailmaps_urls)),# ...]Runpython manage.py migrateto create the modelsUsageA StreamField blockwagtail_maps.blocks.MapBlockcan be used to display a
givenMapobject with its points in your page. To render this block in your
frontend, you will have to include the following assets in the templates which
can contain it - or in your base template:the JavaScript code that renders the map withLeafletthanks to aStimuluscontroller:<script src="{%static"wagtail_maps/js/map-block.js"%}"></script>the default Leaflet stylesheet if you don't provide your own:<link rel="stylesheet" href="{%static"wagtail_maps/vendor/leaflet.css"%}">DevelopmentQuick startTo set up a development environment, ensure that Python 3 is installed on your
system. Then:Clone this repositoryCreate a virtual environment and activate it:python3-mvenvvenvsourcevenv/bin/activateInstall this package and its requirements:(venv)$pipinstall-rrequirements-dev.txtContributingThe tests are written withpytestand code coverage is measured withcoverage.
You can use the following commands while developing:make test: run the tests and output a quick report of code coveragemake test-wip: only run the tests marked as 'wip'make test-all: run the tests on all supported versions of Django and
Wagtail withnoxThe Python code is formatted and linted thanks toflake8,isortandblack.
All of these tools are configured inpre-commitand you should consider to
install its git hook scripts by running:(venv)$pre-commitinstallWhen submitting a pull-request, please ensure that the code is well formatted
and covered, and that all the tests pass.LicenseThis extension is mainly developed byCliss XXIand
licensed under theAGPLv3+. Any contribution is welcome!
Package: wagtailmarkdownblock
Wagtail Markdown BlockPLEASE NOTE:Future development on this package will be limited, since most of the features are now included in the new Draftail editor available in Wagtail. Thank you to everyone who contributed!Markdown blocks for Wagtail Streamfields.This Django app uses theSimpleMDEMarkdown editor in the Wagtail Admin and the website.Example Usagefrom wagtailmarkdownblock.blocks import MarkdownBlock

class ContentStreamBlock(StreamBlock):
    paragraph = RichTextBlock()
    heading = TextBlock()
    code = MarkdownBlock()ContributorsTimothy Allen (https://github.com/FlipperPA)Milton Lenis (https://github.com/MiltonLn)Mathias Picker (https://github.com/mathiasp)Tobias Ernst (https://github.com/to-bee)
Package: wagtail-marketing-addons
About wagtail-marketing-addonsAn (opinionated) overview of all pages and their corresponding promotion settings.SupportWagtail 2.11 and higherUse-caseWhen dealing with large amounts of pages the content editor experience differs from a marketeer's editor experience. A marketeer would more likely want to see what page options were set for SEO and SEA purposes. In this case it can be quite a burden to go through the page explorer, verifying whether the page title, SEO title and search description were set properly.SolutionThe SEO Listing within thewagtail-marketing-addonswill show:An overview of all pages in a single list;Relevant properties: page title, SEO title, search description;A preview what it could look like in a search engine;A basic score indicating how this would perform in terms of word and character count.Things to considerAs stated this plugin contains an opinionated perspective on how you would handle your HTML rendering. With this use-case and solution we're assuming the following rationale on your page:<title>{% if self.seo_title %}{{ self.seo_title }}{% else %}{{ self.title }}{% endif %} | Your Site</title><metaname="description"content="{% if self.search_description %}{{ self.search_description }}{% endif %}">In this case your SEO title (when filled in) has a greater priority over the Page Title.DocumentationFor more information on getting started, an overview of all available settings and the rationale behind the scoring mechanism please seeour documentation on Read the Docs.
Package: wagtail-materializecss
# wagtail_materializecssStyle your wagtail pages with materializecss!Run the demo project to see how it in action.### Includes* Demo project to show how you may want to style a page* Component blocks* Badge* Breadcrumb* Button* Card* Collection* FAB* Footer* Icon* links* Navbar* Preloader* Scrollspy (table of contents)* MaterializePage with base.html* Default page variables to style the navbar and footer* Additionally includes Abstract models Navbar and Footer* Functions to get common components for StreamFields* get_headings(exclude=None) - Return h1, h2, h3, h4, h5, h6 tags with scrollspy table of contetns support* get_components(exclude=None) - Returns blocks for Card, Collection, Button, Icon, ...* get_footer_blocks(exclude=None) - Returns common components that someone might want in a footer.## Example Page![Example Page](./example_page.PNG)![Example Admin](example_admin.PNG)```pythonfrom django.db import modelsfrom wagtail.core.fields import StreamField, RichTextFieldfrom wagtail.admin.edit_handlers import FieldPanel, StreamFieldPanel, MultiFieldPanel, FieldRowPanelfrom wagtail.images.edit_handlers import ImageChooserPanelfrom wagtail.core.blocks import RichTextBlockfrom wagtail_materializecss.models import MaterializePage, get_headings, get_componentsfrom wagtail_materializecss.components import Collectionclass BloggerHomePage(MaterializePage):author = models.CharField(max_length=255)background_image = models.ForeignKey('wagtailimages.Image', on_delete=models.SET_NULL, null=True, related_name='+')user_image = models.ForeignKey('wagtailimages.Image', on_delete=models.SET_NULL, null=True, related_name='+')body = StreamField([*get_headings(exclude=['h6']),('paragraph', RichTextBlock(icon='pilcrow')),('collection', Collection()),*get_components(),])content_panels = MaterializePage.content_panels + [MultiFieldPanel([FieldPanel('author'),ImageChooserPanel('background_image'),ImageChooserPanel('user_image'),], heading="Author Fields",),FieldPanel('intro', classname="full"),]```Template```djangotemplate{% extends "wagtail_materializecss/base.html" %}{% load static wagtailcore_tags wagtailimages_tags wagtail_materializecss_tags %}{% block body_class %}template-bloggerhomepage{% endblock %}{% block before_container %}<div class="row">{% image page.background_image original as page_image %}<div class='hero-image' style="background-image: url('{{ page_image.url }}')"></div></div>{% endblock %}{% block content %}<div class="row"><div class="col s12 m4 right" style="margin-top: 1rem;">{% image page.user_image fill-200x200 class="responsive-img circle center-object" %}<h3 class="center-object {{ page.color }}-text">{{ page.author }}</h3></div><div class="col s12 m8"><h1 class="{{ page.color }}-text scrollspy">Introduction</h1>{% include_block page.body %}</div></div><div class="row"><h5>Posts</h5><div class="divider"></div>{% for post in blogpages %}<div class="col s12 m6 l4">{% make_link None "Go to Post" post.specific as post_link %}{% make_card post.specific.title post.specific.description post_link size='small' %}</div>{% endfor %}</div>{% endblock %}```
Package: wagtailmath
WagtailMath allows you to write equations in yourWagtailcontent using markup and render them beautifully.WagtailMath provides aMathBlockso you can write equations in markup (TeX, MathML, ASCIIMath) and render them with MathJax.
It features a live preview:MathBlockuses MathJax for rendering so there is very little to do on the front end. Simply include
the MathJax JS and render the rawMathBlockcontent as you would for any other streamfield plain text block.WagtailMath even includes a template tag to include the MathJax JS for you from a CDN.
By default, MathJax is configured to accept all recognised markup (TeX, MathML, ASCIIMath) and renders them to HTML.
To change the configuration, you can pass the desired config command to the templatetag.
Seehttp://docs.mathjax.org/en/latest/config-files.html#combined-configurationsfor possible configurations.For help on using the markup languages see the relevant MathJax documentation (e.g.http://docs.mathjax.org/en/latest/tex.html)
and the markup language-specific documentation (e.g.https://en.wikibooks.org/wiki/LaTeX)QuickstartInstall wagtailmath:pip install wagtailmathAdd it to yourINSTALLED_APPS:INSTALLED_APPS=(...'wagtailmath',...)UseMathBlockin yourStreamFieldcontent:fromwagtailmath.blocksimportMathBlockclassMyPage(Page):body=StreamField([('heading',blocks.CharBlock(classname="full title")),('paragraph',blocks.RichTextBlock()),('equation',MathBlock())])Use themathjaxtemplate tag in your front end template to load the MathJax library:{%loadwagtailmath%}...

<script src="{%mathjax%}"></script>History1.2.0 (TBD)Upgrade to newer version of Django + Wagtail0.1.0 (2017-04-24)First release on PyPI.
Package: wagtail_mautic
wagtail-mauticAdds Mautic Marketing Automation into a Wagtail site with a few simple template tagsInstallationInstall using pippip install wagtail-mauticNow add the applicationwagtail_mauticto your Django applications. In yourbase.pysettings file:INSTALLED_APPS=[..."wagtail.contrib.settings","wagtail_mautic",...]Add the site settings to your context processors:'OPTIONS':{'context_processors':[...'wagtail.contrib.settings.context_processors.settings',]}Migrate your models:python manage.py migrateAdd your Mautic setup informationWhen you spin up your Wagtail app, you should now see a new Mautic settings in the Wagtail admin screen.Add in the URL for your Mautic instance (including the https://) to theMautic Urlfield.Add Mautic page trackingThe template tag{% mautic_tracker %}can be added to any page and this will add in the Mautic tracking code. The tag will only add text when the Mautic URL has been added in the settings.To install site-wide add this to yourbase.htmltemplate or similar.Recommended placement is to add the tracking code as the last item in the<body> ... </body>tag section.Add Mautic prefetch tagsFor faster loading of pages, the Mautic site can be set up with a pre-fetch<link>in the header.  To add this to your site, add the{% mautic_prefetch %}tag within the<head></head>of your templates.
Package: wagtailmenus
wagtailmenuswagtailmenus is an extension for Torchbox’sWagtail CMSto help you manage and render multi-level navigation and simple flat menus in a consistent, flexible way.The current version is tested for compatibility with the following:Wagtail versions >= 4.1Python versions 3.8 to 3.11New to wagtailmenus?Start by reading ourOverview and key conceptspage.
It will give you a better understand of how the app works, and help you decide whether it is a good fit for your project.How do I use it?For everything you need to get up and running with wagtailmenus,view the official documentation.ContributingInstructions on how to contribute can be foundhere.As we are members of aJazzBand project,wagtailmenuscontributors should adhere to theContributor Code of Conduct.
Package: wagtail-metadata-mixin
OpenGraph, Twitter Card and Schema.org snippet tags for Wagtail CMS pages.The current version is tested for compatiblily with the following:Wagtail versions 2.7 to 2.15Django versions 2.2 to 3.2Python versions 3.6 and 3.9Authored byBasil Shubin,  and some greatcontributors.InstallationFirst install the module, preferably in a virtual environment. It can be installed from PyPI:pipinstallwagtail-metadata-mixinRequirementsYou must havedjango-metainstalled and configured, see thedjango-metadocumentation for details and setup instructions.SetupFirst make sure the project is configured fordjango-meta.Then add the following settings:INSTALLED_APPS+=('wagtailmetadata',)and just includemeta/meta.htmltemplate in your templates{%loadmeta%}<html{%meta_namespaces_schemaorg%}><head{%meta_namespaces%}>{%include"meta/meta.html"%}</head><body>...</body></html>Checkdjango-metadocumentation for more details.Usage# models.pyfromwagtail.core.modelsimportPage,PageBasefromwagtailmetadata.modelsimportMetadataPageMixin# ensure MetadataPageMixin class goes before Page classclassCustomPage(MetadataPageMixin,Page):schemaorg_type="Page"promote_panels=Page.promote_panels+MetadataPageMixin.panelsContributingIf you like this module, forked it, or would like to improve it, please let us know!
Pull requests are welcome too. :-)Licensewagtail-metadata-mixinis released under the MIT license.Changes2.0.2 (2021-11-29)Fixed stupid typo.2.0.1 (2021-11-29)Added ru translation.2.0.0 (2021-11-28)Added Wagtail 2.15 and Django 3.2 support.Dropped Wagtail 2.7 support.
Package: wagtail-meta-preview
wagtail meta previewCurrent supported versionsWagtail Meta Preview requires Wagtail 4.1+PreviewWagtail Meta Preview provides panels for previewing Facebook sharing, Twitter sharing and Google search results in the Wagtail admin.
Example of how the Facebook share looks like:DocumentationGetting startedSetting up panelsSettingsDevelopmentDev serverThe easiest way is to clone this repo, cd into it and justdocker-compose up, this should
start a server onhttp://localhost:8123/admin/(user: admin, pw: admin) with a couple of page types to test with.Running testsdocker-compose exec web python runtests.pyLicenseWagtail Meta Preview is released under theMIT License.
Package: wagtail-modeladmin
Wagtail ModelAdminAdd any model in your project to the Wagtail admin. Formerlywagtail.contrib.modeladmin.This package is in maintenance mode and will not receive new features. Considermigrating to Snippetsand opening new feature requests in theWagtail issue tracker.LinksDocumentationChangelogContributingDiscussionsSecuritySupported versionsPython 3.8, 3.9, 3.10, 3.11, 3.12Django 4.2, 5.0Wagtail 5.2, 6.0Installationpython -m pip install wagtail-modeladminAddwagtail_modeladminto yourINSTALLED_APPSsetting.INSTALLED_APPS=[# ..."wagtail_modeladmin",# ...]ContributingInstallTo make changes to this project, first clone this repository:gitclonehttps://github.com/wagtail-nest/wagtail-modeladmin.gitcdwagtail-modeladminWith your preferred virtualenv activated, install testing dependencies:Using pippython-mpipinstall--upgradepip>=21.3
python-mpipinstall-e.[testing]-UUsing flitpython-mpipinstallflit
flitinstallpre-commitNote that this project usespre-commit.
It is included in the project testing requirements. To set up locally:# go to the project directory$cdwagtail-modeladmin# initialize pre-commit$pre-commitinstall# Optional, run all checks once for this, then the checks will run only on the changed files$gitls-files--others--cached--exclude-standard|xargspre-commitrun--filesHow to run testsNow you can run tests as shown below:toxor, you can run them for a specific environmenttox -e python3.10-django4.2-wagtail4.1or specific testtox -e python3.10-django4.2-wagtail4.1-sqlite wagtail-modeladmin.tests.test_file.TestClass.test_methodTo run the test app interactively, usetox -e interactive, visithttp://127.0.0.1:8020/admin/and log in withadmin/changeme.
Package: wagtail-modeladmin-sortable
wagtail-modeladmin-sortableGeneric drag-and-drop ordering for objects in the Wagtail admin interfaceQuick startInstallwagtail_modeladmin_sortable$pipinstallwagtail-modeladmin-sortableAddwagtail_modeladmin_sortabletoINSTALLED_APPSthe settings of your Django project:INSTALLED_APPS=[...'wagtail_modeladmin_sortable',]Integrate your modelsfromdjango.dbimportmodelsfromwagtail_modeladmin_sortable.modelsimportAdminSortableclassExample(AdminSortable):title=models.CharField('Title',max_length=255,null=True,blank=True)classMeta(AdminSortable.Meta):verbose_name="Example"verbose_name_plural="Examples"In wagtail_hooks.py, add a mixin class to augment the functionality for sorting (be sure to put the mixin class before ModelAdmin):fromwagtail.contrib.modeladmin.optionsimportModelAdminfromwagtail_modeladmin_sortable.mixinsimportModelAdminSortableMixinclassExampleAdmin(ModelAdminSortableMixin,ModelAdmin):passLicenseCopyright © 2021 Stanislav Lazarov.MIT licensed.
Package: wagtail-modelchooser
A plugin for Wagtail that provides convenience methods for setting up chooser modals
for arbitrary models.InstallingInstall using pip:pip install wagtail-modelchooserThen add it to yourINSTALLED_APPS:INSTALLED_APPS=[# ...'wagtailmodelchooser',# ...]It works with Wagtail 4.0 and upwards.
For older versions of Wagtail check previous versions of the package.Quick startTo enable the chooser for your model, you must register the model.
For simple cases, decorate your model with@register_model_chooser:fromdjango.dbimportmodelsfromwagtailmodelchooserimportregister_model_chooser@register_model_chooserclassAuthor(models.Model):name=models.CharField(max_length=255)def__str__(self):# The ``str()`` of your model will be used in the chooserreturnself.nameYou can then use eitherFieldPanelin an edit handler definition,
orModelChooserBlockin aStreamFielddefinition:fromwagtail.wagtailcore.blocksimportRichTextBlockfromwagtail.wagtailcore.fieldsimportStreamFieldfromwagtail.wagtailcore.modelsimportPagefromwagtail.wagtailadmin.edit_handlersimportFieldPanelfromwagtailmodelchooser.blocksimportModelChooserBlockclassBook(Page):name=models.CharField(max_length=255)author=models.ForeignKey(Author)content_panels=[FieldPanel('name'),FieldPanel('author'),]classContentPage(Page):body=StreamField([('text',RichTextBlock()),('author',ModelChooserBlock('books.Author')),])content_panels=[StreamFieldPanel('body'),]Customisation optionsIf you want to customize the content or behaviour of the model chooser modal you have several options. These are illustrated through some examples below.If you wanted to add an additional filter field to the popup, you might do that as follows:fromdjango.dbimportmodelsfromwagtailmodelchooserimportregister_model_chooser,ChooserclassCity(models.Model):name=models.CharField(max_length=255)capital=models.BooleanField()def__str__(self):# The ``str()`` of your model will be used in the chooserreturnself.name@register_model_chooserclassCityChooser(Chooser):model=Citymodal_template='app_name/city_modal.html'modal_results_template='app_name/city_modal_results.html'defget_queryset(self,request):qs=super().get_queryset(request)ifrequest.GET.get('capital'):qs=qs.filter(capital=request.GET.get('capital')=='0')returnqsSince wagtailmodelchooser is built largely on theChooserViewSetfunctionality already found in Wagtail, if you wish to do deeper customisation it is recommended to use that feature directly.
Package: wagtail-modelchooser-1.13.1
A plugin for Wagtail that provides aModelChooserPanelandModelChooserBlockfor arbitrary models.InstallingInstall using pip:pip install wagtail-modelchooserThen add it to yourINSTALLED_APPS:INSTALLED_APPS=[# ...'wagtailmodelchooser',# ...]It works with Wagtail 1.4 and upwards.Quick startTo enable the chooser for your model, you must register the model.
For simple cases, decorate your model with@register_model_chooser:fromdjango.dbimportmodelsfromwagtailmodelchooserimportregister_model_chooser@register_model_chooserclassAuthor(models.Model):name=models.CharField(max_length=255)def__str__(self):# The ``str()`` of your model will be used in the chooserreturnself.nameYou can then use eitherModelChooserPanelin an edit handler definition,
orModelChooserBlockin aStreamFielddefinition:fromwagtail.wagtailcore.blocksimportRichTextBlockfromwagtail.wagtailcore.fieldsimportStreamFieldfromwagtail.wagtailcore.modelsimportPagefromwagtail.wagtailadmin.edit_handlersimportFieldPanel,StreamFieldPanelfromwagtailmodelchooser.blocksimportModelChooserBlockfromwagtailmodelchooser.edit_handlersimportModelChooserPanelclassBook(Page):name=models.CharField(max_length=255)author=models.ForeignKey(Author)content_panels=[FieldPanel('name'),ModelChooserPanel('author'),]classContentPage(Page):body=StreamField([('text',RichTextBlock()),('author',ModelChooserBlock('books.Author')),])content_panels=[StreamFieldPanel('body'),]