Giter VIP home page Giter VIP logo

pyramid_localize's Introduction

Hi there ๐Ÿ‘‹

Fizyk's GitHub stats

Top Langs

mirakuru pytest-postgresql pytest-redis pytest-elasticsearch

pyramid_localize's People

Contributors

dependabot-preview[bot] avatar dependabot[bot] avatar fizyk avatar github-actions[bot] avatar merger-application[bot] avatar merwok avatar requires avatar rmed avatar

Stargazers

 avatar  avatar  avatar

Watchers

 avatar  avatar  avatar

pyramid_localize's Issues

Simple textarea editor

Create a simple textarea editor for .po files

Each .po file would be opened in textarea field with save button which will write modified data back into .po file.

Store a backup copy as well and create a button to revert to recent backup.

tests to 60%

Add tests, and bring test coverage at least to 60% before the release

Ability to set alternate content links leading to same page in different language

Page might have different slug (not onky the language prefix might differ).

There should be possibility to create a collection of urls for given route leading to same destination, but in different language.

Preferably, all these links should be injected into document's head with

<link rel="alternate" hreflang="<locale>" type="text/html" href="<translated_uri>"/>

SQLAlchemy translation mixin

Idea is to have a translation mixin that will be able to extend model dev want to have tranmslated with submodel that will take some of the fields from master model, and adds relation to master model and to pyramid_localize.models.Language to detect a language. We would have to mark some fields as translatable on master model (new field type?)

Rough idea of how it should look like within python

class Post(LocalizeMixin, Base):
    # ....

post = Post()

assert isinstance(post.translations[0], Post.I18n)

Both Post and Post.I18n should be valid sqlalchemy.

Also Post should retrieve getitme method, that would return requested translation,

post = Post()

assert isinstance(post['en'], Post,I18n)

Integrate pycountry

Integrate pycountry into the locale model, we should be able to return data from pycountry, throu Language model (specific data based on the Language instance - language_code dependant)

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.