Giter Site home page Giter Site logo

webquills's Introduction

WebQuills: A Django Publishing System

Webquills is an example of how to construct a publishing system with Django, using development best practices.

  • Configuration from environment variables using django-environ
  • Unit testing with pytest
  • Testing matrix against multiple Python and Django versions using tox
  • Tests include checks for missing migrations and code style (code formatted with Black)
  • Continuous integration testing using Github Actions workflows
  • Python dependencies managed with pip-tools for consistent repeatable builds (transitive dependencies are locked)
  • Tedious functions automated with the run script

Key architectural features of the software include:

  • Multi-tenant using a custom Sites framework compatible with Django's Sites framework
  • Themes installable as Django apps (theming is still a work in progress)

webquills's People

Contributors

veselosky avatar dependabot[bot] avatar

Watchers

James Cloos avatar

webquills's Issues

Site home page

Complete the design and construction of the site home page.

  • FeaturedArticle component
  • ArticleList component
  • HomePage context to include queries for featured and article list
  • Constrain HomePage to only exist at top level of tree

Expand Theme capabilities to support multiple sites

The current theme is pretty inflexible and doesn't allow much variation between sites (fonts, color schemes, alternate layouts). Things that should be customizable:

  • Base stylesheet (select from original Bootstrap or a Bootswatch variant)
  • Customization stylesheet (loaded after Bootstrap)
  • Menu editor (allow ordering of menu items)
  • Sidebar modules (probably a separate story of its own)
  • Footer modules (probably same as sidebar modules)

Image uploads in TinyMCE

TinyMCE provides client side tools to upload images right in the editor. Requires a server-side handler to catch them.

  • Implement the server-side handler for image upload from TinyMCE
  • Configure the editor appropriately
  • If possible, implement a custom upload function that also submits alt text and other useful fields.

CategoryPage Model

Create a CategoryPage designed to be a parent to BlogPost pages.

  • Has its own content (StreamField)
  • Has its own Featured Image
  • Has an optional Featured Post area for promoting a specific BlogPost in that category
  • Displays a list of its child pages in reverse chronological order.

Site RSS Feed

Add a site RSS feed that lists BlogPosts and TopicPages, but ignores other classes of Page.

Multi-tenancy research

Multi-tenancy is not fully supported in Wagtail, in that there are several places where isolation between sites is not preserved. Research and document the issues that will need to be overcome for multi-tenancy for 1.0.

Authors, Bylines, and Credits

Reworking the older Attribution model. Site design calls for About (the author) module on Article pages. Bits of data we need for display:

Author Model

  • Byline: text only. A name and possibly title, to be used in Article byline module.
  • About: HTML. About the author has a headline and text. Text may contain paragraphs, images, links, etc.
  • Copyright Holder: optional Name to be referenced in copyright notice. Separate from byline.
  • If Copyright holder, copyright year is taken from the publication date. If not, the default notice will not be displayed. In that case you should provide custom Copyright License text, e.g. explaining public domain status.
  • Copyright License: HTML block to follow copyright notice. FK to license table, but can also be custom HTML. If empty, default to "All rights reserved" (translated).

Other Models

  • All copyrightable objects should have optional Credits: HTML field for additional attributions like editing, fact-checking, etc.
  • All copyrightable objects should have optional FK to Author(on_delete=PROTECT), optional override fields for the fields of Author, and properties that delegate appropriately.
  • SiteMeta should have an optional default Author(on_delete=SET_NULL).

HomePage CTA module

Refine the CTA Snippet model and template so that it works and looks good.

Sites framework

Integrate the Sites framework with the content models to make it possible to manage multiple sites.

Category Page Header Design

The intro and right hand image looks janky with the current image size. Try some different iterations to get an attractive layout that works well responsively.

Deep Topic Page

Add a model for a Deep Topic Page. This page will be long-form content with the goal of ranking for some specific search term.

Generic Page Model

Create model for a generic page, just a container for a StreamField. Include template and CSS to render it.

Extend Sites framework

Add a Webquills Sites framework that extends the Django one, with the following improvements:

  • Extend the Site model to include Webquills SiteMeta fields (subclass it so things that expect Django sites will still work)
  • Sites middleware should load the Webquills Site object, adding appropriate select_related
  • Sites middleware should select the request.site based on host, using SITE_ID as the fallback if no match (Django prefers SITE_ID, using host only if SITE_ID is not set)
  • Add a post_save signal for the Django Site model to ensure that a Webquills Site always exists for any Django Site

Pagination in Article Lists

The "Older" and "Newer" links should be hidden when not needed, and should actually do something once there are enough articles that we need to paginate them.

ArticlePage model and template

Create a generic Article Page with template.

  • Streamfield for content
  • Heading block with auto-link
  • Published and Updated properties that do the right thing(TM)
  • Featured image
  • Tagging for internal use only
  • Excerpt support for teases/feeds

Basic HomePage model

Create a basic HomePage model with site metadata and a StreamField. Include a base template and CSS to render the page.

Improve ImageBlock to allow new use cases

Current ImageBlock implementation only works for full width images. Tasks:

  • Enable portrait-left images (floats left, text wraps)
  • Enable portrait-right images (floats right, text wraps)
  • Enable link target for images (wraps image in a-href)

Excerpt for Article Pages

Implement an Excerpt function to provide an excerpt for Article previews in Article Lists (and a target for the Continue Reading link).

Sidebar "Follow" Section

Populate the sidebar "Follow" section with site social media links and a link to the site RSS reed.

Generic CTA Block

Create a Block that presents a Call To Action, similar to the CTA section of the bakery demo home page. Background image, Text, and Action Button.

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    ๐Ÿ–– Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. ๐Ÿ“Š๐Ÿ“ˆ๐ŸŽ‰

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google โค๏ธ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.