Skip to content
This repository has been archived by the owner on Feb 1, 2019. It is now read-only.

Commit

Permalink
added new version
Browse files Browse the repository at this point in the history
  • Loading branch information
FinalAngel committed Jan 24, 2014
1 parent a18812c commit 1ff3c2a
Show file tree
Hide file tree
Showing 103 changed files with 3,082 additions and 139 deletions.
12 changes: 9 additions & 3 deletions .gitignore
Original file line number Diff line number Diff line change
@@ -1,4 +1,10 @@
*.log
*.pot
*.pyc
dist/*
build/*
*.egg-info/*
.project
.pydevproject
.settings
build
env*
dist
aldryn_style.egg-info
8 changes: 4 additions & 4 deletions LICENSE.txt
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
Copyright (c) 2012, Divio AG
Copyright (c) 2011, Divio AG
All rights reserved.

Redistribution and use in source and binary forms, with or without
Expand All @@ -8,17 +8,17 @@ modification, are permitted provided that the following conditions are met:
* Redistributions in binary form must reproduce the above copyright
notice, this list of conditions and the following disclaimer in the
documentation and/or other materials provided with the distribution.
* Neither the name of Divio AG nor the
* Neither the name of Djeese Factory GmbH nor the
names of its contributors may be used to endorse or promote products
derived from this software without specific prior written permission.

THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS "AS IS" AND
ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED
WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE
DISCLAIMED. IN NO EVENT SHALL DIVIO AG BE LIABLE FOR ANY
DISCLAIMED. IN NO EVENT SHALL DJEESE FACTORY GMBH BE LIABLE FOR ANY

This comment has been minimized.

Copy link
@stefanfoulis

stefanfoulis Nov 3, 2015

Contributor

Looks like you got an old license

DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES
(INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES;
LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND
ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT
(INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS
SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
5 changes: 2 additions & 3 deletions MANIFEST.in
Original file line number Diff line number Diff line change
@@ -1,6 +1,5 @@
include LICENSE.txt
recursive-include aldryn_style/templates *
recursive-include aldryn_style/static *
include README.md
recursive-include aldryn_style/locale *
recursive-include aldryn_style/migrations *
recursive-include aldryn_style/templates *
recursive-exclude * *.pyc
39 changes: 39 additions & 0 deletions README.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,39 @@
aldryn-style
============

A Plugin for django CMS to add CSS classes to other plugins


Installation
------------

This plugin requires `django CMS` 2.4 or higher to be properly installed.

* In your projects `virtualenv`_, run ``pip install aldryn-style``.
* Add ``'aldryn_style'`` to your ``INSTALLED_APPS`` setting.
* Run ``manage.py migrate aldryn_style``.


Usage
-----

You can define styles in your settings.py:

```
CMS_STYLE_NAMES = (
('info', _("info")),
('new', _("new")),
('hint', _("hint")),
)
```

After that you can place other plugins inside this style plugin.
It will create a div with a class that was prior selected around this plugin.

Translations
------------

If you want to help translate the plugin please do it on transifex:

https://www.transifex.com/projects/p/django-cms/resource/aldryn-style/

3 changes: 1 addition & 2 deletions aldryn_style/__init__.py
Original file line number Diff line number Diff line change
@@ -1,2 +1 @@
# -*- coding: utf-8 -*-
__version__ = '0.0.5'
__version__ = "1.0.6"
38 changes: 22 additions & 16 deletions aldryn_style/cms_plugins.py
Original file line number Diff line number Diff line change
@@ -1,23 +1,29 @@
# -*- coding: utf-8 -*-
from django.utils.translation import ugettext_lazy as _

from cms.plugin_base import CMSPluginBase
from cms.plugin_pool import plugin_pool

from aldryn_style import models
from aldryn_style.forms import StyleForm

from cms.plugin_base import CMSPluginBase
from django.utils.translation import ugettext_lazy as _
from cms.models import CMSPlugin
from aldryn_style.models import Style

class StylePlugin(CMSPluginBase):

render_template = 'aldryn_style/style.html'
name = _('Style')
model = models.StylePlugin
model = Style
name = _("Style")
render_template = "cms/plugins/style.html"
allow_children = True
form = StyleForm

def render(self, context, instance, placeholder):
context['instance'] = instance
return context
fieldsets = (
(None, {
'fields': ('class_name',)
}),
(_('Advanced Settings'), {
'classes': ('collapse',),
'fields': (
'tag_type',
'additional_classes',
'id_name',
('padding_left', 'padding_right', 'padding_top', 'padding_bottom'),
('margin_left', 'margin_right', 'margin_top', 'margin_bottom'),
),
}),
)

plugin_pool.register_plugin(StylePlugin)
43 changes: 0 additions & 43 deletions aldryn_style/forms.py

This file was deleted.

Binary file added aldryn_style/locale/ar/LC_MESSAGES/django.mo
Binary file not shown.
63 changes: 63 additions & 0 deletions aldryn_style/locale/ar/LC_MESSAGES/django.po
Original file line number Diff line number Diff line change
@@ -0,0 +1,63 @@
# SOME DESCRIPTIVE TITLE.
# Copyright (C) YEAR THE PACKAGE'S COPYRIGHT HOLDER
# This file is distributed under the same license as the PACKAGE package.
#
# Translators:
# draco003 <[email protected]>, 2013
msgid ""
msgstr ""
"Project-Id-Version: django-cms\n"
"Report-Msgid-Bugs-To: https://github.com/divio/django-cms/issues\n"
"POT-Creation-Date: 2012-12-14 14:09+0100\n"
"PO-Revision-Date: 2013-04-29 08:58+0000\n"
"Last-Translator: Patrick Lauber <[email protected]>\n"
"Language-Team: Arabic (http://www.transifex.com/projects/p/django-cms/language/ar/)\n"
"MIME-Version: 1.0\n"
"Content-Type: text/plain; charset=UTF-8\n"
"Content-Transfer-Encoding: 8bit\n"
"Language: ar\n"
"Plural-Forms: nplurals=6; plural=n==0 ? 0 : n==1 ? 1 : n==2 ? 2 : n%100>=3 && n%100<=10 ? 3 : n%100>=11 && n%100<=99 ? 4 : 5;\n"

#: cms_plugins.py:9
msgid "Style"
msgstr "نمط"

#: cms_plugins.py:17
msgid "Padding"
msgstr "مسافة تبطين"

#: cms_plugins.py:21
msgid "Margin"
msgstr "هامش"

#: models.py:7
msgid "info"
msgstr "معلومات"

#: models.py:8
msgid "new"
msgstr "جديد"

#: models.py:9
msgid "hint"
msgstr "تلميح"

#: models.py:17
msgid "class name"
msgstr "اسم الطراز"

#: models.py:19 models.py:24
msgid "left"
msgstr "يسار"

#: models.py:20 models.py:25
msgid "right"
msgstr "يمين"

#: models.py:21 models.py:26
msgid "top"
msgstr "أعلى"

#: models.py:22 models.py:27
msgid "bottom"
msgstr "أسفل"
Binary file added aldryn_style/locale/bg/LC_MESSAGES/django.mo
Binary file not shown.
62 changes: 62 additions & 0 deletions aldryn_style/locale/bg/LC_MESSAGES/django.po
Original file line number Diff line number Diff line change
@@ -0,0 +1,62 @@
# SOME DESCRIPTIVE TITLE.
# Copyright (C) YEAR THE PACKAGE'S COPYRIGHT HOLDER
# This file is distributed under the same license as the PACKAGE package.
#
# Translators:
msgid ""
msgstr ""
"Project-Id-Version: django-cms\n"
"Report-Msgid-Bugs-To: https://github.com/divio/django-cms/issues\n"
"POT-Creation-Date: 2012-12-14 14:09+0100\n"
"PO-Revision-Date: 2013-04-29 08:58+0000\n"
"Last-Translator: Patrick Lauber <[email protected]>\n"
"Language-Team: Bulgarian (http://www.transifex.com/projects/p/django-cms/language/bg/)\n"
"MIME-Version: 1.0\n"
"Content-Type: text/plain; charset=UTF-8\n"
"Content-Transfer-Encoding: 8bit\n"
"Language: bg\n"
"Plural-Forms: nplurals=2; plural=(n != 1);\n"

#: cms_plugins.py:9
msgid "Style"
msgstr ""

#: cms_plugins.py:17
msgid "Padding"
msgstr ""

#: cms_plugins.py:21
msgid "Margin"
msgstr ""

#: models.py:7
msgid "info"
msgstr ""

#: models.py:8
msgid "new"
msgstr ""

#: models.py:9
msgid "hint"
msgstr ""

#: models.py:17
msgid "class name"
msgstr ""

#: models.py:19 models.py:24
msgid "left"
msgstr "ляво"

#: models.py:20 models.py:25
msgid "right"
msgstr "дясно"

#: models.py:21 models.py:26
msgid "top"
msgstr ""

#: models.py:22 models.py:27
msgid "bottom"
msgstr ""
Binary file added aldryn_style/locale/ca/LC_MESSAGES/django.mo
Binary file not shown.
63 changes: 63 additions & 0 deletions aldryn_style/locale/ca/LC_MESSAGES/django.po
Original file line number Diff line number Diff line change
@@ -0,0 +1,63 @@
# SOME DESCRIPTIVE TITLE.
# Copyright (C) YEAR THE PACKAGE'S COPYRIGHT HOLDER
# This file is distributed under the same license as the PACKAGE package.
#
# Translators:
# Roger Pons <[email protected]>, 2013
msgid ""
msgstr ""
"Project-Id-Version: django-cms\n"
"Report-Msgid-Bugs-To: https://github.com/divio/django-cms/issues\n"
"POT-Creation-Date: 2012-12-14 14:09+0100\n"
"PO-Revision-Date: 2013-04-29 08:58+0000\n"
"Last-Translator: Patrick Lauber <[email protected]>\n"
"Language-Team: Catalan (http://www.transifex.com/projects/p/django-cms/language/ca/)\n"
"MIME-Version: 1.0\n"
"Content-Type: text/plain; charset=UTF-8\n"
"Content-Transfer-Encoding: 8bit\n"
"Language: ca\n"
"Plural-Forms: nplurals=2; plural=(n != 1);\n"

#: cms_plugins.py:9
msgid "Style"
msgstr "Estil"

#: cms_plugins.py:17
msgid "Padding"
msgstr "Farciment"

#: cms_plugins.py:21
msgid "Margin"
msgstr "Marge"

#: models.py:7
msgid "info"
msgstr "informació"

#: models.py:8
msgid "new"
msgstr "nou"

#: models.py:9
msgid "hint"
msgstr "Indici"

#: models.py:17
msgid "class name"
msgstr "nom de classe"

#: models.py:19 models.py:24
msgid "left"
msgstr "esquerra"

#: models.py:20 models.py:25
msgid "right"
msgstr "dret"

#: models.py:21 models.py:26
msgid "top"
msgstr "part superior"

#: models.py:22 models.py:27
msgid "bottom"
msgstr "part inferior"
Binary file added aldryn_style/locale/cs/LC_MESSAGES/django.mo
Binary file not shown.
Loading

0 comments on commit 1ff3c2a

Please sign in to comment.