Giter Club home page Giter Club logo

wagtail-360's Introduction

Wagtail 360° virtual tours

An admin interface to choose google street view imagery and display an embedded virtual tour.

Powered by google maps Javascript API and Wagtail CMS

Alt text

Installation

Install the package

pip install wagtail-360

Then add wagtail_360 to your installed apps

INSTALLED_APPS = [
    # ...
    "wagtail_360",
    # ...
]

Usage

Add 2 page models.

The Tour Index Page

This represents a virtual tour and is the parent page for each Panorama in this tour.

from wagtail_360.abstract_models import AbstractTour

class TourPage(AbstractTour, Page):
    subpage_types = ["PanoramaPage"]
    content_panels = Page.content_panels + [AbstractTour.panels]

The Panorama Page Model

This represents a single panorama and is used as a child page of a TourPage.

from wagtail_360.abstract_models import AbstractPanorama

class PanoramaPage(AbstractPanorama):
    parent_page_types = ["TourPage"]
    content_panels = Page.content_panels + AbstractPanorama.panels

Then run:

python manage.py makemigrations
python manage.py migrate

Configuration

Set the configuration in your settings.py file

A google maps API key is required. You can generate one at https://developers.google.com/maps/documentation/javascript

The service isn't free but there's a generous free tier available.

GOOGLE_MAPS_API_KEY = "your-google-maps-api-key"

If you don't set the key the panorama images will still display but will be in developer mode.

Build a virtual tour

User docs

Contributing

If you would like to suggest an improvement to the package contributions are welcome

Issues

If you find an issue please consider raising and issue

wagtail-360's People

Contributors

nickmoreton avatar pre-commit-ci[bot] avatar

Stargazers

 avatar

Watchers

 avatar

wagtail-360's Issues

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.