├── .coveragerc ├── .editorconfig ├── .gitignore ├── .travis.yml ├── .tx └── config ├── CHANGELOG.rst ├── LICENSE.txt ├── MANIFEST.in ├── README.rst ├── addon.json ├── aldryn_bootstrap3 ├── __init__.py ├── cms_plugins.py ├── conf.py ├── constants.py ├── fields.py ├── forms.py ├── locale │ ├── de │ │ └── LC_MESSAGES │ │ │ ├── django.mo │ │ │ └── django.po │ ├── en │ │ └── LC_MESSAGES │ │ │ ├── django.mo │ │ │ └── django.po │ ├── es │ │ └── LC_MESSAGES │ │ │ ├── django.mo │ │ │ └── django.po │ ├── fr │ │ └── LC_MESSAGES │ │ │ ├── django.mo │ │ │ └── django.po │ ├── it │ │ └── LC_MESSAGES │ │ │ ├── django.mo │ │ │ └── django.po │ └── ru │ │ └── LC_MESSAGES │ │ ├── django.mo │ │ └── django.po ├── migrations │ ├── 0001_initial.py │ ├── 0002_bootstrap3fileplugin.py │ ├── 0003_auto_20151113_1604.py │ ├── 0004_auto_20151211_1333.py │ ├── 0005_boostrap3imageplugin_use_original_image.py │ ├── 0006_auto_20160615_1740.py │ ├── 0007_auto_20160705_1155.py │ ├── 0008_auto_20160820_2332.py │ ├── 0009_auto_20161219_1530.py │ ├── 0010_bootstrap3codeplugin.py │ ├── 0011_bootstrap3responsiveplugin.py │ ├── 0012_bootstrap3tabplugin.py │ ├── 0013_boostrap3jumbotronplugin.py │ ├── 0014_translations_update.py │ └── __init__.py ├── model_fields.py ├── models.py ├── static │ └── aldryn_bootstrap3 │ │ ├── css │ │ ├── base.css │ │ ├── bootstrap-iconpicker.min.css │ │ ├── bootstrap.min.css │ │ └── font-awesome.min.css │ │ ├── fonts │ │ ├── fontawesome-webfont.eot │ │ ├── fontawesome-webfont.svg │ │ ├── fontawesome-webfont.ttf │ │ ├── fontawesome-webfont.woff │ │ ├── fontawesome-webfont.woff2 │ │ ├── glyphicons-halflings-regular.eot │ │ ├── glyphicons-halflings-regular.svg │ │ ├── glyphicons-halflings-regular.ttf │ │ ├── glyphicons-halflings-regular.woff │ │ └── glyphicons-halflings-regular.woff2 │ │ ├── img │ │ └── type │ │ │ ├── button.png │ │ │ ├── file.png │ │ │ ├── icon.png │ │ │ ├── label.png │ │ │ └── spacer.png │ │ └── js │ │ ├── base.js │ │ ├── bootstrap-iconpicker.min.js │ │ ├── bootstrap.min.js │ │ ├── ckeditor.js │ │ ├── dropzone.init.js │ │ ├── dropzone.min.js │ │ ├── iconset │ │ ├── iconset-fontawesome-4.2.0.min.js │ │ └── iconset-glyphicon.min.js │ │ └── jquery.min.js ├── templates │ ├── admin │ │ └── aldryn_bootstrap3 │ │ │ ├── base.html │ │ │ ├── plugins │ │ │ ├── button │ │ │ │ └── change_form.html │ │ │ ├── code │ │ │ │ └── change_form.html │ │ │ ├── column │ │ │ │ └── change_form.html │ │ │ ├── label │ │ │ │ └── change_form.html │ │ │ └── row │ │ │ │ └── change_form.html │ │ │ └── widgets │ │ │ ├── context.html │ │ │ ├── dragndrop.html │ │ │ ├── icon.html │ │ │ ├── link_or_button.html │ │ │ ├── responsive.html │ │ │ ├── responsive_print.html │ │ │ └── size.html │ └── aldryn_bootstrap3 │ │ └── plugins │ │ ├── accordion.html │ │ ├── accordion_item.html │ │ ├── alert.html │ │ ├── blockquote.html │ │ ├── button.html │ │ ├── carousel │ │ ├── base.html │ │ └── standard │ │ │ ├── carousel.html │ │ │ ├── image_slide.html │ │ │ ├── includes │ │ │ └── image.html │ │ │ ├── slide.html │ │ │ └── slide_folder.html │ │ ├── cite.html │ │ ├── code.html │ │ ├── column.html │ │ ├── file.html │ │ ├── icon.html │ │ ├── image.html │ │ ├── includes │ │ └── icon.html │ │ ├── jumbotron.html │ │ ├── label.html │ │ ├── list_group.html │ │ ├── list_group_item.html │ │ ├── panel.html │ │ ├── panel_body.html │ │ ├── panel_footer.html │ │ ├── panel_heading.html │ │ ├── responsive.html │ │ ├── row.html │ │ ├── spacer.html │ │ ├── tab.html │ │ ├── tab_item.html │ │ └── well.html ├── templatetags │ ├── __init__.py │ └── aldryn_bootstrap3_tags.py └── widgets.py ├── aldryn_config.py ├── preview.gif ├── setup.py ├── tests ├── __init__.py ├── requirements.txt ├── settings.py └── tests_models.py └── tox.ini /.coveragerc: -------------------------------------------------------------------------------- 1 | [run] 2 | branch = True 3 | source = aldryn_bootstrap3 4 | omit = 5 | migrations/* 6 | tests/* 7 | 8 | [report] 9 | exclude_lines = 10 | pragma: no cover 11 | def __repr__ 12 | if self.debug: 13 | if settings.DEBUG 14 | raise AssertionError 15 | raise NotImplementedError 16 | if 0: 17 | if __name__ == .__main__.: 18 | ignore_errors = True 19 | -------------------------------------------------------------------------------- /.editorconfig: -------------------------------------------------------------------------------- 1 | # editorconfig.org 2 | 3 | root = true 4 | 5 | [*] 6 | indent_style = space 7 | indent_size = 4 8 | end_of_line = lf 9 | charset = utf-8 10 | trim_trailing_whitespace = true 11 | insert_final_newline = true 12 | max_line_length = 80 13 | 14 | [*.py] 15 | max_line_length = 120 16 | quote_type = single 17 | 18 | [*.{scss,js,html}] 19 | max_line_length = 120 20 | indent_style = space 21 | quote_type = double 22 | 23 | [*.js] 24 | max_line_length = 120 25 | quote_type = single 26 | 27 | [*.rst] 28 | max_line_length = 80 29 | 30 | [*.yml] 31 | indent_size = 2 32 | 33 | [*plugins/code.html] 34 | insert_final_newline = false 35 | 36 | [*plugins/responsive.html] 37 | insert_final_newline = false 38 | 39 | [*plugins/image.html] 40 | insert_final_newline = false 41 | -------------------------------------------------------------------------------- /.gitignore: -------------------------------------------------------------------------------- 1 | *.pyc 2 | *.egg-info 3 | .DS_Store 4 | .idea/ 5 | .tox/ 6 | .eggs/ 7 | dist/ 8 | build/ 9 | -------------------------------------------------------------------------------- /.travis.yml: -------------------------------------------------------------------------------- 1 | language: python 2 | 3 | sudo: false 4 | 5 | env: 6 | - TOX_ENV=flake8 7 | - TOX_ENV=py27-latest 8 | - TOX_ENV=py34-latest 9 | # Django 1.8 10 | - TOX_ENV=py27-dj18-cms34 11 | - TOX_ENV=py27-dj18-cms33 12 | - TOX_ENV=py34-dj18-cms34 13 | - TOX_ENV=py34-dj18-cms33 14 | # Django 1.9 15 | - TOX_ENV=py27-dj19-cms34 16 | - TOX_ENV=py27-dj19-cms33 17 | - TOX_ENV=py34-dj19-cms34 18 | - TOX_ENV=py34-dj19-cms33 19 | 20 | install: 21 | - pip install tox coverage 22 | 23 | script: 24 | - tox -e $TOX_ENV 25 | 26 | after_success: 27 | - bash <(curl -s https://codecov.io/bash) 28 | -------------------------------------------------------------------------------- /.tx/config: -------------------------------------------------------------------------------- 1 | [main] 2 | host = https://www.transifex.com 3 | 4 | [aldryn-bootstrap3.aldryn_bootstrap3] 5 | file_filter = aldryn_bootstrap3/locale//LC_MESSAGES/django.po 6 | source_file = aldryn_bootstrap3/locale/en/LC_MESSAGES/django.po 7 | source_lang = en 8 | type = PO 9 | -------------------------------------------------------------------------------- /CHANGELOG.rst: -------------------------------------------------------------------------------- 1 | ========= 2 | Changelog 3 | ========= 4 | 5 | 6 | 1.3.0 (2018-04-09) 7 | ================== 8 | 9 | * Introduced Django 1.11 support 10 | * Fixed a bug where overriding ``Site.__str__`` resulted in invalid urls. 11 | * Fixed a bug in iconpicker that would prevent form submissions via keyboard 12 | * Fixed a bug in iconpicker when disabled prev/next buttons would be ignored 13 | * Added possibility of using custom iconsets with svg inlining 14 | 15 | 16 | 1.2.2 (2017-05-09) 17 | ================== 18 | 19 | * Fixed a bug which prevented links from working when the page 20 | referenced is on a different site from the one that contains the plugin. 21 | * Removed unused and deprecated django-durationfield from requirements 22 | * Updated translations 23 | 24 | 25 | 1.2.1 (2017-03-07) 26 | ================== 27 | 28 | * Removed link restriction when no link is provided to the carousel 29 | * Fixed an issue where selecting the "Use original image" option is not 30 | rendering the image 31 | 32 | 33 | 1.2.0 (2017-01-26) 34 | ================== 35 | 36 | * Added Django 1.10 support 37 | * Added plugin 38 | * Added plugin to
39 | * Added responsive plugin to set device and print breakpoints 40 | * Added tab and tab item plugins 41 | * Added attributes fields to models missing it 42 | * Added missing translation declarations to untranslated strings 43 | * Added default CKEditor "styleSet" to load via djangocms-text-ckeditor in 44 | ``/static/aldryn_bootstrap3/js/ckeditor.js`` 45 | * Added transifex integration for translations 46 | * Added test framework 47 | * Changed root files such as ``README``, ``CHANGELOG``, ``setup.py`` and others 48 | to conform with other core addons such as django CMS Picture 49 | * Changed labels and help texts of several plugins 50 | * Changed all max_values to 255 51 | * Changed code to reflect Bootstrap 3's documentation 52 | * Fixed an issue with collapse styles from image plugin overriding bootstrap 53 | styles already on the page 54 | * Fixed an issue with dropzone strings visible inside djangocms-text-ckeditor 55 | image preview under certain circumstances 56 | * Fixed an issue where column offset, push and pull did not accept "0" as a value 57 | * **Backwards incompatible** changes: 58 | * The Panel only allows header, body and footer now to be its direct 59 | decendands and the descendends require the "Panel" parent. 60 | * Drag & drop support has been removed from the rendered plugin markup 61 | until a cleaner version is ready 62 | * Simplified and removed constants such as ``LABEL_CONTEXT_CHOICES``, 63 | ``LABEL_CONTEXT_DEFAULT``, ,``TEXT_LINK_CONTEXT_CHOICES``, 64 | ``TXT_LINK_CONTEXT_DEFAULT``, ``PANEL_CONTEXT_CHOICES``, 65 | ``PANEL_CONTEXT_DEFAULT``, ``ACCORDION_ITEM_CONTEXT_CHOICES``, 66 | ``ACCORDION_ITEM_CONTEXT_DEFAULT``, ``LIST_GROUP_ITEM_CONTEXT_CHOICES``, 67 | ``LIST_GROUP_ITEM_CONTEXT_DEFAULT`` 68 | 69 | 70 | 1.1.2 (2016-09-05) 71 | ================== 72 | 73 | * Let attributes field be optional 74 | * Fixed styling issues with attributes field 75 | * Changed the "label" plugin template to include no whitespace inside or 76 | outside the span 77 | * Pinned djangocms-attributes-field to v0.1.1+ 78 | * Disabled "text preview" for the Spacer plugin 79 | * Changed JavaScript to allow custom iconsets 80 | * Improved edit mode preview of image plugin 81 | * Fixed a bug in Link/Button plugin preview not always respecting icon options 82 | * Added missing migrations for djangoCMS 3.3.1 compatibility. 83 | * Added class "js-ckeditor-use-selected-text" to the label field on the 84 | Bootstrap3LabelCMSPlugin and Bootstrap3ButtonCMSPlugin plugins 85 | * Introduced support for djangoCMS 3.4.0 86 | 87 | 88 | 1.1.1 (2016-07-05) 89 | ================== 90 | 91 | * Pinned djangocms-attributes-field v0.1.0 92 | * Fixed issue with template 93 | 94 | 95 | 1.1.0 (2016-06-20) 96 | ================== 97 | 98 | * Added support for arbitrary attributes on link tags 99 | * Fixed a Python 3 incompatibility 100 | * Allow zero values for column push, pull and offset in admin forms 101 | * Added a "change" event trigger when changing bootstrap style for multiple 102 | plugins 103 | 104 | 105 | 1.0.10 (2016-04-27) 106 | =================== 107 | 108 | * Removes spaces before and after link 109 | * Fixes drag and drop image view in edit mode for xplorer 110 | * Updates upload info box styles 111 | 112 | 113 | 1.0.9 (2016-03-16) 114 | ================== 115 | 116 | * Removes unnecessary `cache = False` from plugins 117 | 118 | 119 | 1.0.8 (2016-02-22) 120 | ================== 121 | 122 | * Add drag-n-drop for image plugin in content mode 123 | 124 | 125 | 1.0.7 (2016-01-13) 126 | ================== 127 | 128 | * Remove imagePlugin reference 129 | * Add drag and drop support for image plugin in content mode 130 | (if supported by Django Filer). 131 | * Fix name display for file plugin 132 | * Add original image checkbox 133 | 134 | 135 | 1.0.6 (2015-12-14) 136 | ================== 137 | 138 | * Allow children in link plugin 139 | * Make image in carousel slide plugin mandatory 140 | * Make image in image plugin mandatory 141 | * Replace `xrange` with `range` 142 | * Remove preview for image 143 | 144 | 145 | 1.0.5 (2015-11-26) 146 | ================== 147 | 148 | * Upload correct version 149 | 150 | 151 | 1.0.4 (2015-11-24) 152 | ================== 153 | 154 | * Move extra width and height for image to advanced section 155 | * Change how image label is retrieved (fixes nonexistent image issue) 156 | 157 | 158 | 1.0.3 (2015-11-19) 159 | ================== 160 | 161 | * Fixed an issue with links not rendering target 162 | * Fixed an issue with links rendering empty class attribute 163 | * Enhance display of image name in structure board 164 | 165 | 166 | 1.0.2 (2015-11-17) 167 | ================== 168 | 169 | * Adds static folder to include in MANIFEST.in 170 | 171 | 172 | 1.0.1 (2015-11-17) 173 | ================== 174 | 175 | * Fixes preview display for all plugins and widgets 176 | * Implement icons for text_enabled plugins 177 | * Add width and height configuration to image plugin 178 | * Code cleanup 179 | 180 | 181 | 1.0.0 (2015-11-03) 182 | ================== 183 | 184 | * Initial release 185 | -------------------------------------------------------------------------------- /LICENSE.txt: -------------------------------------------------------------------------------- 1 | Copyright (c) 2015, Divio AG 2 | All rights reserved. 3 | 4 | Redistribution and use in source and binary forms, with or without 5 | modification, are permitted provided that the following conditions are met: 6 | * Redistributions of source code must retain the above copyright 7 | notice, this list of conditions and the following disclaimer. 8 | * Redistributions in binary form must reproduce the above copyright 9 | notice, this list of conditions and the following disclaimer in the 10 | documentation and/or other materials provided with the distribution. 11 | * Neither the name of Divio AG nor the 12 | names of its contributors may be used to endorse or promote products 13 | derived from this software without specific prior written permission. 14 | 15 | THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS "AS IS" AND 16 | ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED 17 | WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE 18 | DISCLAIMED. IN NO EVENT SHALL DIVIO AG BE LIABLE FOR ANY 19 | DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES 20 | (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; 21 | LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND 22 | ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT 23 | (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS 24 | SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. 25 | -------------------------------------------------------------------------------- /MANIFEST.in: -------------------------------------------------------------------------------- 1 | include LICENSE.txt 2 | include README.rst 3 | recursive-include aldryn_bootstrap3/locale * 4 | recursive-include aldryn_bootstrap3/static * 5 | recursive-include aldryn_bootstrap3/templates * 6 | recursive-exclude * *.py[co] 7 | -------------------------------------------------------------------------------- /README.rst: -------------------------------------------------------------------------------- 1 | **Deprecated** 2 | 3 | This project has been succeeded by `djangocms-bootstrap4 `_ , and is no longer supported. 4 | 5 | Divio will undertake no further development or maintenance of this project. If you are interested in continuing to develop it, use the fork functionality from GitHub. We are not able to transfer ownership of the repository to another party. 6 | 7 | 8 | ================= 9 | Aldryn Bootstrap3 10 | ================= 11 | 12 | 13 | |pypi| |build| |coverage| 14 | 15 | **Aldryn Bootstrap 3** is a plugin bundle for django CMS providing several 16 | components from the popular `Bootstrap 3 `_ framework. 17 | 18 | This addon is compatible with `Divio Cloud `_ and is also available on the 19 | `django CMS Marketplace `_ 20 | for easy installation. 21 | 22 | .. image:: preview.gif 23 | 24 | 25 | Contributing 26 | ============ 27 | 28 | This is a an open-source project. We'll be delighted to receive your 29 | feedback in the form of issues and pull requests. Before submitting your 30 | pull request, please review our `contribution guidelines 31 | `_. 32 | 33 | One of the easiest contributions you can make is helping to translate this addon on 34 | `Transifex `_. 35 | 36 | 37 | Documentation 38 | ============= 39 | 40 | See ``REQUIREMENTS`` in the `setup.py `_ 41 | file for additional dependencies: 42 | 43 | * Python 2.7, 3.3 or higher 44 | * Django 1.6 or higher 45 | * Django Filer 1.2.4 or higher 46 | * Django Text CKEditor 3.1.0 or higher 47 | 48 | Make sure `django Filer `_ 49 | and `django CMS Text CKEditor `_ 50 | are installed and configured appropriately. 51 | 52 | 53 | Installation 54 | ------------ 55 | 56 | For a manual install: 57 | 58 | * run ``pip install aldryn-bootstrap3`` 59 | * add ``aldryn_bootstrap3`` to your ``INSTALLED_APPS`` 60 | * run ``python manage.py migrate aldryn_bootstrap3`` 61 | 62 | 63 | Configuration 64 | ------------- 65 | 66 | Aldryn Bootstrap 3 **replaces** the following django CMS plugins: 67 | 68 | * **django CMS Link**: `Link and Button `_ 69 | * **django CMS Picture**: `Image `_ 70 | * **django CMS File**: `File `_ 71 | 72 | It provides the following **standard** Bootstrap 3 components: 73 | 74 | * `Accordion `_ 75 | * `Alert `_ 76 | * `Blockquote `_ 77 | * `Carousel `_ 78 | * `Code `_ 79 | * `Grid (Row and Column) `_ 80 | * `Glyphicons `_ 81 | * `Jumbotron `_ 82 | * `Label `_ 83 | * `List Group `_ 84 | * `Panel (Heading, Body and Footer) `_ 85 | * `Responsive `_ 86 | * `Tabs `_ 87 | * `Well `_ 88 | 89 | It also provides the following **3rd party** components: 90 | 91 | * `Font Awesome `_ 92 | * `Spacer `_ 93 | 94 | These components need to be manually configured in order to work properly 95 | inside your project. See `this gist `_ 96 | for additional information on a recommended spacer configuration. 97 | 98 | 99 | Settings 100 | ~~~~~~~~ 101 | 102 | This addon provides a ``standard`` template for Carousels. You can provide 103 | additional style choices by adding a ``ALDRYN_BOOTSTRAP3_CAROUSEL_STYLES`` 104 | setting:: 105 | 106 | ALDRYN_BOOTSTRAP3_CAROUSEL_STYLES = [ 107 | ('feature', _('Featured Version')), 108 | ] 109 | 110 | You'll need to create the `feature` folder inside ``templates/aldryn_bootstrap/plugins/carousel/`` 111 | otherwise you will get a *template does not exist* error. You can do this by 112 | copying the ``standard`` folder inside that directory and renaming it to 113 | ``feature``. 114 | 115 | In addition you can set or extend your own icon fonts using ``ALDRYN_BOOTSTRAP3_ICONSETS``:: 116 | 117 | ALDRYN_BOOTSTRAP3_ICONSETS = [ 118 | ('glyphicons', 'glyphicons', 'Glyphicons'), 119 | ('fontawesome', 'fa', 'Font Awesome'), 120 | # custom iconsets have to be JSON 121 | ('{"iconClass": "icon", "iconClassFix": "icon-", "icons": [...]}', 'icon', 'Custom Font Icons'), 122 | ('{"svg": true, "spritePath": "sprites/icons.svg", "iconClass": "icon", "iconClassFix": "icon-", "icons": [...]}', 'icon', 'Custom SVG Icons'), 123 | ] 124 | 125 | The default grid size is set to **24** when validating the column input, 126 | you can override this by setting:: 127 | 128 | ALDRYN_BOOTSTRAP3_GRID_SIZE = 12 129 | 130 | 131 | Running Tests 132 | ------------- 133 | 134 | You can run tests by executing:: 135 | 136 | virtualenv env 137 | source env/bin/activate 138 | pip install -r tests/requirements.txt 139 | python setup.py test 140 | 141 | 142 | .. |pypi| image:: https://badge.fury.io/py/aldryn-bootstrap3.svg 143 | :target: http://badge.fury.io/py/aldryn-bootstrap3 144 | .. |build| image:: https://travis-ci.org/aldryn/aldryn-bootstrap3.svg?branch=master 145 | :target: https://travis-ci.org/aldryn/aldryn-bootstrap3 146 | .. |coverage| image:: https://codecov.io/gh/aldryn/aldryn-bootstrap3/branch/master/graph/badge.svg 147 | :target: https://codecov.io/gh/aldryn/aldryn-bootstrap3 148 | -------------------------------------------------------------------------------- /addon.json: -------------------------------------------------------------------------------- 1 | { 2 | "package-name": "aldryn-bootstrap3", 3 | "installed-apps": [ 4 | "aldryn_bootstrap3" 5 | ], 6 | "protected": [ 7 | "templates/*", 8 | "static/*" 9 | ] 10 | } 11 | -------------------------------------------------------------------------------- /aldryn_bootstrap3/__init__.py: -------------------------------------------------------------------------------- 1 | # -*- coding: utf-8 -*- 2 | __version__ = '1.3.0' 3 | -------------------------------------------------------------------------------- /aldryn_bootstrap3/conf.py: -------------------------------------------------------------------------------- 1 | # -*- coding: utf-8 -*- 2 | from __future__ import unicode_literals, absolute_import 3 | 4 | from django.conf import settings 5 | from django.utils.translation import ugettext_lazy as _ 6 | 7 | from appconf import AppConf 8 | 9 | 10 | class AldrynSitesConf(AppConf): 11 | GRID_SIZE = 24 12 | ICONSETS = ( 13 | # NOTE: these values are overridden by the settings from aldryn_config.py on aldryn 14 | # first value is the iconset identifier for http://victor-valencia.github.io/bootstrap-iconpicker/ 15 | # second is the prefix for the css class 16 | # third is the pretty name shown in the select box 17 | ('glyphicons', 'glyphicons', 'Glyphicons'), 18 | ('fontawesome', 'fa', 'Fontawesome'), 19 | ) 20 | -------------------------------------------------------------------------------- /aldryn_bootstrap3/constants.py: -------------------------------------------------------------------------------- 1 | # -*- coding: utf-8 -*- 2 | from __future__ import unicode_literals, absolute_import 3 | 4 | from django.utils.translation import ugettext_lazy as _ 5 | 6 | from .conf import settings 7 | 8 | 9 | # Changable constants, overriden through settings 10 | GRID_SIZE = getattr(settings, 'ALDRYN_BOOTSTRAP3_GRID_SIZE', 24) 11 | 12 | # Fixed constants, not influenced by settings 13 | # Changes here will most likely require database migrtions 14 | DEVICE_CHOICES = ( 15 | ('xs', _('Tiny')), 16 | ('sm', _('Small')), 17 | ('md', _('Medium')), 18 | ('lg', _('Large')), 19 | ) 20 | 21 | DEVICE_SIZES = tuple([size for size, name in DEVICE_CHOICES]) 22 | 23 | TARGET_CHOICES = ( 24 | ('_blank', _('Open in new window')), 25 | ('_self', _('Open in same window')), 26 | ('_parent', _('Delegate to parent')), 27 | ('_top', _('Delegate to top')), 28 | ) 29 | 30 | CONTEXT_CHOICES = ( 31 | ('primary', _('Primary'),), 32 | ('success', _('Success'),), 33 | ('info', _('Info'),), 34 | ('warning', _('Warning'),), 35 | ('danger', _('Danger'),), 36 | ) 37 | 38 | CONTEXT_DEFAULT = 'default' 39 | 40 | BUTTON_CONTEXT_CHOICES = ( 41 | ('default', _('Default'),), 42 | ) + CONTEXT_CHOICES + ( 43 | ('link', _('Link'),), 44 | ) 45 | 46 | BUTTON_CONTEXT_DEFAULT = 'default' 47 | 48 | TEXT_LINK_CONTEXT_CHOICES = ( 49 | ('', _('Default'),), 50 | ) + CONTEXT_CHOICES + ( 51 | ('muted ', _('Muted'),), 52 | ) 53 | 54 | TEXT_LINK_CONTEXT_DEFAULT = '' 55 | 56 | ASPECT_RATIOS = ( 57 | (4, 3), 58 | (16, 9), 59 | (16, 10), 60 | (21, 9), 61 | ) 62 | 63 | ASPECT_RATIOS_REVERSED = ([(y, x) for x, y in ASPECT_RATIOS]) 64 | 65 | ASPECT_RATIO_CHOICES = ( 66 | tuple([ 67 | ('{0}x{1}'.format(1, 1), '{0}x{1}'.format(1, 1)) 68 | ]) + tuple([ 69 | ('{0}x{1}'.format(x, y), '{0}x{1}'.format(x, y)) 70 | for x, y in ASPECT_RATIOS 71 | ]) + tuple([ 72 | ('{0}x{1}'.format(x, y), '{0}x{1}'.format(x, y)) 73 | for x, y in ASPECT_RATIOS_REVERSED 74 | ])) 75 | 76 | SIZE_CHOICES = ( 77 | ('lg', _('Large'),), 78 | ('md', _('Medium'),), 79 | ('sm', _('Small'),), 80 | ('xs', _('Extra Small'),), 81 | ) 82 | 83 | DEVICES = ( 84 | { 85 | 'identifier': 'xs', 86 | 'name': _('Mobile phones'), 87 | 'width': 768, 88 | 'width_gutter': 750, 89 | 'icon': 'mobile-phone', 90 | }, 91 | { 92 | 'identifier': 'sm', 93 | 'name': _('Tablets'), 94 | 'width': 768, 95 | 'width_gutter': 750, 96 | 'icon': 'tablet', 97 | }, 98 | { 99 | 'identifier': 'md', 100 | 'name': _('Laptops'), 101 | 'width': 992, 102 | 'width_gutter': 970, 103 | 'icon': 'laptop', 104 | }, 105 | { 106 | 'identifier': 'lg', 107 | 'name': _('Large desktops'), 108 | 'width': 1200, 109 | 'width_gutter': 1170, 110 | 'icon': 'desktop', 111 | }, 112 | ) 113 | 114 | for device in DEVICES: 115 | identifier = device['identifier'] 116 | device['long_description'] = '{name} (<{width}px)'.format(**device) 117 | device['size_name'] = dict(SIZE_CHOICES).get(identifier) 118 | -------------------------------------------------------------------------------- /aldryn_bootstrap3/fields.py: -------------------------------------------------------------------------------- 1 | # -*- coding: utf-8 -*- 2 | from __future__ import unicode_literals, absolute_import 3 | 4 | import django.forms.fields 5 | from django.utils.translation import ugettext_lazy as _ 6 | 7 | from .conf import settings 8 | from . import widgets, constants 9 | 10 | 11 | class Context(django.forms.fields.ChoiceField): 12 | widget = widgets.Context 13 | CHOICES = constants.CONTEXT_CHOICES 14 | DEFAULT = constants.CONTEXT_DEFAULT 15 | 16 | def __init__(self, *args, **kwargs): 17 | if 'choices' not in kwargs: 18 | kwargs['choices'] = self.CHOICES 19 | if 'initial' not in kwargs: 20 | kwargs['initial'] = self.DEFAULT 21 | kwargs.pop('coerce', None) 22 | kwargs.pop('max_length', None) 23 | kwargs.pop('widget', None) 24 | kwargs['widget'] = self.widget 25 | super(Context, self).__init__(*args, **kwargs) 26 | 27 | 28 | class Size(django.forms.fields.ChoiceField): 29 | widget = widgets.Size 30 | CHOICES = constants.SIZE_CHOICES 31 | DEFAULT = 'md' 32 | 33 | def __init__(self, *args, **kwargs): 34 | if 'choices' not in kwargs: 35 | kwargs['choices'] = self.CHOICES 36 | if 'initial' not in kwargs: 37 | kwargs['initial'] = self.DEFAULT 38 | kwargs.pop('coerce', None) 39 | kwargs.pop('max_length', None) 40 | kwargs.pop('widget', None) 41 | kwargs['widget'] = self.widget 42 | super(Size, self).__init__(*args, **kwargs) 43 | 44 | 45 | class Icon(django.forms.fields.CharField): 46 | widget = widgets.Icon 47 | DEFAULT = '' 48 | 49 | def __init__(self, *args, **kwargs): 50 | if 'initial' not in kwargs: 51 | kwargs['initial'] = self.DEFAULT 52 | kwargs.pop('coerce', None) 53 | kwargs.pop('max_length', None) 54 | kwargs.pop('widget', None) 55 | kwargs['widget'] = self.widget 56 | super(Icon, self).__init__(*args, **kwargs) 57 | 58 | 59 | class Integer(django.forms.fields.IntegerField): 60 | widget = django.forms.NumberInput 61 | 62 | def __init__(self, *args, **kwargs): 63 | kwargs.pop('coerce', None) 64 | kwargs.pop('max_length', None) 65 | kwargs.pop('widget', None) 66 | kwargs['widget'] = self.widget 67 | super(Integer, self).__init__(*args, **kwargs) 68 | 69 | 70 | class Classes(django.forms.fields.CharField): 71 | widget = django.forms.widgets.Textarea 72 | 73 | 74 | class MiniText(django.forms.fields.CharField): 75 | widget = widgets.MiniTextarea 76 | 77 | def __init__(self, *args, **kwargs): 78 | kwargs.pop('coerce', None) 79 | kwargs.pop('max_length', None) 80 | kwargs.pop('widget', None) 81 | kwargs['widget'] = self.widget 82 | super(MiniText, self).__init__(*args, **kwargs) 83 | 84 | 85 | class LinkOrButton(django.forms.fields.ChoiceField): 86 | widget = widgets.LinkOrButton 87 | CHOICES = ( 88 | ('lnk', 'link'), 89 | ('btn', 'button'), 90 | ) 91 | DEFAULT = 'lnk' 92 | 93 | def __init__(self, *args, **kwargs): 94 | if 'choices' not in kwargs: 95 | kwargs['choices'] = self.CHOICES 96 | if 'initial' not in kwargs: 97 | kwargs['initial'] = self.DEFAULT 98 | kwargs.pop('coerce', None) 99 | kwargs.pop('max_length', None) 100 | kwargs.pop('widget', None) 101 | kwargs['widget'] = self.widget 102 | super(LinkOrButton, self).__init__(*args, **kwargs) 103 | 104 | 105 | class Responsive(MiniText): 106 | widget = widgets.Responsive 107 | 108 | 109 | class ResponsivePrint(MiniText): 110 | widget = widgets.ResponsivePrint 111 | -------------------------------------------------------------------------------- /aldryn_bootstrap3/forms.py: -------------------------------------------------------------------------------- 1 | # -*- coding: utf-8 -*- 2 | from __future__ import unicode_literals, absolute_import 3 | 4 | import django.core.exceptions 5 | import django.forms 6 | import django.forms.models 7 | import django.template 8 | import django.template.loader 9 | 10 | from django.forms.widgets import Media, TextInput, Textarea 11 | from django.utils.translation import ugettext_lazy as _ 12 | 13 | import cms.forms.fields 14 | import cms.models 15 | 16 | from djangocms_attributes_field.widgets import AttributesWidget 17 | 18 | from . import models, constants 19 | 20 | 21 | class RowPluginBaseForm(django.forms.models.ModelForm): 22 | create = django.forms.IntegerField( 23 | label=_('Create columns'), 24 | help_text=_('Number of columns to create in this row.'), 25 | required=False, 26 | min_value=0, 27 | ) 28 | 29 | class Meta: 30 | model = models.Bootstrap3RowPlugin 31 | exclude = ('page', 'position', 'placeholder', 'language', 'plugin_type') 32 | 33 | 34 | extra_fields_row = {} 35 | for size, name in constants.DEVICE_CHOICES: 36 | extra_fields_row['create_{}_col'.format(size)] = django.forms.IntegerField( 37 | label='col-{}-'.format(size), 38 | help_text=_('Width of created columns ' 39 | '(can be edited later if required.)'), 40 | required=False, 41 | min_value=1, 42 | max_value=constants.GRID_SIZE, 43 | ) 44 | extra_fields_row['create_{}_offset'.format(size)] = django.forms.IntegerField( 45 | label='offset-'.format(size), 46 | help_text=_('Offset of created columns ' 47 | '(can be edited later if required.)'), 48 | required=False, 49 | min_value=0, 50 | max_value=constants.GRID_SIZE, 51 | ) 52 | extra_fields_row['create_{}_push'.format(size)] = django.forms.IntegerField( 53 | label='push-'.format(size), 54 | help_text=_('Push of created columns ' 55 | '(can be edited later if required.)'), 56 | required=False, 57 | min_value=0, 58 | max_value=constants.GRID_SIZE, 59 | ) 60 | extra_fields_row['create_{}_pull'.format(size)] = django.forms.IntegerField( 61 | label='pull-'.format(size), 62 | help_text=_('Pull of created columns ' 63 | '(can be edited later if required.)'), 64 | required=False, 65 | min_value=0, 66 | max_value=constants.GRID_SIZE, 67 | ) 68 | 69 | RowPluginForm = type( 70 | str('RowPluginBaseForm'), 71 | (RowPluginBaseForm,), 72 | extra_fields_row 73 | ) 74 | 75 | 76 | class ColumnPluginBaseForm(django.forms.models.ModelForm): 77 | create = django.forms.IntegerField( 78 | label=_('Adjust columns'), 79 | help_text=_('Adjust this column.'), 80 | required=False, 81 | min_value=0, 82 | ) 83 | 84 | class Meta: 85 | model = models.Bootstrap3ColumnPlugin 86 | exclude = ('page', 'position', 'placeholder', 'language', 'plugin_type') 87 | 88 | 89 | extra_fields_column = {} 90 | for size, name in constants.DEVICE_CHOICES: 91 | extra_fields_column['{}_col'.format(size)] = django.forms.IntegerField( 92 | label='col-{}-'.format(size), 93 | help_text=_('Width of created columns ' 94 | '(can be edited later if required.)'), 95 | required=False, 96 | min_value=1, 97 | max_value=constants.GRID_SIZE, 98 | ) 99 | extra_fields_column['{}_offset'.format(size)] = django.forms.IntegerField( 100 | label='offset-'.format(size), 101 | help_text=_('Offset of created columns ' 102 | '(can be edited later if required.)'), 103 | required=False, 104 | min_value=0, 105 | max_value=constants.GRID_SIZE, 106 | ) 107 | extra_fields_column['{}_push'.format(size)] = django.forms.IntegerField( 108 | label='push-'.format(size), 109 | help_text=_('Push of created columns ' 110 | '(can be edited later if required.)'), 111 | required=False, 112 | min_value=0, 113 | max_value=constants.GRID_SIZE, 114 | ) 115 | extra_fields_column['{}_pull'.format(size)] = django.forms.IntegerField( 116 | label='pull-'.format(size), 117 | help_text=_('Pull of created columns ' 118 | '(can be edited later if required.)'), 119 | required=False, 120 | min_value=0, 121 | max_value=constants.GRID_SIZE, 122 | ) 123 | 124 | ColumnPluginForm = type( 125 | str('ColumnPluginBaseForm'), 126 | (ColumnPluginBaseForm,), 127 | extra_fields_column 128 | ) 129 | 130 | 131 | class Bootstrap3CodePluginForm(django.forms.models.ModelForm): 132 | class Meta: 133 | # When used inside djangocms-text-ckeditor 134 | # this causes the label field to be prefilled with the selected text. 135 | widgets = { 136 | 'code': Textarea(attrs={'class': 'js-ckeditor-use-selected-text'}), 137 | } 138 | 139 | 140 | class LinkForm(django.forms.models.ModelForm): 141 | link_page = cms.forms.fields.PageSelectFormField( 142 | queryset=cms.models.Page.objects.drafts(), 143 | label=_('Internal link'), 144 | required=False, 145 | ) 146 | 147 | def for_site(self, site): 148 | # override the page_link fields queryset to containt just pages for 149 | # current site 150 | self.fields['link_page'].queryset = cms.models.Page.objects.drafts().on_site(site) 151 | 152 | class Meta: 153 | model = models.Boostrap3ButtonPlugin 154 | exclude = ( 155 | 'page', 'position', 'placeholder', 'language', 'plugin_type', 156 | ) 157 | # When used inside djangocms-text-ckeditor 158 | # this causes the label field to be prefilled with the selected text. 159 | widgets = { 160 | 'label': TextInput(attrs={'class': 'js-ckeditor-use-selected-text'}), 161 | } 162 | 163 | def __init__(self, *args, **kwargs): 164 | super(LinkForm, self).__init__(*args, **kwargs) 165 | self.fields['link_attributes'].widget = AttributesWidget() 166 | 167 | def _get_media(self): 168 | """ 169 | Provide a description of all media required to render the widgets on this form 170 | """ 171 | media = Media() 172 | for field in self.fields.values(): 173 | media = media + field.widget.media 174 | media._js = ['cms/js/libs/jquery.min.js'] + media._js 175 | return media 176 | media = property(_get_media) 177 | 178 | 179 | class Boostrap3LabelPluginForm(django.forms.models.ModelForm): 180 | 181 | class Meta: 182 | model = models.Boostrap3LabelPlugin 183 | exclude = ('page', 'position', 'placeholder', 'language', 'plugin_type') 184 | # When used inside djangocms-text-ckeditor 185 | # this causes the label field to be prefilled with the selected text. 186 | widgets = { 187 | 'label': TextInput(attrs={'class': 'js-ckeditor-use-selected-text'}), 188 | } 189 | 190 | 191 | class PanelPluginBaseForm(django.forms.models.ModelForm): 192 | create_heading = django.forms.BooleanField( 193 | label=_('Initial heading'), 194 | required=False, 195 | initial=False, 196 | ) 197 | create_body = django.forms.BooleanField( 198 | label=_('Initial body'), 199 | required=False, 200 | initial=False, 201 | ) 202 | create_footer = django.forms.BooleanField( 203 | label=_('Initial footer'), 204 | required=False, 205 | initial=False, 206 | ) 207 | 208 | class Meta: 209 | model = models.Boostrap3PanelPlugin 210 | exclude = ('page', 'position', 'placeholder', 'language', 'plugin_type') 211 | 212 | 213 | class CarouselPluginForm(django.forms.ModelForm): 214 | 215 | class Meta: 216 | fields = [ 217 | 'style', 218 | 'transition_effect', 219 | 'ride', 220 | 'interval', 221 | ] 222 | model = models.Bootstrap3CarouselPlugin 223 | 224 | def clean_style(self): 225 | style = self.cleaned_data.get('style') 226 | template = 'aldryn_bootstrap3/plugins/carousel/{}/carousel.html'.format( 227 | style 228 | ) 229 | # Check if template for style exists: 230 | try: 231 | django.template.loader.select_template([template]) 232 | except django.template.TemplateDoesNotExist: 233 | raise django.forms.ValidationError( 234 | _('Not a valid style (template {path} does not exist)').format(path=template) 235 | ) 236 | return style 237 | 238 | 239 | class CarouselSlidePluginForm(django.forms.ModelForm): 240 | 241 | class Meta: 242 | fields = ['image', 'content', 'link_text', 'classes', 'link_attributes'] 243 | model = models.Bootstrap3CarouselSlidePlugin 244 | 245 | def __init__(self, *args, **kwargs): 246 | super(CarouselSlidePluginForm, self).__init__(*args, **kwargs) 247 | self.fields['link_attributes'].widget = AttributesWidget() 248 | -------------------------------------------------------------------------------- /aldryn_bootstrap3/locale/de/LC_MESSAGES/django.mo: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/divio/aldryn-bootstrap3/bb80aaf6cbe9339718b4240e45907ac61bc0781a/aldryn_bootstrap3/locale/de/LC_MESSAGES/django.mo -------------------------------------------------------------------------------- /aldryn_bootstrap3/locale/en/LC_MESSAGES/django.mo: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/divio/aldryn-bootstrap3/bb80aaf6cbe9339718b4240e45907ac61bc0781a/aldryn_bootstrap3/locale/en/LC_MESSAGES/django.mo -------------------------------------------------------------------------------- /aldryn_bootstrap3/locale/en/LC_MESSAGES/django.po: -------------------------------------------------------------------------------- 1 | # SOME DESCRIPTIVE TITLE. 2 | # Copyright (C) YEAR THE PACKAGE'S COPYRIGHT HOLDER 3 | # This file is distributed under the same license as the PACKAGE package. 4 | # FIRST AUTHOR , YEAR. 5 | # 6 | #, fuzzy 7 | msgid "" 8 | msgstr "" 9 | "Project-Id-Version: PACKAGE VERSION\n" 10 | "Report-Msgid-Bugs-To: \n" 11 | "POT-Creation-Date: 2017-01-26 10:09+0100\n" 12 | "PO-Revision-Date: YEAR-MO-DA HO:MI+ZONE\n" 13 | "Last-Translator: FULL NAME \n" 14 | "Language-Team: LANGUAGE \n" 15 | "Language: \n" 16 | "MIME-Version: 1.0\n" 17 | "Content-Type: text/plain; charset=UTF-8\n" 18 | "Content-Transfer-Encoding: 8bit\n" 19 | 20 | # "Plural-Forms: nplurals=INTEGER; plural=EXPRESSION;\n" 21 | #: cms_plugins.py:35 22 | msgid "Row" 23 | msgstr "" 24 | 25 | #: cms_plugins.py:36 cms_plugins.py:94 cms_plugins.py:130 cms_plugins.py:158 26 | #: cms_plugins.py:188 cms_plugins.py:218 cms_plugins.py:265 cms_plugins.py:363 27 | #: cms_plugins.py:394 cms_plugins.py:425 cms_plugins.py:458 cms_plugins.py:487 28 | #: cms_plugins.py:516 cms_plugins.py:545 cms_plugins.py:584 cms_plugins.py:652 29 | #: cms_plugins.py:682 cms_plugins.py:710 cms_plugins.py:738 cms_plugins.py:766 30 | #: cms_plugins.py:802 cms_plugins.py:832 cms_plugins.py:896 cms_plugins.py:1042 31 | #: cms_plugins.py:1073 32 | msgid "Bootstrap 3" 33 | msgstr "" 34 | 35 | #: cms_plugins.py:44 forms.py:23 36 | msgid "Create columns" 37 | msgstr "" 38 | 39 | #: cms_plugins.py:56 cms_plugins.py:112 cms_plugins.py:141 cms_plugins.py:171 40 | #: cms_plugins.py:201 cms_plugins.py:245 cms_plugins.py:279 cms_plugins.py:375 41 | #: cms_plugins.py:405 cms_plugins.py:438 cms_plugins.py:470 cms_plugins.py:499 42 | #: cms_plugins.py:528 cms_plugins.py:562 cms_plugins.py:608 cms_plugins.py:665 43 | #: cms_plugins.py:693 cms_plugins.py:721 cms_plugins.py:749 cms_plugins.py:780 44 | #: cms_plugins.py:815 cms_plugins.py:844 cms_plugins.py:880 cms_plugins.py:952 45 | #: cms_plugins.py:1006 cms_plugins.py:1054 cms_plugins.py:1087 46 | msgid "Advanced settings" 47 | msgstr "" 48 | 49 | #: cms_plugins.py:93 50 | msgid "Column" 51 | msgstr "" 52 | 53 | #: cms_plugins.py:102 forms.py:78 54 | msgid "Adjust columns" 55 | msgstr "" 56 | 57 | #: cms_plugins.py:129 58 | msgid "Blockquote" 59 | msgstr "" 60 | 61 | #: cms_plugins.py:157 62 | msgid "Cite" 63 | msgstr "" 64 | 65 | #: cms_plugins.py:187 models.py:249 66 | msgid "Code" 67 | msgstr "" 68 | 69 | #: cms_plugins.py:217 70 | msgid "Link/Button" 71 | msgstr "" 72 | 73 | #: cms_plugins.py:237 cms_plugins.py:996 74 | msgid "Link settings" 75 | msgstr "" 76 | 77 | #: cms_plugins.py:264 models.py:322 models.py:1099 78 | msgid "Image" 79 | msgstr "" 80 | 81 | #: cms_plugins.py:362 82 | msgid "Responsive utilities" 83 | msgstr "" 84 | 85 | #: cms_plugins.py:393 model_fields.py:309 models.py:510 86 | msgid "Icon" 87 | msgstr "" 88 | 89 | #: cms_plugins.py:424 models.py:533 models.py:566 90 | msgid "Label" 91 | msgstr "" 92 | 93 | #: cms_plugins.py:457 94 | msgid "Jumbotron" 95 | msgstr "" 96 | 97 | #: cms_plugins.py:486 98 | msgid "Alert" 99 | msgstr "" 100 | 101 | #: cms_plugins.py:515 102 | msgid "List Group" 103 | msgstr "" 104 | 105 | #: cms_plugins.py:544 106 | msgid "List Group Item" 107 | msgstr "" 108 | 109 | #: cms_plugins.py:583 110 | msgid "Panel" 111 | msgstr "" 112 | 113 | #: cms_plugins.py:596 114 | msgid "Create" 115 | msgstr "" 116 | 117 | #: cms_plugins.py:603 118 | msgid "Settings" 119 | msgstr "" 120 | 121 | #: cms_plugins.py:651 122 | msgid "Panel header" 123 | msgstr "" 124 | 125 | #: cms_plugins.py:681 126 | msgid "Panel body" 127 | msgstr "" 128 | 129 | #: cms_plugins.py:709 130 | msgid "Panel footer" 131 | msgstr "" 132 | 133 | #: cms_plugins.py:737 134 | msgid "Well" 135 | msgstr "" 136 | 137 | #: cms_plugins.py:765 138 | msgid "Tab" 139 | msgstr "" 140 | 141 | #: cms_plugins.py:801 142 | msgid "Tab item" 143 | msgstr "" 144 | 145 | #: cms_plugins.py:831 cms_plugins.py:867 146 | msgid "Accordion" 147 | msgstr "" 148 | 149 | #: cms_plugins.py:866 150 | msgid "Accordion item" 151 | msgstr "" 152 | 153 | #: cms_plugins.py:934 154 | msgid "Carousel" 155 | msgstr "" 156 | 157 | #: cms_plugins.py:984 158 | msgid "Carousel slide" 159 | msgstr "" 160 | 161 | #: cms_plugins.py:1022 162 | msgid "Carousel slides folder" 163 | msgstr "" 164 | 165 | #: cms_plugins.py:1041 166 | msgid "Spacer" 167 | msgstr "" 168 | 169 | #: cms_plugins.py:1072 model_fields.py:148 models.py:1197 170 | msgid "File" 171 | msgstr "" 172 | 173 | #: constants.py:15 174 | msgid "Tiny" 175 | msgstr "" 176 | 177 | #: constants.py:16 constants.py:79 178 | msgid "Small" 179 | msgstr "" 180 | 181 | #: constants.py:17 constants.py:78 182 | msgid "Medium" 183 | msgstr "" 184 | 185 | #: constants.py:18 constants.py:77 186 | msgid "Large" 187 | msgstr "" 188 | 189 | #: constants.py:24 models.py:1209 190 | msgid "Open in new window" 191 | msgstr "" 192 | 193 | #: constants.py:25 194 | msgid "Open in same window" 195 | msgstr "" 196 | 197 | #: constants.py:26 198 | msgid "Delegate to parent" 199 | msgstr "" 200 | 201 | #: constants.py:27 202 | msgid "Delegate to top" 203 | msgstr "" 204 | 205 | #: constants.py:31 206 | msgid "Primary" 207 | msgstr "" 208 | 209 | #: constants.py:32 210 | msgid "Success" 211 | msgstr "" 212 | 213 | #: constants.py:33 214 | msgid "Info" 215 | msgstr "" 216 | 217 | #: constants.py:34 218 | msgid "Warning" 219 | msgstr "" 220 | 221 | #: constants.py:35 222 | msgid "Danger" 223 | msgstr "" 224 | 225 | #: constants.py:41 constants.py:49 models.py:541 models.py:664 models.py:700 226 | #: models.py:949 templates/admin/aldryn_bootstrap3/widgets/responsive.html:32 227 | #: templates/admin/aldryn_bootstrap3/widgets/responsive.html:35 228 | #: templates/admin/aldryn_bootstrap3/widgets/responsive_print.html:14 229 | #: templates/admin/aldryn_bootstrap3/widgets/responsive_print.html:17 230 | msgid "Default" 231 | msgstr "" 232 | 233 | #: constants.py:43 234 | msgid "Link" 235 | msgstr "" 236 | 237 | #: constants.py:51 238 | msgid "Muted" 239 | msgstr "" 240 | 241 | #: constants.py:80 242 | msgid "Extra Small" 243 | msgstr "" 244 | 245 | #: constants.py:86 246 | msgid "Mobile phones" 247 | msgstr "" 248 | 249 | #: constants.py:93 250 | msgid "Tablets" 251 | msgstr "" 252 | 253 | #: constants.py:100 254 | msgid "Laptops" 255 | msgstr "" 256 | 257 | #: constants.py:107 258 | msgid "Large desktops" 259 | msgstr "" 260 | 261 | #: forms.py:24 262 | msgid "Number of columns to create in this row." 263 | msgstr "" 264 | 265 | #: forms.py:38 forms.py:93 266 | msgid "Width of created columns (can be edited later if required.)" 267 | msgstr "" 268 | 269 | #: forms.py:46 forms.py:101 270 | msgid "Offset of created columns (can be edited later if required.)" 271 | msgstr "" 272 | 273 | #: forms.py:54 forms.py:109 274 | msgid "Push of created columns (can be edited later if required.)" 275 | msgstr "" 276 | 277 | #: forms.py:62 forms.py:117 278 | msgid "Pull of created columns (can be edited later if required.)" 279 | msgstr "" 280 | 281 | #: forms.py:79 282 | msgid "Adjust this column." 283 | msgstr "" 284 | 285 | #: forms.py:143 model_fields.py:116 286 | msgid "Internal link" 287 | msgstr "" 288 | 289 | #: forms.py:193 290 | msgid "Initial heading" 291 | msgstr "" 292 | 293 | #: forms.py:198 294 | msgid "Initial body" 295 | msgstr "" 296 | 297 | #: forms.py:203 298 | msgid "Initial footer" 299 | msgstr "" 300 | 301 | #: forms.py:234 302 | #, python-brace-format 303 | msgid "Not a valid style (template {path} does not exist)" 304 | msgstr "" 305 | 306 | #: model_fields.py:89 307 | msgid "Classes" 308 | msgstr "" 309 | 310 | #: model_fields.py:95 311 | msgid "" 312 | "Space separated classes that are added to the class. See Bootstrap 3 documentation." 314 | msgstr "" 315 | 316 | #: model_fields.py:110 317 | msgid "External link" 318 | msgstr "" 319 | 320 | #: model_fields.py:113 321 | msgid "Provide a valid URL to an external website." 322 | msgstr "" 323 | 324 | #: model_fields.py:120 325 | msgid "If provided, overrides the external link." 326 | msgstr "" 327 | 328 | #: model_fields.py:123 329 | msgid "Email address" 330 | msgstr "" 331 | 332 | #: model_fields.py:129 333 | msgid "Phone" 334 | msgstr "" 335 | 336 | #: model_fields.py:135 337 | msgid "Anchor" 338 | msgstr "" 339 | 340 | #: model_fields.py:138 341 | msgid "" 342 | "Appends the value only after the internal or external link. Do not " 343 | "include a preceding \"#\" symbol." 344 | msgstr "" 345 | 346 | #: model_fields.py:142 347 | msgid "Target" 348 | msgstr "" 349 | 350 | #: model_fields.py:154 models.py:53 models.py:96 models.py:196 models.py:217 351 | #: models.py:254 models.py:390 models.py:458 models.py:515 models.py:548 352 | #: models.py:579 models.py:604 models.py:628 models.py:680 models.py:707 353 | #: models.py:732 models.py:751 models.py:770 models.py:792 models.py:859 354 | #: models.py:885 models.py:910 models.py:956 models.py:1025 models.py:1180 355 | #: models.py:1222 356 | msgid "Attributes" 357 | msgstr "" 358 | 359 | #: model_fields.py:216 360 | #, python-brace-format 361 | msgid "Only one of {0} or {1} may be given." 362 | msgstr "" 363 | 364 | #: model_fields.py:225 365 | msgid "Please provide a link." 366 | msgstr "" 367 | 368 | #: model_fields.py:231 369 | #, python-format 370 | msgid "" 371 | "%(anchor_field_verbose_name)s is not allowed together with %(field_name)s." 372 | msgstr "" 373 | 374 | #: model_fields.py:247 models.py:278 375 | msgid "Type" 376 | msgstr "" 377 | 378 | #: model_fields.py:278 model_fields.py:371 models.py:282 models.py:295 379 | #: models.py:539 models.py:597 models.py:662 models.py:698 models.py:947 380 | msgid "Context" 381 | msgstr "" 382 | 383 | #: model_fields.py:350 384 | msgid "Responsive" 385 | msgstr "" 386 | 387 | #: models.py:67 models.py:639 models.py:921 388 | msgid "" 389 | msgstr "" 390 | 391 | #: models.py:71 392 | #, python-format 393 | msgid "1 column" 394 | msgid_plural "%(count)i columns" 395 | msgstr[0] "" 396 | msgstr[1] "" 397 | 398 | #: models.py:91 399 | msgid "Tag" 400 | msgstr "" 401 | 402 | #: models.py:188 403 | msgid "Reverse quote" 404 | msgstr "" 405 | 406 | #: models.py:191 407 | msgid "" 408 | "Reverses the position by adding the Bootstrap 3 \"blockquote-reverse\" class." 409 | msgstr "" 410 | 411 | #: models.py:235 templates/admin/aldryn_bootstrap3/widgets/responsive.html:37 412 | #: templates/admin/aldryn_bootstrap3/widgets/responsive_print.html:19 413 | msgid "Inline" 414 | msgstr "" 415 | 416 | #: models.py:236 417 | msgid "User input" 418 | msgstr "" 419 | 420 | #: models.py:237 421 | msgid "Basic block" 422 | msgstr "" 423 | 424 | #: models.py:238 425 | msgid "Variables" 426 | msgstr "" 427 | 428 | #: models.py:239 429 | msgid "Sample output" 430 | msgstr "" 431 | 432 | #: models.py:243 433 | msgid "Code type" 434 | msgstr "" 435 | 436 | #: models.py:272 437 | msgid "Display name" 438 | msgstr "" 439 | 440 | #: models.py:287 models.py:788 models.py:1176 441 | msgid "Size" 442 | msgstr "" 443 | 444 | #: models.py:290 templates/admin/aldryn_bootstrap3/widgets/responsive.html:36 445 | #: templates/admin/aldryn_bootstrap3/widgets/responsive_print.html:18 446 | msgid "Block" 447 | msgstr "" 448 | 449 | #: models.py:302 450 | msgid "Icon left" 451 | msgstr "" 452 | 453 | #: models.py:305 454 | msgid "Icon right" 455 | msgstr "" 456 | 457 | #: models.py:329 458 | msgid "Alternative text" 459 | msgstr "" 460 | 461 | #: models.py:334 models.py:657 models.py:725 models.py:942 462 | msgid "Title" 463 | msgstr "" 464 | 465 | #: models.py:339 466 | msgid "Use original image" 467 | msgstr "" 468 | 469 | #: models.py:342 470 | msgid "Outputs the raw image without cropping." 471 | msgstr "" 472 | 473 | #: models.py:345 474 | msgid "Override width" 475 | msgstr "" 476 | 477 | #: models.py:348 478 | msgid "" 479 | "The image width as number in pixels. Example: \"720\" and not \"720px\"." 480 | msgstr "" 481 | 482 | #: models.py:352 483 | msgid "Override height" 484 | msgstr "" 485 | 486 | #: models.py:355 487 | msgid "" 488 | "The image height as number in pixels. Example: \"720\" and not \"720px\"." 489 | msgstr "" 490 | 491 | #: models.py:359 models.py:988 models.py:1043 492 | msgid "Aspect ratio" 493 | msgstr "" 494 | 495 | #: models.py:364 496 | msgid "" 497 | "Determines width and height of the image according to the selected ratio." 498 | msgstr "" 499 | 500 | #: models.py:368 501 | msgid "Shape" 502 | msgstr "" 503 | 504 | #: models.py:381 505 | msgid "Adds the Bootstrap 3 \".img-thumbnail\" class." 506 | msgstr "" 507 | 508 | #: models.py:387 509 | msgid "Adds the Bootstrap 3 \".img-responsive\" class." 510 | msgstr "" 511 | 512 | #: models.py:449 513 | msgid "Devices" 514 | msgstr "" 515 | 516 | #: models.py:453 517 | msgid "Print" 518 | msgstr "" 519 | 520 | #: models.py:571 521 | msgid "Add container" 522 | msgstr "" 523 | 524 | #: models.py:574 525 | msgid "" 526 | "Adds a \".container\" element inside the \"Jumbotron\" for use outside of a " 527 | "grid." 528 | msgstr "" 529 | 530 | #: models.py:600 models.py:881 531 | msgid "Title icon" 532 | msgstr "" 533 | 534 | #: models.py:624 535 | msgid "Adds the list-group and subsequent list-group-item classes." 536 | msgstr "" 537 | 538 | #: models.py:643 models.py:925 539 | #, python-format 540 | msgid "1 item" 541 | msgid_plural "%(count)i items" 542 | msgstr[0] "" 543 | msgstr[1] "" 544 | 545 | #: models.py:670 546 | msgid "State" 547 | msgstr "" 548 | 549 | #: models.py:672 550 | msgid "Active" 551 | msgstr "" 552 | 553 | #: models.py:673 554 | msgid "Disabled" 555 | msgstr "" 556 | 557 | #: models.py:728 558 | msgid "Panels can have additional plugins." 559 | msgstr "" 560 | 561 | #: models.py:830 562 | msgid "Tabs" 563 | msgstr "" 564 | 565 | #: models.py:831 566 | msgid "Tabs justified" 567 | msgstr "" 568 | 569 | #: models.py:832 570 | msgid "Pills" 571 | msgstr "" 572 | 573 | #: models.py:833 574 | msgid "Pills justified" 575 | msgstr "" 576 | 577 | #: models.py:836 578 | msgid "Fade" 579 | msgstr "" 580 | 581 | #: models.py:840 models.py:903 582 | msgid "Index" 583 | msgstr "" 584 | 585 | #: models.py:843 models.py:906 586 | msgid "Index of element to open on page load (optional)." 587 | msgstr "" 588 | 589 | #: models.py:846 590 | msgid "Display type" 591 | msgstr "" 592 | 593 | #: models.py:852 594 | msgid "Animation effect" 595 | msgstr "" 596 | 597 | #: models.py:877 598 | msgid "Tab title" 599 | msgstr "" 600 | 601 | #: models.py:975 602 | msgid "Standard" 603 | msgstr "" 604 | 605 | #: models.py:978 606 | msgid "Slide" 607 | msgstr "" 608 | 609 | #: models.py:982 models.py:1039 610 | msgid "Style" 611 | msgstr "" 612 | 613 | #: models.py:995 models.py:1040 614 | msgid "Transition effect" 615 | msgstr "" 616 | 617 | #: models.py:1002 models.py:1041 618 | msgid "Ride" 619 | msgstr "" 620 | 621 | #: models.py:1004 622 | msgid "Auto-starts animation of the carousel." 623 | msgstr "" 624 | 625 | #: models.py:1007 models.py:1042 626 | msgid "Interval" 627 | msgstr "" 628 | 629 | #: models.py:1009 630 | msgid "Time (in milliseconds) between items." 631 | msgstr "" 632 | 633 | #: models.py:1012 634 | msgid "Wrap" 635 | msgstr "" 636 | 637 | #: models.py:1015 638 | msgid "Loops carousel animation." 639 | msgstr "" 640 | 641 | #: models.py:1018 642 | msgid "Pause" 643 | msgstr "" 644 | 645 | #: models.py:1021 646 | msgid "Pauses the carousel on hover." 647 | msgstr "" 648 | 649 | #: models.py:1106 650 | msgid "Link text" 651 | msgstr "" 652 | 653 | #: models.py:1111 654 | msgid "Content" 655 | msgstr "" 656 | 657 | #: models.py:1114 658 | msgid "Content may also be added using child plugins." 659 | msgstr "" 660 | 661 | #: models.py:1151 662 | msgid "Folder" 663 | msgstr "" 664 | 665 | #: models.py:1161 666 | msgid "" 667 | msgstr "" 668 | 669 | #: models.py:1204 670 | msgid "Name" 671 | msgstr "" 672 | 673 | #: models.py:1213 674 | msgid "Show file size" 675 | msgstr "" 676 | 677 | #: templates/admin/aldryn_bootstrap3/plugins/button/change_form.html:9 678 | #: templates/admin/aldryn_bootstrap3/plugins/label/change_form.html:9 679 | msgid "Preview" 680 | msgstr "" 681 | 682 | #: templates/admin/aldryn_bootstrap3/widgets/icon.html:8 683 | msgid "" 684 | "No Iconsets configured. Please configure at least one Iconset before using " 685 | "this widget." 686 | msgstr "" 687 | 688 | #: templates/admin/aldryn_bootstrap3/widgets/responsive.html:8 689 | #: templates/admin/aldryn_bootstrap3/widgets/responsive.html:14 690 | #: templates/admin/aldryn_bootstrap3/widgets/responsive.html:20 691 | #: templates/admin/aldryn_bootstrap3/widgets/responsive.html:26 692 | #: templates/admin/aldryn_bootstrap3/widgets/responsive_print.html:8 693 | msgid "Visible" 694 | msgstr "" 695 | 696 | #: templates/admin/aldryn_bootstrap3/widgets/responsive.html:9 697 | #: templates/admin/aldryn_bootstrap3/widgets/responsive.html:15 698 | #: templates/admin/aldryn_bootstrap3/widgets/responsive.html:21 699 | #: templates/admin/aldryn_bootstrap3/widgets/responsive.html:27 700 | #: templates/admin/aldryn_bootstrap3/widgets/responsive_print.html:9 701 | msgid "Hidden" 702 | msgstr "" 703 | 704 | #: templates/admin/aldryn_bootstrap3/widgets/responsive.html:38 705 | #: templates/admin/aldryn_bootstrap3/widgets/responsive_print.html:20 706 | msgid "Inline block" 707 | msgstr "" 708 | 709 | #: templates/aldryn_bootstrap3/plugins/carousel/standard/carousel.html:23 710 | msgid "Previous" 711 | msgstr "" 712 | 713 | #: templates/aldryn_bootstrap3/plugins/carousel/standard/carousel.html:27 714 | msgid "Next" 715 | msgstr "" 716 | -------------------------------------------------------------------------------- /aldryn_bootstrap3/locale/es/LC_MESSAGES/django.mo: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/divio/aldryn-bootstrap3/bb80aaf6cbe9339718b4240e45907ac61bc0781a/aldryn_bootstrap3/locale/es/LC_MESSAGES/django.mo -------------------------------------------------------------------------------- /aldryn_bootstrap3/locale/es/LC_MESSAGES/django.po: -------------------------------------------------------------------------------- 1 | # SOME DESCRIPTIVE TITLE. 2 | # Copyright (C) YEAR THE PACKAGE'S COPYRIGHT HOLDER 3 | # This file is distributed under the same license as the PACKAGE package. 4 | # FIRST AUTHOR , YEAR. 5 | # 6 | #, fuzzy 7 | msgid "" 8 | msgstr "" 9 | "Project-Id-Version: PACKAGE VERSION\n" 10 | "Report-Msgid-Bugs-To: \n" 11 | "POT-Creation-Date: 2017-01-26 10:09+0100\n" 12 | "PO-Revision-Date: YEAR-MO-DA HO:MI+ZONE\n" 13 | "Language-Team: Spanish (https://www.transifex.com/divio/teams/58664/es/)\n" 14 | "MIME-Version: 1.0\n" 15 | "Content-Type: text/plain; charset=UTF-8\n" 16 | "Content-Transfer-Encoding: 8bit\n" 17 | "Language: es\n" 18 | "Plural-Forms: nplurals=2; plural=(n != 1);\n" 19 | 20 | # "Plural-Forms: nplurals=INTEGER; plural=EXPRESSION;\n" 21 | #: cms_plugins.py:35 22 | msgid "Row" 23 | msgstr "" 24 | 25 | #: cms_plugins.py:36 cms_plugins.py:94 cms_plugins.py:130 cms_plugins.py:158 26 | #: cms_plugins.py:188 cms_plugins.py:218 cms_plugins.py:265 cms_plugins.py:363 27 | #: cms_plugins.py:394 cms_plugins.py:425 cms_plugins.py:458 cms_plugins.py:487 28 | #: cms_plugins.py:516 cms_plugins.py:545 cms_plugins.py:584 cms_plugins.py:652 29 | #: cms_plugins.py:682 cms_plugins.py:710 cms_plugins.py:738 cms_plugins.py:766 30 | #: cms_plugins.py:802 cms_plugins.py:832 cms_plugins.py:896 31 | #: cms_plugins.py:1042 cms_plugins.py:1073 32 | msgid "Bootstrap 3" 33 | msgstr "" 34 | 35 | #: cms_plugins.py:44 forms.py:23 36 | msgid "Create columns" 37 | msgstr "" 38 | 39 | #: cms_plugins.py:56 cms_plugins.py:112 cms_plugins.py:141 cms_plugins.py:171 40 | #: cms_plugins.py:201 cms_plugins.py:245 cms_plugins.py:279 cms_plugins.py:375 41 | #: cms_plugins.py:405 cms_plugins.py:438 cms_plugins.py:470 cms_plugins.py:499 42 | #: cms_plugins.py:528 cms_plugins.py:562 cms_plugins.py:608 cms_plugins.py:665 43 | #: cms_plugins.py:693 cms_plugins.py:721 cms_plugins.py:749 cms_plugins.py:780 44 | #: cms_plugins.py:815 cms_plugins.py:844 cms_plugins.py:880 cms_plugins.py:952 45 | #: cms_plugins.py:1006 cms_plugins.py:1054 cms_plugins.py:1087 46 | msgid "Advanced settings" 47 | msgstr "" 48 | 49 | #: cms_plugins.py:93 50 | msgid "Column" 51 | msgstr "" 52 | 53 | #: cms_plugins.py:102 forms.py:78 54 | msgid "Adjust columns" 55 | msgstr "" 56 | 57 | #: cms_plugins.py:129 58 | msgid "Blockquote" 59 | msgstr "" 60 | 61 | #: cms_plugins.py:157 62 | msgid "Cite" 63 | msgstr "" 64 | 65 | #: cms_plugins.py:187 models.py:249 66 | msgid "Code" 67 | msgstr "" 68 | 69 | #: cms_plugins.py:217 70 | msgid "Link/Button" 71 | msgstr "" 72 | 73 | #: cms_plugins.py:237 cms_plugins.py:996 74 | msgid "Link settings" 75 | msgstr "" 76 | 77 | #: cms_plugins.py:264 models.py:322 models.py:1099 78 | msgid "Image" 79 | msgstr "" 80 | 81 | #: cms_plugins.py:362 82 | msgid "Responsive utilities" 83 | msgstr "" 84 | 85 | #: cms_plugins.py:393 model_fields.py:309 models.py:510 86 | msgid "Icon" 87 | msgstr "" 88 | 89 | #: cms_plugins.py:424 models.py:533 models.py:566 90 | msgid "Label" 91 | msgstr "" 92 | 93 | #: cms_plugins.py:457 94 | msgid "Jumbotron" 95 | msgstr "" 96 | 97 | #: cms_plugins.py:486 98 | msgid "Alert" 99 | msgstr "" 100 | 101 | #: cms_plugins.py:515 102 | msgid "List Group" 103 | msgstr "" 104 | 105 | #: cms_plugins.py:544 106 | msgid "List Group Item" 107 | msgstr "" 108 | 109 | #: cms_plugins.py:583 110 | msgid "Panel" 111 | msgstr "" 112 | 113 | #: cms_plugins.py:596 114 | msgid "Create" 115 | msgstr "" 116 | 117 | #: cms_plugins.py:603 118 | msgid "Settings" 119 | msgstr "" 120 | 121 | #: cms_plugins.py:651 122 | msgid "Panel header" 123 | msgstr "" 124 | 125 | #: cms_plugins.py:681 126 | msgid "Panel body" 127 | msgstr "" 128 | 129 | #: cms_plugins.py:709 130 | msgid "Panel footer" 131 | msgstr "" 132 | 133 | #: cms_plugins.py:737 134 | msgid "Well" 135 | msgstr "" 136 | 137 | #: cms_plugins.py:765 138 | msgid "Tab" 139 | msgstr "" 140 | 141 | #: cms_plugins.py:801 142 | msgid "Tab item" 143 | msgstr "" 144 | 145 | #: cms_plugins.py:831 cms_plugins.py:867 146 | msgid "Accordion" 147 | msgstr "" 148 | 149 | #: cms_plugins.py:866 150 | msgid "Accordion item" 151 | msgstr "" 152 | 153 | #: cms_plugins.py:934 154 | msgid "Carousel" 155 | msgstr "" 156 | 157 | #: cms_plugins.py:984 158 | msgid "Carousel slide" 159 | msgstr "" 160 | 161 | #: cms_plugins.py:1022 162 | msgid "Carousel slides folder" 163 | msgstr "" 164 | 165 | #: cms_plugins.py:1041 166 | msgid "Spacer" 167 | msgstr "" 168 | 169 | #: cms_plugins.py:1072 model_fields.py:148 models.py:1197 170 | msgid "File" 171 | msgstr "" 172 | 173 | #: constants.py:15 174 | msgid "Tiny" 175 | msgstr "" 176 | 177 | #: constants.py:16 constants.py:79 178 | msgid "Small" 179 | msgstr "" 180 | 181 | #: constants.py:17 constants.py:78 182 | msgid "Medium" 183 | msgstr "" 184 | 185 | #: constants.py:18 constants.py:77 186 | msgid "Large" 187 | msgstr "" 188 | 189 | #: constants.py:24 models.py:1209 190 | msgid "Open in new window" 191 | msgstr "" 192 | 193 | #: constants.py:25 194 | msgid "Open in same window" 195 | msgstr "" 196 | 197 | #: constants.py:26 198 | msgid "Delegate to parent" 199 | msgstr "" 200 | 201 | #: constants.py:27 202 | msgid "Delegate to top" 203 | msgstr "" 204 | 205 | #: constants.py:31 206 | msgid "Primary" 207 | msgstr "" 208 | 209 | #: constants.py:32 210 | msgid "Success" 211 | msgstr "" 212 | 213 | #: constants.py:33 214 | msgid "Info" 215 | msgstr "" 216 | 217 | #: constants.py:34 218 | msgid "Warning" 219 | msgstr "" 220 | 221 | #: constants.py:35 222 | msgid "Danger" 223 | msgstr "" 224 | 225 | #: constants.py:41 constants.py:49 models.py:541 models.py:664 models.py:700 226 | #: models.py:949 templates/admin/aldryn_bootstrap3/widgets/responsive.html:32 227 | #: templates/admin/aldryn_bootstrap3/widgets/responsive.html:35 228 | #: templates/admin/aldryn_bootstrap3/widgets/responsive_print.html:14 229 | #: templates/admin/aldryn_bootstrap3/widgets/responsive_print.html:17 230 | msgid "Default" 231 | msgstr "" 232 | 233 | #: constants.py:43 234 | msgid "Link" 235 | msgstr "" 236 | 237 | #: constants.py:51 238 | msgid "Muted" 239 | msgstr "" 240 | 241 | #: constants.py:80 242 | msgid "Extra Small" 243 | msgstr "" 244 | 245 | #: constants.py:86 246 | msgid "Mobile phones" 247 | msgstr "" 248 | 249 | #: constants.py:93 250 | msgid "Tablets" 251 | msgstr "" 252 | 253 | #: constants.py:100 254 | msgid "Laptops" 255 | msgstr "" 256 | 257 | #: constants.py:107 258 | msgid "Large desktops" 259 | msgstr "" 260 | 261 | #: forms.py:24 262 | msgid "Number of columns to create in this row." 263 | msgstr "" 264 | 265 | #: forms.py:38 forms.py:93 266 | msgid "Width of created columns (can be edited later if required.)" 267 | msgstr "" 268 | 269 | #: forms.py:46 forms.py:101 270 | msgid "Offset of created columns (can be edited later if required.)" 271 | msgstr "" 272 | 273 | #: forms.py:54 forms.py:109 274 | msgid "Push of created columns (can be edited later if required.)" 275 | msgstr "" 276 | 277 | #: forms.py:62 forms.py:117 278 | msgid "Pull of created columns (can be edited later if required.)" 279 | msgstr "" 280 | 281 | #: forms.py:79 282 | msgid "Adjust this column." 283 | msgstr "" 284 | 285 | #: forms.py:143 model_fields.py:116 286 | msgid "Internal link" 287 | msgstr "" 288 | 289 | #: forms.py:193 290 | msgid "Initial heading" 291 | msgstr "" 292 | 293 | #: forms.py:198 294 | msgid "Initial body" 295 | msgstr "" 296 | 297 | #: forms.py:203 298 | msgid "Initial footer" 299 | msgstr "" 300 | 301 | #: forms.py:234 302 | #, python-brace-format 303 | msgid "Not a valid style (template {path} does not exist)" 304 | msgstr "" 305 | 306 | #: model_fields.py:89 307 | msgid "Classes" 308 | msgstr "" 309 | 310 | #: model_fields.py:95 311 | msgid "" 312 | "Space separated classes that are added to the class. See Bootstrap 3 " 314 | "documentation." 315 | msgstr "" 316 | 317 | #: model_fields.py:110 318 | msgid "External link" 319 | msgstr "" 320 | 321 | #: model_fields.py:113 322 | msgid "Provide a valid URL to an external website." 323 | msgstr "" 324 | 325 | #: model_fields.py:120 326 | msgid "If provided, overrides the external link." 327 | msgstr "" 328 | 329 | #: model_fields.py:123 330 | msgid "Email address" 331 | msgstr "" 332 | 333 | #: model_fields.py:129 334 | msgid "Phone" 335 | msgstr "" 336 | 337 | #: model_fields.py:135 338 | msgid "Anchor" 339 | msgstr "" 340 | 341 | #: model_fields.py:138 342 | msgid "" 343 | "Appends the value only after the internal or external link. Do not " 344 | "include a preceding \"#\" symbol." 345 | msgstr "" 346 | 347 | #: model_fields.py:142 348 | msgid "Target" 349 | msgstr "" 350 | 351 | #: model_fields.py:154 models.py:53 models.py:96 models.py:196 models.py:217 352 | #: models.py:254 models.py:390 models.py:458 models.py:515 models.py:548 353 | #: models.py:579 models.py:604 models.py:628 models.py:680 models.py:707 354 | #: models.py:732 models.py:751 models.py:770 models.py:792 models.py:859 355 | #: models.py:885 models.py:910 models.py:956 models.py:1025 models.py:1180 356 | #: models.py:1222 357 | msgid "Attributes" 358 | msgstr "" 359 | 360 | #: model_fields.py:216 361 | #, python-brace-format 362 | msgid "Only one of {0} or {1} may be given." 363 | msgstr "" 364 | 365 | #: model_fields.py:225 366 | msgid "Please provide a link." 367 | msgstr "" 368 | 369 | #: model_fields.py:231 370 | #, python-format 371 | msgid "" 372 | "%(anchor_field_verbose_name)s is not allowed together with %(field_name)s." 373 | msgstr "" 374 | 375 | #: model_fields.py:247 models.py:278 376 | msgid "Type" 377 | msgstr "" 378 | 379 | #: model_fields.py:278 model_fields.py:371 models.py:282 models.py:295 380 | #: models.py:539 models.py:597 models.py:662 models.py:698 models.py:947 381 | msgid "Context" 382 | msgstr "" 383 | 384 | #: model_fields.py:350 385 | msgid "Responsive" 386 | msgstr "" 387 | 388 | #: models.py:67 models.py:639 models.py:921 389 | msgid "" 390 | msgstr "" 391 | 392 | #: models.py:71 393 | #, python-format 394 | msgid "1 column" 395 | msgid_plural "%(count)i columns" 396 | msgstr[0] "" 397 | msgstr[1] "" 398 | 399 | #: models.py:91 400 | msgid "Tag" 401 | msgstr "" 402 | 403 | #: models.py:188 404 | msgid "Reverse quote" 405 | msgstr "" 406 | 407 | #: models.py:191 408 | msgid "" 409 | "Reverses the position by adding the Bootstrap 3 \"blockquote-reverse\" " 410 | "class." 411 | msgstr "" 412 | 413 | #: models.py:235 templates/admin/aldryn_bootstrap3/widgets/responsive.html:37 414 | #: templates/admin/aldryn_bootstrap3/widgets/responsive_print.html:19 415 | msgid "Inline" 416 | msgstr "" 417 | 418 | #: models.py:236 419 | msgid "User input" 420 | msgstr "" 421 | 422 | #: models.py:237 423 | msgid "Basic block" 424 | msgstr "" 425 | 426 | #: models.py:238 427 | msgid "Variables" 428 | msgstr "" 429 | 430 | #: models.py:239 431 | msgid "Sample output" 432 | msgstr "" 433 | 434 | #: models.py:243 435 | msgid "Code type" 436 | msgstr "" 437 | 438 | #: models.py:272 439 | msgid "Display name" 440 | msgstr "" 441 | 442 | #: models.py:287 models.py:788 models.py:1176 443 | msgid "Size" 444 | msgstr "" 445 | 446 | #: models.py:290 templates/admin/aldryn_bootstrap3/widgets/responsive.html:36 447 | #: templates/admin/aldryn_bootstrap3/widgets/responsive_print.html:18 448 | msgid "Block" 449 | msgstr "" 450 | 451 | #: models.py:302 452 | msgid "Icon left" 453 | msgstr "" 454 | 455 | #: models.py:305 456 | msgid "Icon right" 457 | msgstr "" 458 | 459 | #: models.py:329 460 | msgid "Alternative text" 461 | msgstr "" 462 | 463 | #: models.py:334 models.py:657 models.py:725 models.py:942 464 | msgid "Title" 465 | msgstr "" 466 | 467 | #: models.py:339 468 | msgid "Use original image" 469 | msgstr "" 470 | 471 | #: models.py:342 472 | msgid "Outputs the raw image without cropping." 473 | msgstr "" 474 | 475 | #: models.py:345 476 | msgid "Override width" 477 | msgstr "" 478 | 479 | #: models.py:348 480 | msgid "The image width as number in pixels. Example: \"720\" and not \"720px\"." 481 | msgstr "" 482 | 483 | #: models.py:352 484 | msgid "Override height" 485 | msgstr "" 486 | 487 | #: models.py:355 488 | msgid "The image height as number in pixels. Example: \"720\" and not \"720px\"." 489 | msgstr "" 490 | 491 | #: models.py:359 models.py:988 models.py:1043 492 | msgid "Aspect ratio" 493 | msgstr "" 494 | 495 | #: models.py:364 496 | msgid "" 497 | "Determines width and height of the image according to the selected ratio." 498 | msgstr "" 499 | 500 | #: models.py:368 501 | msgid "Shape" 502 | msgstr "" 503 | 504 | #: models.py:381 505 | msgid "Adds the Bootstrap 3 \".img-thumbnail\" class." 506 | msgstr "" 507 | 508 | #: models.py:387 509 | msgid "Adds the Bootstrap 3 \".img-responsive\" class." 510 | msgstr "" 511 | 512 | #: models.py:449 513 | msgid "Devices" 514 | msgstr "" 515 | 516 | #: models.py:453 517 | msgid "Print" 518 | msgstr "" 519 | 520 | #: models.py:571 521 | msgid "Add container" 522 | msgstr "" 523 | 524 | #: models.py:574 525 | msgid "" 526 | "Adds a \".container\" element inside the \"Jumbotron\" for use outside of a " 527 | "grid." 528 | msgstr "" 529 | 530 | #: models.py:600 models.py:881 531 | msgid "Title icon" 532 | msgstr "" 533 | 534 | #: models.py:624 535 | msgid "Adds the list-group and subsequent list-group-item classes." 536 | msgstr "" 537 | 538 | #: models.py:643 models.py:925 539 | #, python-format 540 | msgid "1 item" 541 | msgid_plural "%(count)i items" 542 | msgstr[0] "" 543 | msgstr[1] "" 544 | 545 | #: models.py:670 546 | msgid "State" 547 | msgstr "" 548 | 549 | #: models.py:672 550 | msgid "Active" 551 | msgstr "" 552 | 553 | #: models.py:673 554 | msgid "Disabled" 555 | msgstr "" 556 | 557 | #: models.py:728 558 | msgid "Panels can have additional plugins." 559 | msgstr "" 560 | 561 | #: models.py:830 562 | msgid "Tabs" 563 | msgstr "" 564 | 565 | #: models.py:831 566 | msgid "Tabs justified" 567 | msgstr "" 568 | 569 | #: models.py:832 570 | msgid "Pills" 571 | msgstr "" 572 | 573 | #: models.py:833 574 | msgid "Pills justified" 575 | msgstr "" 576 | 577 | #: models.py:836 578 | msgid "Fade" 579 | msgstr "" 580 | 581 | #: models.py:840 models.py:903 582 | msgid "Index" 583 | msgstr "" 584 | 585 | #: models.py:843 models.py:906 586 | msgid "Index of element to open on page load (optional)." 587 | msgstr "" 588 | 589 | #: models.py:846 590 | msgid "Display type" 591 | msgstr "" 592 | 593 | #: models.py:852 594 | msgid "Animation effect" 595 | msgstr "" 596 | 597 | #: models.py:877 598 | msgid "Tab title" 599 | msgstr "" 600 | 601 | #: models.py:975 602 | msgid "Standard" 603 | msgstr "" 604 | 605 | #: models.py:978 606 | msgid "Slide" 607 | msgstr "" 608 | 609 | #: models.py:982 models.py:1039 610 | msgid "Style" 611 | msgstr "" 612 | 613 | #: models.py:995 models.py:1040 614 | msgid "Transition effect" 615 | msgstr "" 616 | 617 | #: models.py:1002 models.py:1041 618 | msgid "Ride" 619 | msgstr "" 620 | 621 | #: models.py:1004 622 | msgid "Auto-starts animation of the carousel." 623 | msgstr "" 624 | 625 | #: models.py:1007 models.py:1042 626 | msgid "Interval" 627 | msgstr "" 628 | 629 | #: models.py:1009 630 | msgid "Time (in milliseconds) between items." 631 | msgstr "" 632 | 633 | #: models.py:1012 634 | msgid "Wrap" 635 | msgstr "" 636 | 637 | #: models.py:1015 638 | msgid "Loops carousel animation." 639 | msgstr "" 640 | 641 | #: models.py:1018 642 | msgid "Pause" 643 | msgstr "" 644 | 645 | #: models.py:1021 646 | msgid "Pauses the carousel on hover." 647 | msgstr "" 648 | 649 | #: models.py:1106 650 | msgid "Link text" 651 | msgstr "" 652 | 653 | #: models.py:1111 654 | msgid "Content" 655 | msgstr "" 656 | 657 | #: models.py:1114 658 | msgid "Content may also be added using child plugins." 659 | msgstr "" 660 | 661 | #: models.py:1151 662 | msgid "Folder" 663 | msgstr "" 664 | 665 | #: models.py:1161 666 | msgid "" 667 | msgstr "" 668 | 669 | #: models.py:1204 670 | msgid "Name" 671 | msgstr "" 672 | 673 | #: models.py:1213 674 | msgid "Show file size" 675 | msgstr "" 676 | 677 | #: templates/admin/aldryn_bootstrap3/plugins/button/change_form.html:9 678 | #: templates/admin/aldryn_bootstrap3/plugins/label/change_form.html:9 679 | msgid "Preview" 680 | msgstr "" 681 | 682 | #: templates/admin/aldryn_bootstrap3/widgets/icon.html:8 683 | msgid "" 684 | "No Iconsets configured. Please configure at least one Iconset before using " 685 | "this widget." 686 | msgstr "" 687 | 688 | #: templates/admin/aldryn_bootstrap3/widgets/responsive.html:8 689 | #: templates/admin/aldryn_bootstrap3/widgets/responsive.html:14 690 | #: templates/admin/aldryn_bootstrap3/widgets/responsive.html:20 691 | #: templates/admin/aldryn_bootstrap3/widgets/responsive.html:26 692 | #: templates/admin/aldryn_bootstrap3/widgets/responsive_print.html:8 693 | msgid "Visible" 694 | msgstr "" 695 | 696 | #: templates/admin/aldryn_bootstrap3/widgets/responsive.html:9 697 | #: templates/admin/aldryn_bootstrap3/widgets/responsive.html:15 698 | #: templates/admin/aldryn_bootstrap3/widgets/responsive.html:21 699 | #: templates/admin/aldryn_bootstrap3/widgets/responsive.html:27 700 | #: templates/admin/aldryn_bootstrap3/widgets/responsive_print.html:9 701 | msgid "Hidden" 702 | msgstr "" 703 | 704 | #: templates/admin/aldryn_bootstrap3/widgets/responsive.html:38 705 | #: templates/admin/aldryn_bootstrap3/widgets/responsive_print.html:20 706 | msgid "Inline block" 707 | msgstr "" 708 | 709 | #: templates/aldryn_bootstrap3/plugins/carousel/standard/carousel.html:23 710 | msgid "Previous" 711 | msgstr "" 712 | 713 | #: templates/aldryn_bootstrap3/plugins/carousel/standard/carousel.html:27 714 | msgid "Next" 715 | msgstr "" 716 | -------------------------------------------------------------------------------- /aldryn_bootstrap3/locale/fr/LC_MESSAGES/django.mo: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/divio/aldryn-bootstrap3/bb80aaf6cbe9339718b4240e45907ac61bc0781a/aldryn_bootstrap3/locale/fr/LC_MESSAGES/django.mo -------------------------------------------------------------------------------- /aldryn_bootstrap3/locale/it/LC_MESSAGES/django.mo: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/divio/aldryn-bootstrap3/bb80aaf6cbe9339718b4240e45907ac61bc0781a/aldryn_bootstrap3/locale/it/LC_MESSAGES/django.mo -------------------------------------------------------------------------------- /aldryn_bootstrap3/locale/ru/LC_MESSAGES/django.mo: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/divio/aldryn-bootstrap3/bb80aaf6cbe9339718b4240e45907ac61bc0781a/aldryn_bootstrap3/locale/ru/LC_MESSAGES/django.mo -------------------------------------------------------------------------------- /aldryn_bootstrap3/migrations/0002_bootstrap3fileplugin.py: -------------------------------------------------------------------------------- 1 | # -*- coding: utf-8 -*- 2 | from __future__ import unicode_literals 3 | 4 | from django.db import models, migrations 5 | import filer.fields.file 6 | import aldryn_bootstrap3.model_fields 7 | import django.db.models.deletion 8 | 9 | 10 | class Migration(migrations.Migration): 11 | 12 | dependencies = [ 13 | ('filer', '0002_auto_20150606_2003'), 14 | ('cms', '0011_auto_20150419_1006'), 15 | ('aldryn_bootstrap3', '0001_initial'), 16 | ] 17 | 18 | operations = [ 19 | migrations.CreateModel( 20 | name='Bootstrap3FilePlugin', 21 | fields=[ 22 | ('cmsplugin_ptr', models.OneToOneField(parent_link=True, related_name='+', primary_key=True, serialize=False, to='cms.CMSPlugin', on_delete=models.CASCADE)), 23 | ('name', aldryn_bootstrap3.model_fields.MiniText(default='', verbose_name='name', blank=True)), 24 | ('open_new_window', models.BooleanField(default=False)), 25 | ('show_file_size', models.BooleanField(default=False)), 26 | ('icon_left', aldryn_bootstrap3.model_fields.Icon(default='', max_length=255, blank=True)), 27 | ('icon_right', aldryn_bootstrap3.model_fields.Icon(default='', max_length=255, blank=True)), 28 | ('classes', aldryn_bootstrap3.model_fields.Classes(default='', help_text='space separated classes that are added to the class. see bootstrap docs', blank=True)), 29 | ('file', filer.fields.file.FilerFileField(related_name='+', on_delete=django.db.models.deletion.SET_NULL, verbose_name='file', to='filer.File', null=True)), 30 | ], 31 | options={ 32 | 'abstract': False, 33 | }, 34 | bases=('cms.cmsplugin',), 35 | ), 36 | ] 37 | -------------------------------------------------------------------------------- /aldryn_bootstrap3/migrations/0003_auto_20151113_1604.py: -------------------------------------------------------------------------------- 1 | # -*- coding: utf-8 -*- 2 | from __future__ import unicode_literals 3 | 4 | from django.db import models, migrations 5 | import aldryn_bootstrap3.model_fields 6 | 7 | 8 | class Migration(migrations.Migration): 9 | 10 | dependencies = [ 11 | ('aldryn_bootstrap3', '0002_bootstrap3fileplugin'), 12 | ] 13 | 14 | operations = [ 15 | migrations.AddField( 16 | model_name='boostrap3imageplugin', 17 | name='override_height', 18 | field=models.IntegerField(help_text='if this field is provided - it would be used across all devices instead of default for devices types. If aspect ration is selected - height will be calculated based on that.', null=True, verbose_name='override height', blank=True), 19 | preserve_default=True, 20 | ), 21 | migrations.AddField( 22 | model_name='boostrap3imageplugin', 23 | name='override_width', 24 | field=models.IntegerField(help_text='if this field is provided - it would be used across all devices instead of default for devices types.', null=True, verbose_name='override width', blank=True), 25 | preserve_default=True, 26 | ), 27 | migrations.AlterField( 28 | model_name='boostrap3buttonplugin', 29 | name='btn_context', 30 | field=aldryn_bootstrap3.model_fields.Context(default='default', max_length=255, verbose_name='context', choices=[('default', 'Default'), ('primary', 'Primary'), ('success', 'Success'), ('info', 'Info'), ('warning', 'Warning'), ('danger', 'Danger'), ('link', 'Link')]), 31 | preserve_default=True, 32 | ), 33 | migrations.AlterField( 34 | model_name='boostrap3buttonplugin', 35 | name='link_mailto', 36 | field=models.EmailField(max_length=75, null=True, verbose_name='email address', blank=True), 37 | preserve_default=True, 38 | ), 39 | migrations.AlterField( 40 | model_name='boostrap3buttonplugin', 41 | name='txt_context', 42 | field=aldryn_bootstrap3.model_fields.Context(default='', max_length=255, verbose_name='context', blank=True, choices=[('', 'Default'), ('primary', 'Primary'), ('success', 'Success'), ('info', 'Info'), ('warning', 'Warning'), ('danger', 'Danger'), ('muted ', 'Muted')]), 43 | preserve_default=True, 44 | ), 45 | migrations.AlterField( 46 | model_name='boostrap3imageplugin', 47 | name='aspect_ratio', 48 | field=models.CharField(default='', max_length=10, verbose_name='aspect ratio', blank=True, choices=[('1x1', '1x1'), ('4x3', '4x3'), ('16x9', '16x9'), ('16x10', '16x10'), ('21x9', '21x9'), ('3x4', '3x4'), ('9x16', '9x16'), ('10x16', '10x16'), ('9x21', '9x21')]), 49 | preserve_default=True, 50 | ), 51 | migrations.AlterField( 52 | model_name='bootstrap3carouselplugin', 53 | name='aspect_ratio', 54 | field=models.CharField(default='', max_length=10, verbose_name='aspect ratio', blank=True, choices=[('1x1', '1x1'), ('4x3', '4x3'), ('16x9', '16x9'), ('16x10', '16x10'), ('21x9', '21x9'), ('3x4', '3x4'), ('9x16', '9x16'), ('10x16', '10x16'), ('9x21', '9x21')]), 55 | preserve_default=True, 56 | ), 57 | migrations.AlterField( 58 | model_name='bootstrap3carouselslideplugin', 59 | name='link_mailto', 60 | field=models.EmailField(max_length=75, null=True, verbose_name='email address', blank=True), 61 | preserve_default=True, 62 | ), 63 | migrations.AlterField( 64 | model_name='bootstrap3listgroupitemplugin', 65 | name='context', 66 | field=aldryn_bootstrap3.model_fields.Context(default='', max_length=255, blank=True, choices=[('', 'Default'), ('primary', 'Primary'), ('success', 'Success'), ('info', 'Info'), ('warning', 'Warning'), ('danger', 'Danger')]), 67 | preserve_default=True, 68 | ), 69 | ] 70 | -------------------------------------------------------------------------------- /aldryn_bootstrap3/migrations/0004_auto_20151211_1333.py: -------------------------------------------------------------------------------- 1 | # -*- coding: utf-8 -*- 2 | from __future__ import unicode_literals 3 | 4 | from django.db import migrations, models 5 | import filer.fields.image 6 | import django.db.models.deletion 7 | 8 | 9 | class Migration(migrations.Migration): 10 | 11 | dependencies = [ 12 | ('aldryn_bootstrap3', '0003_auto_20151113_1604'), 13 | ] 14 | 15 | operations = [ 16 | migrations.AlterField( 17 | model_name='boostrap3buttonplugin', 18 | name='link_mailto', 19 | field=models.EmailField(max_length=254, null=True, verbose_name='mailto', blank=True), 20 | ), 21 | migrations.AlterField( 22 | model_name='boostrap3imageplugin', 23 | name='file', 24 | field=filer.fields.image.FilerImageField(related_name='+', on_delete=django.db.models.deletion.SET_NULL, verbose_name='file', to='filer.Image', null=True), 25 | ), 26 | migrations.AlterField( 27 | model_name='boostrap3imageplugin', 28 | name='override_height', 29 | field=models.IntegerField(help_text='if this field is provided it will be used to scale image. If aspect ration is selected - height will be calculated based on that.', null=True, verbose_name='override height', blank=True), 30 | ), 31 | migrations.AlterField( 32 | model_name='boostrap3imageplugin', 33 | name='override_width', 34 | field=models.IntegerField(help_text='if this field is provided it will be used to scale image.', null=True, verbose_name='override width', blank=True), 35 | ), 36 | migrations.AlterField( 37 | model_name='bootstrap3carouselslideplugin', 38 | name='image', 39 | field=filer.fields.image.FilerImageField(related_name='+', on_delete=django.db.models.deletion.SET_NULL, verbose_name='image', to='filer.Image', null=True), 40 | ), 41 | migrations.AlterField( 42 | model_name='bootstrap3carouselslideplugin', 43 | name='link_mailto', 44 | field=models.EmailField(max_length=254, null=True, verbose_name='mailto', blank=True), 45 | ), 46 | ] 47 | -------------------------------------------------------------------------------- /aldryn_bootstrap3/migrations/0005_boostrap3imageplugin_use_original_image.py: -------------------------------------------------------------------------------- 1 | # -*- coding: utf-8 -*- 2 | from __future__ import unicode_literals 3 | 4 | from django.db import migrations, models 5 | 6 | 7 | class Migration(migrations.Migration): 8 | 9 | dependencies = [ 10 | ('aldryn_bootstrap3', '0004_auto_20151211_1333'), 11 | ] 12 | 13 | operations = [ 14 | migrations.AddField( 15 | model_name='boostrap3imageplugin', 16 | name='use_original_image', 17 | field=models.BooleanField(default=False, help_text='use the original full-resolution image (no resizing).', verbose_name='use original image'), 18 | ), 19 | ] 20 | -------------------------------------------------------------------------------- /aldryn_bootstrap3/migrations/0006_auto_20160615_1740.py: -------------------------------------------------------------------------------- 1 | # -*- coding: utf-8 -*- 2 | # Generated by Django 1.9.6 on 2016-06-15 21:40 3 | from __future__ import unicode_literals 4 | 5 | from django.db import migrations 6 | import djangocms_attributes_field.fields 7 | 8 | 9 | class Migration(migrations.Migration): 10 | 11 | dependencies = [ 12 | ('aldryn_bootstrap3', '0005_boostrap3imageplugin_use_original_image'), 13 | ] 14 | 15 | operations = [ 16 | migrations.AddField( 17 | model_name='boostrap3buttonplugin', 18 | name='link_attributes', 19 | field=djangocms_attributes_field.fields.AttributesField(default=dict, verbose_name='Link Attributes'), 20 | ), 21 | migrations.AddField( 22 | model_name='bootstrap3carouselslideplugin', 23 | name='link_attributes', 24 | field=djangocms_attributes_field.fields.AttributesField(default=dict, verbose_name='Link Attributes'), 25 | ), 26 | ] 27 | -------------------------------------------------------------------------------- /aldryn_bootstrap3/migrations/0007_auto_20160705_1155.py: -------------------------------------------------------------------------------- 1 | # -*- coding: utf-8 -*- 2 | # Generated by Django 1.9.7 on 2016-07-05 15:55 3 | from __future__ import unicode_literals 4 | 5 | from django.db import migrations 6 | import djangocms_attributes_field.fields 7 | 8 | 9 | class Migration(migrations.Migration): 10 | 11 | dependencies = [ 12 | ('aldryn_bootstrap3', '0006_auto_20160615_1740'), 13 | ] 14 | 15 | operations = [ 16 | migrations.AlterField( 17 | model_name='boostrap3buttonplugin', 18 | name='link_attributes', 19 | field=djangocms_attributes_field.fields.AttributesField(blank=True, default=dict, verbose_name='Link Attributes'), 20 | ), 21 | migrations.AlterField( 22 | model_name='bootstrap3carouselslideplugin', 23 | name='link_attributes', 24 | field=djangocms_attributes_field.fields.AttributesField(blank=True, default=dict, verbose_name='Link Attributes'), 25 | ), 26 | ] 27 | -------------------------------------------------------------------------------- /aldryn_bootstrap3/migrations/0008_auto_20160820_2332.py: -------------------------------------------------------------------------------- 1 | # -*- coding: utf-8 -*- 2 | from __future__ import unicode_literals 3 | 4 | from django.db import migrations, models 5 | 6 | 7 | class Migration(migrations.Migration): 8 | 9 | dependencies = [ 10 | ('aldryn_bootstrap3', '0007_auto_20160705_1155'), 11 | ] 12 | 13 | operations = [ 14 | migrations.AlterField( 15 | model_name='bootstrap3accordionitemplugin', 16 | name='cmsplugin_ptr', 17 | field=models.OneToOneField(parent_link=True, related_name='+', primary_key=True, serialize=False, to='cms.CMSPlugin', on_delete=models.CASCADE), 18 | ), 19 | migrations.AlterField( 20 | model_name='bootstrap3accordionplugin', 21 | name='cmsplugin_ptr', 22 | field=models.OneToOneField(parent_link=True, related_name='+', primary_key=True, serialize=False, to='cms.CMSPlugin', on_delete=models.CASCADE), 23 | ), 24 | migrations.AlterField( 25 | model_name='bootstrap3carouselplugin', 26 | name='cmsplugin_ptr', 27 | field=models.OneToOneField(parent_link=True, related_name='+', primary_key=True, serialize=False, to='cms.CMSPlugin', on_delete=models.CASCADE), 28 | ), 29 | migrations.AlterField( 30 | model_name='bootstrap3carouselslidefolderplugin', 31 | name='cmsplugin_ptr', 32 | field=models.OneToOneField(parent_link=True, related_name='+', primary_key=True, serialize=False, to='cms.CMSPlugin', on_delete=models.CASCADE), 33 | ), 34 | migrations.AlterField( 35 | model_name='bootstrap3carouselslideplugin', 36 | name='cmsplugin_ptr', 37 | field=models.OneToOneField(parent_link=True, related_name='+', primary_key=True, serialize=False, to='cms.CMSPlugin', on_delete=models.CASCADE), 38 | ), 39 | migrations.AlterField( 40 | model_name='bootstrap3columnplugin', 41 | name='cmsplugin_ptr', 42 | field=models.OneToOneField(parent_link=True, related_name='+', primary_key=True, serialize=False, to='cms.CMSPlugin', on_delete=models.CASCADE), 43 | ), 44 | migrations.AlterField( 45 | model_name='bootstrap3listgroupitemplugin', 46 | name='cmsplugin_ptr', 47 | field=models.OneToOneField(parent_link=True, related_name='+', primary_key=True, serialize=False, to='cms.CMSPlugin', on_delete=models.CASCADE), 48 | ), 49 | migrations.AlterField( 50 | model_name='bootstrap3listgroupplugin', 51 | name='cmsplugin_ptr', 52 | field=models.OneToOneField(parent_link=True, related_name='+', primary_key=True, serialize=False, to='cms.CMSPlugin', on_delete=models.CASCADE), 53 | ), 54 | migrations.AlterField( 55 | model_name='bootstrap3rowplugin', 56 | name='cmsplugin_ptr', 57 | field=models.OneToOneField(parent_link=True, related_name='+', primary_key=True, serialize=False, to='cms.CMSPlugin', on_delete=models.CASCADE), 58 | ), 59 | ] 60 | -------------------------------------------------------------------------------- /aldryn_bootstrap3/migrations/0010_bootstrap3codeplugin.py: -------------------------------------------------------------------------------- 1 | # -*- coding: utf-8 -*- 2 | from __future__ import unicode_literals 3 | 4 | from django.db import migrations, models 5 | import aldryn_bootstrap3.model_fields 6 | import djangocms_attributes_field.fields 7 | 8 | 9 | class Migration(migrations.Migration): 10 | 11 | dependencies = [ 12 | ('cms', '0016_auto_20160608_1535'), 13 | ('aldryn_bootstrap3', '0009_auto_20161219_1530'), 14 | ] 15 | 16 | operations = [ 17 | migrations.CreateModel( 18 | name='Bootstrap3CodePlugin', 19 | fields=[ 20 | ('code_type', models.CharField(default='code', max_length=255, verbose_name='Code type', choices=[('code', 'Inline'), ('kbd', 'User input'), ('pre', 'Basic block'), ('var', 'Variables'), ('samp', 'Sample output')])), 21 | ('code', models.TextField(verbose_name='Code', blank=True)), 22 | ('classes', aldryn_bootstrap3.model_fields.Classes(default='', help_text='Space separated classes that are added to the class. See Bootstrap 3 documentation.', verbose_name='Classes', blank=True)), 23 | ('attributes', djangocms_attributes_field.fields.AttributesField(default=dict, verbose_name='Attributes', blank=True)), 24 | ('cmsplugin_ptr', models.OneToOneField(parent_link=True, related_name='aldryn_bootstrap3_bootstrap3codeplugin', primary_key=True, serialize=False, to='cms.CMSPlugin', on_delete=models.CASCADE)), 25 | ], 26 | options={ 27 | 'abstract': False, 28 | }, 29 | bases=('cms.cmsplugin',), 30 | ), 31 | ] 32 | -------------------------------------------------------------------------------- /aldryn_bootstrap3/migrations/0011_bootstrap3responsiveplugin.py: -------------------------------------------------------------------------------- 1 | # -*- coding: utf-8 -*- 2 | from __future__ import unicode_literals 3 | 4 | from django.db import migrations, models 5 | import aldryn_bootstrap3.model_fields 6 | import djangocms_attributes_field.fields 7 | 8 | 9 | class Migration(migrations.Migration): 10 | 11 | dependencies = [ 12 | ('cms', '0016_auto_20160608_1535'), 13 | ('aldryn_bootstrap3', '0010_bootstrap3codeplugin'), 14 | ] 15 | 16 | operations = [ 17 | migrations.CreateModel( 18 | name='Bootstrap3ResponsivePlugin', 19 | fields=[ 20 | ('device_breakpoints', aldryn_bootstrap3.model_fields.Responsive(default='visible-xs visible-sm visible-md visible-lg', verbose_name='Devices', blank=True)), 21 | ('print_breakpoints', aldryn_bootstrap3.model_fields.ResponsivePrint(default='visible-print', verbose_name='Print', blank=True)), 22 | ('classes', aldryn_bootstrap3.model_fields.Classes(default='', help_text='Space separated classes that are added to the class. See Bootstrap 3 documentation.', verbose_name='Classes', blank=True)), 23 | ('attributes', djangocms_attributes_field.fields.AttributesField(default=dict, verbose_name='Attributes', blank=True)), 24 | ('cmsplugin_ptr', models.OneToOneField(parent_link=True, related_name='aldryn_bootstrap3_bootstrap3responsiveplugin', primary_key=True, serialize=False, to='cms.CMSPlugin', on_delete=models.CASCADE)), 25 | ], 26 | options={ 27 | 'abstract': False, 28 | }, 29 | bases=('cms.cmsplugin',), 30 | ), 31 | migrations.AlterField( 32 | model_name='bootstrap3carouselplugin', 33 | name='aspect_ratio', 34 | field=models.CharField(default='', max_length=255, verbose_name='Aspect ratio', blank=True), 35 | ), 36 | ] 37 | -------------------------------------------------------------------------------- /aldryn_bootstrap3/migrations/0012_bootstrap3tabplugin.py: -------------------------------------------------------------------------------- 1 | # -*- coding: utf-8 -*- 2 | from __future__ import unicode_literals 3 | 4 | from django.db import migrations, models 5 | import aldryn_bootstrap3.model_fields 6 | import djangocms_attributes_field.fields 7 | 8 | 9 | class Migration(migrations.Migration): 10 | 11 | dependencies = [ 12 | ('cms', '0016_auto_20160608_1535'), 13 | ('aldryn_bootstrap3', '0011_bootstrap3responsiveplugin'), 14 | ] 15 | 16 | operations = [ 17 | migrations.CreateModel( 18 | name='Bootstrap3TabItemPlugin', 19 | fields=[ 20 | ('title', models.CharField(max_length=255, verbose_name='Tab title')), 21 | ('icon', aldryn_bootstrap3.model_fields.Icon(default='', max_length=255, verbose_name='Title icon', blank=True)), 22 | ('classes', aldryn_bootstrap3.model_fields.Classes(default='', help_text='Space separated classes that are added to the class. See Bootstrap 3 documentation.', verbose_name='Classes', blank=True)), 23 | ('attributes', djangocms_attributes_field.fields.AttributesField(default=dict, verbose_name='Attributes', blank=True)), 24 | ('cmsplugin_ptr', models.OneToOneField(parent_link=True, related_name='aldryn_bootstrap3_bootstrap3tabitemplugin', primary_key=True, serialize=False, to='cms.CMSPlugin', on_delete=models.CASCADE)), 25 | ], 26 | options={ 27 | 'abstract': False, 28 | }, 29 | bases=('cms.cmsplugin',), 30 | ), 31 | migrations.CreateModel( 32 | name='Bootstrap3TabPlugin', 33 | fields=[ 34 | ('index', models.PositiveIntegerField(help_text='Index of element that should be opened on page load (leave it empty if none of the items should be opened)', null=True, verbose_name='Index', blank=True)), 35 | ('style', models.CharField(default='nav-tabs', max_length=255, verbose_name='Display type', choices=[('nav-tabs', 'Tabs'), ('nav-tabs nav-justified', 'Tabs justified'), ('nav-pills', 'Pills'), ('nav-pills nav-justified', 'Pills justified')])), 36 | ('effect', models.CharField(blank=True, max_length=255, verbose_name='Animation effect', choices=[('fade', 'Fade')])), 37 | ('classes', aldryn_bootstrap3.model_fields.Classes(default='', help_text='Space separated classes that are added to the class. See Bootstrap 3 documentation.', verbose_name='Classes', blank=True)), 38 | ('attributes', djangocms_attributes_field.fields.AttributesField(default=dict, verbose_name='Attributes', blank=True)), 39 | ('cmsplugin_ptr', models.OneToOneField(parent_link=True, related_name='aldryn_bootstrap3_bootstrap3tabplugin', primary_key=True, serialize=False, to='cms.CMSPlugin', on_delete=models.CASCADE)), 40 | ], 41 | options={ 42 | 'abstract': False, 43 | }, 44 | bases=('cms.cmsplugin',), 45 | ), 46 | ] 47 | -------------------------------------------------------------------------------- /aldryn_bootstrap3/migrations/0013_boostrap3jumbotronplugin.py: -------------------------------------------------------------------------------- 1 | # -*- coding: utf-8 -*- 2 | from __future__ import unicode_literals 3 | 4 | from django.db import migrations, models 5 | import aldryn_bootstrap3.model_fields 6 | import djangocms_attributes_field.fields 7 | 8 | 9 | class Migration(migrations.Migration): 10 | 11 | dependencies = [ 12 | ('cms', '0016_auto_20160608_1535'), 13 | ('aldryn_bootstrap3', '0012_bootstrap3tabplugin'), 14 | ] 15 | 16 | operations = [ 17 | migrations.CreateModel( 18 | name='Boostrap3JumbotronPlugin', 19 | fields=[ 20 | ('label', models.CharField(max_length=255, verbose_name='Label', blank=True)), 21 | ('grid', models.BooleanField(default=False, help_text='Adds a "container" element inside of the "Jumbotron"for use outside of a grid.', verbose_name='Add container')), 22 | ('classes', aldryn_bootstrap3.model_fields.Classes(default='', help_text='Space separated classes that are added to the class. See Bootstrap 3 documentation.', verbose_name='Classes', blank=True)), 23 | ('attributes', djangocms_attributes_field.fields.AttributesField(default=dict, verbose_name='Attributes', blank=True)), 24 | ('cmsplugin_ptr', models.OneToOneField(parent_link=True, related_name='aldryn_bootstrap3_boostrap3jumbotronplugin', primary_key=True, serialize=False, to='cms.CMSPlugin', on_delete=models.CASCADE)), 25 | ], 26 | options={ 27 | 'abstract': False, 28 | }, 29 | bases=('cms.cmsplugin',), 30 | ), 31 | ] 32 | -------------------------------------------------------------------------------- /aldryn_bootstrap3/migrations/0014_translations_update.py: -------------------------------------------------------------------------------- 1 | # -*- coding: utf-8 -*- 2 | from __future__ import unicode_literals 3 | 4 | from django.db import migrations, models 5 | import djangocms_text_ckeditor.fields 6 | import filer.fields.file 7 | import django.db.models.deletion 8 | from aldryn_bootstrap3.models import Bootstrap3CarouselPlugin 9 | from aldryn_bootstrap3.model_fields import get_additional_styles 10 | 11 | 12 | class Migration(migrations.Migration): 13 | 14 | dependencies = [ 15 | ('aldryn_bootstrap3', '0013_boostrap3jumbotronplugin'), 16 | ] 17 | 18 | operations = [ 19 | migrations.AlterField( 20 | model_name='boostrap3blockquoteplugin', 21 | name='reverse', 22 | field=models.BooleanField(default=False, help_text='Reverses the position by adding the Bootstrap 3 "blockquote-reverse" class.', verbose_name='Reverse quote'), 23 | ), 24 | migrations.AlterField( 25 | model_name='boostrap3imageplugin', 26 | name='aspect_ratio', 27 | field=models.CharField(default='', choices=[('1x1', '1x1'), ('4x3', '4x3'), ('16x9', '16x9'), ('16x10', '16x10'), ('21x9', '21x9'), ('3x4', '3x4'), ('9x16', '9x16'), ('10x16', '10x16'), ('9x21', '9x21')], max_length=255, blank=True, help_text='Determines width and height of the image according to the selected ratio.', verbose_name='Aspect ratio'), 28 | ), 29 | migrations.AlterField( 30 | model_name='bootstrap3accordionplugin', 31 | name='index', 32 | field=models.PositiveIntegerField(help_text='Index of element to open on page load (optional).', null=True, verbose_name='Index', blank=True), 33 | ), 34 | migrations.AlterField( 35 | model_name='bootstrap3carouselplugin', 36 | name='interval', 37 | field=models.IntegerField(default=5000, help_text='Time (in milliseconds) between items.', verbose_name='Interval'), 38 | ), 39 | migrations.AlterField( 40 | model_name='bootstrap3carouselplugin', 41 | name='pause', 42 | field=models.BooleanField(default=True, help_text='Pauses the carousel on hover.', verbose_name='Pause'), 43 | ), 44 | migrations.AlterField( 45 | model_name='bootstrap3carouselplugin', 46 | name='ride', 47 | field=models.BooleanField(default=True, help_text='Auto-starts animation of the carousel.', verbose_name='Ride'), 48 | ), 49 | migrations.AlterField( 50 | model_name='bootstrap3carouselplugin', 51 | name='wrap', 52 | field=models.BooleanField(default=True, help_text='Loops carousel animation.', verbose_name='Wrap'), 53 | ), 54 | migrations.AlterField( 55 | model_name='bootstrap3carouselslideplugin', 56 | name='link_file', 57 | field=filer.fields.file.FilerFileField(on_delete=django.db.models.deletion.SET_NULL, verbose_name='File', blank=True, to='filer.File', null=True), 58 | ), 59 | migrations.AlterField( 60 | model_name='bootstrap3listgroupplugin', 61 | name='add_list_group_class', 62 | field=models.BooleanField(default=True, help_text='Adds the list-group and subsequent list-group-item classes.', verbose_name='.list-group'), 63 | ), 64 | migrations.AlterField( 65 | model_name='bootstrap3tabplugin', 66 | name='index', 67 | field=models.PositiveIntegerField(help_text='Index of element to open on page load (optional).', null=True, verbose_name='Index', blank=True), 68 | ), 69 | migrations.AlterField( 70 | model_name='boostrap3buttonplugin', 71 | name='link_file', 72 | field=filer.fields.file.FilerFileField(on_delete=django.db.models.deletion.SET_NULL, verbose_name='File', blank=True, to='filer.File', null=True), 73 | ), 74 | migrations.AlterField( 75 | model_name='boostrap3jumbotronplugin', 76 | name='grid', 77 | field=models.BooleanField(default=False, help_text='Adds a ".container" element inside the "Jumbotron" for use outside of a grid.', verbose_name='Add container'), 78 | ), 79 | migrations.AlterField( 80 | model_name='bootstrap3carouselslideplugin', 81 | name='content', 82 | field=djangocms_text_ckeditor.fields.HTMLField(default='', help_text='Content may also be added using child plugins.', verbose_name='Content', blank=True), 83 | ), 84 | migrations.AlterField( 85 | model_name='bootstrap3carouselplugin', 86 | name='style', 87 | field=models.CharField(choices=Bootstrap3CarouselPlugin.STYLE_CHOICES + get_additional_styles(), default='standard', max_length=255, verbose_name='Style'), 88 | ), 89 | migrations.AlterField( 90 | model_name='boostrap3imageplugin', 91 | name='img_responsive', 92 | field=models.BooleanField(default=True, help_text='Adds the Bootstrap 3 ".img-responsive" class.', verbose_name='.img-responsive'), 93 | ), 94 | migrations.AlterField( 95 | model_name='bootstrap3carouselplugin', 96 | name='aspect_ratio', 97 | field=models.CharField(default='', choices=[('1x1', '1x1'), ('4x3', '4x3'), ('16x9', '16x9'), ('16x10', '16x10'), ('21x9', '21x9'), ('3x4', '3x4'), ('9x16', '9x16'), ('10x16', '10x16'), ('9x21', '9x21')], max_length=255, blank=True, help_text='Determines width and height of the image according to the selected ratio.', verbose_name='Aspect ratio'), 98 | ), 99 | ] 100 | -------------------------------------------------------------------------------- /aldryn_bootstrap3/migrations/__init__.py: -------------------------------------------------------------------------------- 1 | # -*- coding: utf-8 -*- 2 | -------------------------------------------------------------------------------- /aldryn_bootstrap3/model_fields.py: -------------------------------------------------------------------------------- 1 | # -*- coding: utf-8 -*- 2 | from __future__ import unicode_literals, absolute_import 3 | 4 | from functools import partial 5 | 6 | import django.db.models 7 | import django.forms 8 | 9 | from django.contrib.sites.models import Site 10 | from django.core.exceptions import ValidationError 11 | from django.db import models 12 | from django.utils.translation import ugettext, ugettext_lazy as _, ungettext 13 | 14 | from django.utils.encoding import force_text 15 | 16 | import cms.models 17 | import cms.models.fields 18 | from cms.models.pluginmodel import CMSPlugin 19 | 20 | import filer.fields.file 21 | import filer.fields.image 22 | 23 | from djangocms_attributes_field.fields import AttributesField 24 | 25 | from .conf import settings 26 | from . import fields, constants 27 | 28 | 29 | def get_additional_styles(): 30 | """ 31 | Get additional styles choices from settings 32 | """ 33 | choices = [] 34 | raw = getattr( 35 | settings, 36 | 'ALDRYN_BOOTSTRAP3_CAROUSEL_STYLES', 37 | getattr(settings, 'GALLERY_STYLES', False) 38 | ) 39 | if raw: 40 | if isinstance(raw, str): 41 | raw = raw.split(',') 42 | for choice in raw: 43 | clean = choice.strip() 44 | choices.append((clean.lower(), clean.title())) 45 | else: 46 | for choice in raw: 47 | choices.append(choice) 48 | return choices 49 | 50 | 51 | # Add an app namespace to related_name to avoid field name clashes 52 | # with any other plugins that have a field with the same name as the 53 | # lowercase of the class name of this model. 54 | # https://github.com/divio/django-cms/issues/5030 55 | CMSPluginField = partial( 56 | models.OneToOneField, 57 | to=CMSPlugin, 58 | related_name='%(app_label)s_%(class)s', 59 | parent_link=True, 60 | on_delete=models.CASCADE, 61 | ) 62 | 63 | 64 | # Helper for: 65 | # Classes, LinkOrButton, Size, IntegerField 66 | class SouthMixinBase(object): 67 | south_field_class = '' 68 | 69 | def south_field_triple(self): 70 | """Returns a suitable description of this field for South.""" 71 | if not self.south_field_class: 72 | raise NotImplementedError('Please set south_field_class when ' 73 | 'using the south field mixin.') 74 | # We'll just introspect ourselves, since we inherit. 75 | from south.modelsinspector import introspector 76 | field_class = self.south_field_class 77 | args, kwargs = introspector(self) 78 | # That's our definition! 79 | return field_class, args, kwargs 80 | 81 | 82 | # Code here is mostly used in `models.py` and `migrations/` 83 | 84 | 85 | class Classes(django.db.models.TextField, SouthMixinBase): 86 | default_field_class = fields.Classes 87 | south_field_class = 'django.db.models.fields.TextField' 88 | 89 | def __init__(self, *args, **kwargs): 90 | if 'verbose_name' not in kwargs: 91 | kwargs['verbose_name'] = _('Classes') 92 | if 'blank' not in kwargs: 93 | kwargs['blank'] = True 94 | if 'default' not in kwargs: 95 | kwargs['default'] = '' 96 | if 'help_text' not in kwargs: 97 | kwargs['help_text'] = _('Space separated classes that are added to ' 98 | 'the class. See Bootstrap 3 documentation.') 100 | super(Classes, self).__init__(*args, **kwargs) 101 | 102 | def formfield(self, **kwargs): 103 | defaults = { 104 | 'form_class': self.default_field_class, 105 | } 106 | defaults.update(kwargs) 107 | return super(Classes, self).formfield(**defaults) 108 | 109 | 110 | class LinkMixin(models.Model): 111 | link_url = models.URLField( 112 | verbose_name=_('External link'), 113 | blank=True, 114 | default='', 115 | help_text=_('Provide a valid URL to an external website.'), 116 | ) 117 | link_page = cms.models.fields.PageField( 118 | verbose_name=_('Internal link'), 119 | blank=True, 120 | null=True, 121 | on_delete=models.SET_NULL, 122 | help_text=_('If provided, overrides the external link.'), 123 | ) 124 | link_mailto = models.EmailField( 125 | verbose_name=_('Email address'), 126 | blank=True, 127 | null=True, 128 | max_length=255, 129 | ) 130 | link_phone = models.CharField( 131 | verbose_name=_('Phone'), 132 | blank=True, 133 | null=True, 134 | max_length=255, 135 | ) 136 | link_anchor = models.CharField( 137 | verbose_name=_('Anchor'), 138 | max_length=255, 139 | blank=True, 140 | help_text=_('Appends the value only after the internal or external link. ' 141 | 'Do not include a preceding "#" symbol.'), 142 | ) 143 | link_target = models.CharField( 144 | verbose_name=_('Target'), 145 | choices=constants.TARGET_CHOICES, 146 | blank=True, 147 | max_length=255, 148 | ) 149 | link_file = filer.fields.file.FilerFileField( 150 | verbose_name=_('File'), 151 | null=True, 152 | blank=True, 153 | on_delete=models.SET_NULL, 154 | ) 155 | link_attributes = AttributesField( 156 | verbose_name=_('Attributes'), 157 | blank=True, 158 | excluded_keys=['class', 'href', 'target'], 159 | ) 160 | 161 | class Meta: 162 | abstract = True 163 | 164 | def get_link_url(self): 165 | if self.link_page: 166 | ref_page = self.link_page 167 | link = ref_page.get_absolute_url() 168 | 169 | if ref_page.site_id != getattr(self.page, 'site_id', None): 170 | ref_site = Site.objects._get_site_by_id(ref_page.site_id) 171 | link = '//{}{}'.format(ref_site.domain, link) 172 | elif self.link_url: 173 | link = self.link_url 174 | elif self.link_phone: 175 | link = 'tel:{}'.format(self.link_phone.replace(' ', '')) 176 | elif self.link_mailto: 177 | link = 'mailto:{}'.format(self.link_mailto) 178 | elif self.link_file: 179 | link = self.link_file.url 180 | else: 181 | link = '' 182 | if self.link_anchor: 183 | link += '#{}'.format(self.link_anchor) 184 | return link 185 | 186 | def clean(self): 187 | super(LinkMixin, self).clean() 188 | field_names = ( 189 | 'link_url', 190 | 'link_page', 191 | 'link_mailto', 192 | 'link_phone', 193 | 'link_file', 194 | ) 195 | anchor_field_name = 'link_anchor' 196 | field_names_allowed_with_anchor = ( 197 | 'link_url', 198 | 'link_page', 199 | 'link_file', 200 | ) 201 | 202 | anchor_field_verbose_name = force_text( 203 | self._meta.get_field(anchor_field_name).verbose_name) 204 | anchor_field_value = getattr(self, anchor_field_name) 205 | 206 | link_fields = { 207 | key: getattr(self, key) 208 | for key in field_names 209 | } 210 | link_field_verbose_names = { 211 | key: force_text(self._meta.get_field(key).verbose_name) 212 | for key in link_fields.keys() 213 | } 214 | provided_link_fields = { 215 | key: value 216 | for key, value in link_fields.items() 217 | if value 218 | } 219 | 220 | required_link_classes = ( 221 | 'Boostrap3ButtonPlugin', 222 | ) 223 | 224 | if len(provided_link_fields) > 1: 225 | # Too many fields have a value. 226 | verbose_names = sorted(link_field_verbose_names.values()) 227 | error_msg = _('Only one of {0} or {1} may be given.').format( 228 | ', '.join(verbose_names[:-1]), 229 | verbose_names[-1], 230 | ) 231 | errors = {}.fromkeys(provided_link_fields.keys(), error_msg) 232 | raise ValidationError(errors) 233 | 234 | if self.__class__.__name__ in required_link_classes: 235 | if len(provided_link_fields) == 0 and not self.link_anchor: 236 | raise ValidationError( 237 | _('Please provide a link.') 238 | ) 239 | 240 | if anchor_field_value: 241 | for field_name in provided_link_fields.keys(): 242 | if field_name not in field_names_allowed_with_anchor: 243 | error_msg = _('%(anchor_field_verbose_name)s is not allowed together with %(field_name)s.') % { 244 | 'anchor_field_verbose_name': anchor_field_verbose_name, 245 | 'field_name': link_field_verbose_names.get(field_name) 246 | } 247 | raise ValidationError({ 248 | anchor_field_name: error_msg, 249 | field_name: error_msg, 250 | }) 251 | 252 | 253 | class LinkOrButton(django.db.models.fields.CharField, SouthMixinBase): 254 | default_field_class = fields.LinkOrButton 255 | south_field_class = 'django.db.models.fields.CharField' 256 | 257 | def __init__(self, *args, **kwargs): 258 | if 'verbose_name' not in kwargs: 259 | kwargs['verbose_name'] = ugettext('Type') 260 | if 'max_length' not in kwargs: 261 | kwargs['max_length'] = 255 262 | if 'blank' not in kwargs: 263 | kwargs['blank'] = False 264 | if 'default' not in kwargs: 265 | kwargs['default'] = self.default_field_class.DEFAULT 266 | super(LinkOrButton, self).__init__(*args, **kwargs) 267 | 268 | def formfield(self, **kwargs): 269 | defaults = { 270 | 'form_class': self.default_field_class, 271 | 'choices_form_class': self.default_field_class, 272 | } 273 | defaults.update(kwargs) 274 | return super(LinkOrButton, self).formfield(**defaults) 275 | 276 | def get_choices(self, **kwargs): 277 | # if there already is a "blank" choice, don't add another 278 | # default blank choice 279 | if '' in dict(self.choices).keys(): 280 | kwargs['include_blank'] = False 281 | return super(LinkOrButton, self).get_choices(**kwargs) 282 | 283 | 284 | class Context(django.db.models.fields.CharField): 285 | default_field_class = fields.Context 286 | south_field_class = 'django.db.models.fields.CharField' 287 | 288 | def __init__(self, *args, **kwargs): 289 | if 'verbose_name' not in kwargs: 290 | kwargs['verbose_name'] = ugettext('Context') 291 | if 'max_length' not in kwargs: 292 | kwargs['max_length'] = 255 293 | if 'blank' not in kwargs: 294 | kwargs['blank'] = False 295 | if 'default' not in kwargs: 296 | kwargs['default'] = self.default_field_class.DEFAULT 297 | super(Context, self).__init__(*args, **kwargs) 298 | 299 | def formfield(self, **kwargs): 300 | defaults = { 301 | 'form_class': self.default_field_class, 302 | 'choices_form_class': self.default_field_class, 303 | } 304 | defaults.update(kwargs) 305 | return super(Context, self).formfield(**defaults) 306 | 307 | def get_choices(self, **kwargs): 308 | # if there already is a "blank" choice, don't add another 309 | # default blank choice 310 | if '' in dict(self.choices).keys(): 311 | kwargs['include_blank'] = False 312 | return super(Context, self).get_choices(**kwargs) 313 | 314 | 315 | class Icon(django.db.models.CharField): 316 | default_field_class = fields.Icon 317 | south_field_class = 'django.db.models.fields.CharField' 318 | 319 | def __init__(self, *args, **kwargs): 320 | if 'verbose_name' not in kwargs: 321 | kwargs['verbose_name'] = ugettext('Icon') 322 | if 'max_length' not in kwargs: 323 | kwargs['max_length'] = 255 324 | if 'blank' not in kwargs: 325 | kwargs['blank'] = True 326 | if 'default' not in kwargs: 327 | kwargs['default'] = self.default_field_class.DEFAULT 328 | super(Icon, self).__init__(*args, **kwargs) 329 | 330 | def formfield(self, **kwargs): 331 | defaults = { 332 | 'form_class': self.default_field_class, 333 | } 334 | defaults.update(kwargs) 335 | return super(Icon, self).formfield(**defaults) 336 | 337 | 338 | class MiniText(django.db.models.TextField): 339 | default_field_class = fields.MiniText 340 | south_field_class = 'django.db.models.fields.TextField' 341 | 342 | def __init__(self, *args, **kwargs): 343 | if 'blank' not in kwargs: 344 | kwargs['blank'] = True 345 | if 'default' not in kwargs: 346 | kwargs['default'] = '' 347 | super(MiniText, self).__init__(*args, **kwargs) 348 | 349 | def formfield(self, **kwargs): 350 | defaults = { 351 | 'form_class': self.default_field_class, 352 | } 353 | defaults.update(kwargs) 354 | return super(MiniText, self).formfield(**defaults) 355 | 356 | 357 | class Responsive(MiniText): 358 | default_field_class = fields.Responsive 359 | 360 | def __init__(self, *args, **kwargs): 361 | if 'verbose_name' not in kwargs: 362 | kwargs['verbose_name'] = ugettext('Responsive') 363 | if 'blank' not in kwargs: 364 | kwargs['blank'] = True 365 | if 'default' not in kwargs: 366 | kwargs['default'] = '' 367 | super(Responsive, self).__init__(*args, **kwargs) 368 | 369 | def formfield(self, **kwargs): 370 | defaults = { 371 | 'form_class': self.default_field_class, 372 | } 373 | defaults.update(kwargs) 374 | return super(Responsive, self).formfield(**defaults) 375 | 376 | 377 | class Size(django.db.models.CharField, SouthMixinBase): 378 | default_field_class = fields.Size 379 | south_field_class = 'django.db.models.fields.CharField' 380 | 381 | def __init__(self, *args, **kwargs): 382 | if 'verbose_name' not in kwargs: 383 | kwargs['verbose_name'] = ugettext('Context') 384 | if 'max_length' not in kwargs: 385 | kwargs['max_length'] = 255 386 | if 'blank' not in kwargs: 387 | kwargs['blank'] = True 388 | if 'default' not in kwargs: 389 | kwargs['default'] = self.default_field_class.DEFAULT 390 | super(Size, self).__init__(*args, **kwargs) 391 | 392 | def formfield(self, **kwargs): 393 | defaults = { 394 | 'form_class': self.default_field_class, 395 | 'choices_form_class': self.default_field_class, 396 | } 397 | defaults.update(kwargs) 398 | return super(Size, self).formfield(**defaults) 399 | 400 | def get_choices(self, **kwargs): 401 | # if there already is a "blank" choice, don't add another 402 | # default blank choice 403 | if '' in dict(self.choices).keys(): 404 | kwargs['include_blank'] = False 405 | return super(Size, self).get_choices(**kwargs) 406 | 407 | 408 | class IntegerField(django.db.models.IntegerField, SouthMixinBase): 409 | default_field_class = fields.Integer 410 | south_field_class = 'django.db.models.fields.IntegerField' 411 | 412 | def __init__(self, verbose_name=None, name=None, min_value=None, max_value=None, **kwargs): 413 | self.min_value, self.max_value = min_value, max_value 414 | django.db.models.IntegerField.__init__(self, verbose_name, name, **kwargs) 415 | 416 | def formfield(self, **kwargs): 417 | defaults = { 418 | 'form_class': self.default_field_class, 419 | 'min_value': self.min_value, 420 | 'max_value': self.max_value, 421 | } 422 | defaults.update(kwargs) 423 | return super(IntegerField, self).formfield(**defaults) 424 | 425 | 426 | class ResponsivePrint(MiniText): 427 | default_field_class = fields.ResponsivePrint 428 | 429 | def __init__(self, *args, **kwargs): 430 | if 'blank' not in kwargs: 431 | kwargs['blank'] = True 432 | if 'default' not in kwargs: 433 | kwargs['default'] = '' 434 | super(ResponsivePrint, self).__init__(*args, **kwargs) 435 | 436 | def formfield(self, **kwargs): 437 | defaults = { 438 | 'form_class': self.default_field_class, 439 | } 440 | defaults.update(kwargs) 441 | return super(ResponsivePrint, self).formfield(**defaults) 442 | 443 | 444 | #TODO: 445 | # * btn-block, disabled 446 | # * pull-left, pull-right 447 | # * margins/padding 448 | -------------------------------------------------------------------------------- /aldryn_bootstrap3/static/aldryn_bootstrap3/css/base.css: -------------------------------------------------------------------------------- 1 | @charset "utf-8"; 2 | /*! 3 | * @copyright: https://github.com/divio/django-cms 4 | */ 5 | 6 | /*############################################################################## 7 | // CONTEXT WIDGET */ 8 | /* used in aldryn_bootstrap3/widgets/context.html */ 9 | .aldryn-bootstrap3-context { 10 | margin-left: 3px; 11 | } 12 | .aldryn-bootstrap3-context label { 13 | position: relative !important; 14 | z-index: 1 !important; 15 | } 16 | .aldryn-bootstrap3-context label.active { 17 | z-index: 10 !important; 18 | outline: 3px solid #000; 19 | border-radius: 0; 20 | } 21 | .aldryn-bootstrap3-context label.btn-link { 22 | border-color: #ccc; 23 | } 24 | 25 | /*############################################################################## 26 | // ICON WIDGET */ 27 | /* used in aldryn_bootstrap3/widgets/icon.html */ 28 | .aldryn-bootstrap3-icon select.form-control { 29 | width: auto !important; 30 | } 31 | .aldryn-bootstrap3-icon .icon-widgets label { 32 | display: inline !important; 33 | } 34 | .aldryn-bootstrap3-icon select { 35 | margin: 0; 36 | } 37 | .aldryn-bootstrap3-icon button.iconpicker { 38 | padding-right: 10px !important; 39 | padding-left: 10px !important; 40 | } 41 | 42 | .iconpicker-popover .search-control { 43 | width: 100% !important; 44 | } 45 | .iconpicker-popover table tfoot tr td { 46 | padding-top: 10px; 47 | border-top: 0; 48 | background: none; 49 | } 50 | .iconpicker-popover .page-count { 51 | display: inline-block; 52 | padding-top: 8px; 53 | } 54 | /* the first entry uses ".glyphicon-" to deselect any icons */ 55 | .iconpicker-popover .glyphicon-, 56 | .iconpicker-popover .fa- { 57 | width: 14px; 58 | } 59 | 60 | /*############################################################################## 61 | // BUTTON WIDGET */ 62 | /* used in aldryn_bootstrap3/widgets/link_or_button.html */ 63 | .aldryn-bootstrap3-button .preview-btn { 64 | margin: 0; 65 | } 66 | .field-btn_block .checkbox-row { 67 | padding-top: 0 !important; 68 | border: none !important; 69 | } 70 | .field-txt_context .btn-muted { 71 | color: #ccc !important; 72 | border: 1px solid #ccc !important; 73 | } 74 | .field-btn_context .btn-link { 75 | border-radius: 0 3px 3px 0; 76 | } 77 | 78 | /*############################################################################## 79 | // SIZES WIDGET */ 80 | /* used in aldryn_bootstrap3/widgets/size.html */ 81 | .btn-group-sizes label { 82 | line-height: 20px; 83 | } 84 | .btn-group-sizes .text-lg { 85 | font-size: 18px; 86 | } 87 | .btn-group-sizes .text-md { 88 | font-size: 14px; 89 | } 90 | .btn-group-sizes .text-sm { 91 | font-size: 12px; 92 | } 93 | .btn-group-sizes .text-sm .glyphicon { 94 | top: 2px; 95 | } 96 | .btn-group-sizes .text-xs { 97 | font-size: 10px; 98 | } 99 | .btn-group-sizes .text-xs .glyphicon { 100 | top: 3px; 101 | } 102 | 103 | /*############################################################################## 104 | // RESPONSIVE WIDGET */ 105 | /* used in aldryn_bootstrap3/widgets/responsive.html */ 106 | /* used in aldryn_bootstrap3/widgets/responsive_print.html */ 107 | .aldryn-bootstrap3-responsive .fa { 108 | margin: 4px 0; 109 | } 110 | .aldryn-bootstrap3-responsive .btn-group label { 111 | min-width: 90px; 112 | } 113 | .aldryn-bootstrap3-responsive .btn-group .dropdown-menu { 114 | right: 0; 115 | left: auto; 116 | padding: 0; 117 | margin: 5px 0; 118 | border: none; 119 | } 120 | .aldryn-bootstrap3-responsive .btn-group .dropdown-menu li { 121 | padding: 5px 0; 122 | } 123 | .aldryn-bootstrap3-responsive .btn-group .dropdown-menu li:first-child { 124 | border-top: none; 125 | } 126 | 127 | /*############################################################################## 128 | // GRID PLUGIN */ 129 | /* used in aldryn_bootstrap3/plugins/column/change_form.html */ 130 | /* used in aldryn_bootstrap3/plugins/row/change_form.html */ 131 | .aldryn-bootstrap3-grid input[type="number"] { 132 | margin-right: 10px; 133 | } 134 | .aldryn-bootstrap3-grid .module { 135 | margin-bottom: 20px; 136 | } 137 | .aldryn-bootstrap3-grid .form-row { 138 | overflow: hidden; 139 | padding: 14px 0 10px; 140 | } 141 | .aldryn-bootstrap3-grid fieldset:first-child .form-row { 142 | border-bottom: 1px solid #ddd !important; 143 | } 144 | .aldryn-bootstrap3-grid .help { 145 | display: none; 146 | } 147 | .aldryn-bootstrap3-grid .form-row-icon { 148 | float: left; 149 | font-size: 35px; 150 | line-height: 40px; 151 | margin-right: 10px; 152 | } 153 | 154 | .aldryn-bootstrap3-grid .field-create label { 155 | float: left; 156 | display: inline-block; 157 | width: 150px !important; 158 | } 159 | .aldryn-bootstrap3-grid .field-create input { 160 | width: 70px !important; 161 | } 162 | 163 | .aldryn-bootstrap3-grid .field-box label { 164 | float: left; 165 | display: inline-block; 166 | text-transform: lowercase; 167 | text-align: right; 168 | width: 70px !important; 169 | } 170 | .aldryn-bootstrap3-grid .field-box input { 171 | width: auto !important; 172 | } 173 | 174 | /*############################################################################## 175 | // LABEL PLUGIN */ 176 | /* used in aldryn_bootstrap3/plugins/label/change_form.html */ 177 | .aldryn-bootstrap3-label .label-preview { 178 | font-size: 18px !important; 179 | margin: 0; 180 | } 181 | 182 | /*############################################################################## 183 | // BLOCKQUOTE PLUGIN */ 184 | /* used in aldryn_bootstrap3/plugins/blockquote/change_form.html */ 185 | #boostrap3blockquoteplugin_form .checkbox-row { 186 | padding-top: 0 !important; 187 | border: none !important; 188 | } 189 | 190 | /*############################################################################## 191 | // IMAGE PLUGIN WITH DRAG AND DROP FEATURE */ 192 | .filer-dropzone-image-plugin { 193 | display: inline-block; 194 | } 195 | .filer-dropzone.dz-drag-hover { 196 | background: #E5F8FF; 197 | box-shadow: 0 0 0 2px #00BAFF; 198 | } 199 | .popup .filer-dropzone.dz-drag-hover { 200 | box-shadow: none; 201 | } 202 | .filer-dropzone.dz-drag-hover img { 203 | opacity: 0.3; 204 | } 205 | .filer-dropzone-info-message, 206 | .filer-dropzone-error-message { 207 | position: fixed; 208 | display: block; 209 | left: 50%; 210 | bottom: 0; 211 | overflow: hidden; 212 | z-index: 2; 213 | color: #000; 214 | font-size: 14px; 215 | font-weight: normal; 216 | line-height: 20px; 217 | text-align: center; 218 | width: 270px; 219 | margin: 0 0 50px -150px; 220 | padding: 15px; 221 | border-radius: 3px; 222 | background: #fff; 223 | box-shadow: 0 0 5px 0 rgba(0,0,0,0.2); 224 | } 225 | .filer-dropzone-info-message .filer-dropzone-icon, 226 | .filer-dropzone-error-message .filer-dropzone-icon { 227 | display: block; 228 | font-size: 35px; 229 | color: #0bf; 230 | } 231 | .filer-dropzone-info-message .filer-dropzone-text, 232 | .filer-dropzone-error-message .filer-dropzone-text { 233 | display: block; 234 | margin: 5px 0 10px 0; 235 | } 236 | .filer-dropzone-upload-info { 237 | display: block; 238 | margin-top: 10px; 239 | } 240 | .filer-dropzone-upload-info .filer-dropzone-file-name { 241 | display: block; 242 | overflow: hidden; 243 | text-overflow: ellipsis; 244 | white-space: nowrap; 245 | } 246 | .filer-dropzone-progress { 247 | display: block; 248 | height: 5px; 249 | margin-top: 5px; 250 | background-color: #0bf; 251 | } 252 | 253 | .table-icons .aldryn-bootstrap3-svg-icon:before { 254 | content: none; 255 | } 256 | .aldryn-bootstrap3-svg-icon { 257 | font-size: 20px; 258 | } 259 | .aldryn-bootstrap3-svg-icon svg { 260 | display: inline-block; 261 | width: 1em; 262 | height: 1em; 263 | vertical-align: top; 264 | } 265 | .table-icons .disabled { 266 | /* 267 | work around the bug in the icon picker when disabled buttons could 268 | be clicked which would result in icon page overflow errors 269 | */ 270 | pointer-events: none !important; 271 | } 272 | -------------------------------------------------------------------------------- /aldryn_bootstrap3/static/aldryn_bootstrap3/css/bootstrap-iconpicker.min.css: -------------------------------------------------------------------------------- 1 | /*! 2 | * Bootstrap-iconpicker v1.7.0 3 | * 4 | * Copyright 2013-2015 Victor Valencia Rico. 5 | * Licensed under the Apache License v2.0 6 | * http://www.apache.org/licenses/LICENSE-2.0 7 | * 8 | * Designed and built with all the love in the world by @recktoner. 9 | */.iconpicker .caret{margin-left:10px!important}.iconpicker{min-width:60px}.iconpicker input.search-control{margin-bottom:6px;margin-top:6px}div.iconpicker.left .table-icons{margin-right:auto}div.iconpicker.center .table-icons{margin-left:auto;margin-right:auto}div.iconpicker.right .table-icons{margin-left:auto}.table-icons .btn{min-height:30px;min-width:35px;text-align:center;padding:0;margin:2px}.table-icons td{min-width:39px}.popover{max-width:inherit!important}.iconpicker-popover{z-index:1050!important}.iconpicker-popover .search-control{margin-bottom:6px;margin-top:6px} -------------------------------------------------------------------------------- /aldryn_bootstrap3/static/aldryn_bootstrap3/fonts/fontawesome-webfont.eot: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/divio/aldryn-bootstrap3/bb80aaf6cbe9339718b4240e45907ac61bc0781a/aldryn_bootstrap3/static/aldryn_bootstrap3/fonts/fontawesome-webfont.eot -------------------------------------------------------------------------------- /aldryn_bootstrap3/static/aldryn_bootstrap3/fonts/fontawesome-webfont.ttf: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/divio/aldryn-bootstrap3/bb80aaf6cbe9339718b4240e45907ac61bc0781a/aldryn_bootstrap3/static/aldryn_bootstrap3/fonts/fontawesome-webfont.ttf -------------------------------------------------------------------------------- /aldryn_bootstrap3/static/aldryn_bootstrap3/fonts/fontawesome-webfont.woff: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/divio/aldryn-bootstrap3/bb80aaf6cbe9339718b4240e45907ac61bc0781a/aldryn_bootstrap3/static/aldryn_bootstrap3/fonts/fontawesome-webfont.woff -------------------------------------------------------------------------------- /aldryn_bootstrap3/static/aldryn_bootstrap3/fonts/fontawesome-webfont.woff2: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/divio/aldryn-bootstrap3/bb80aaf6cbe9339718b4240e45907ac61bc0781a/aldryn_bootstrap3/static/aldryn_bootstrap3/fonts/fontawesome-webfont.woff2 -------------------------------------------------------------------------------- /aldryn_bootstrap3/static/aldryn_bootstrap3/fonts/glyphicons-halflings-regular.eot: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/divio/aldryn-bootstrap3/bb80aaf6cbe9339718b4240e45907ac61bc0781a/aldryn_bootstrap3/static/aldryn_bootstrap3/fonts/glyphicons-halflings-regular.eot -------------------------------------------------------------------------------- /aldryn_bootstrap3/static/aldryn_bootstrap3/fonts/glyphicons-halflings-regular.ttf: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/divio/aldryn-bootstrap3/bb80aaf6cbe9339718b4240e45907ac61bc0781a/aldryn_bootstrap3/static/aldryn_bootstrap3/fonts/glyphicons-halflings-regular.ttf -------------------------------------------------------------------------------- /aldryn_bootstrap3/static/aldryn_bootstrap3/fonts/glyphicons-halflings-regular.woff: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/divio/aldryn-bootstrap3/bb80aaf6cbe9339718b4240e45907ac61bc0781a/aldryn_bootstrap3/static/aldryn_bootstrap3/fonts/glyphicons-halflings-regular.woff -------------------------------------------------------------------------------- /aldryn_bootstrap3/static/aldryn_bootstrap3/fonts/glyphicons-halflings-regular.woff2: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/divio/aldryn-bootstrap3/bb80aaf6cbe9339718b4240e45907ac61bc0781a/aldryn_bootstrap3/static/aldryn_bootstrap3/fonts/glyphicons-halflings-regular.woff2 -------------------------------------------------------------------------------- /aldryn_bootstrap3/static/aldryn_bootstrap3/img/type/button.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/divio/aldryn-bootstrap3/bb80aaf6cbe9339718b4240e45907ac61bc0781a/aldryn_bootstrap3/static/aldryn_bootstrap3/img/type/button.png -------------------------------------------------------------------------------- /aldryn_bootstrap3/static/aldryn_bootstrap3/img/type/file.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/divio/aldryn-bootstrap3/bb80aaf6cbe9339718b4240e45907ac61bc0781a/aldryn_bootstrap3/static/aldryn_bootstrap3/img/type/file.png -------------------------------------------------------------------------------- /aldryn_bootstrap3/static/aldryn_bootstrap3/img/type/icon.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/divio/aldryn-bootstrap3/bb80aaf6cbe9339718b4240e45907ac61bc0781a/aldryn_bootstrap3/static/aldryn_bootstrap3/img/type/icon.png -------------------------------------------------------------------------------- /aldryn_bootstrap3/static/aldryn_bootstrap3/img/type/label.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/divio/aldryn-bootstrap3/bb80aaf6cbe9339718b4240e45907ac61bc0781a/aldryn_bootstrap3/static/aldryn_bootstrap3/img/type/label.png -------------------------------------------------------------------------------- /aldryn_bootstrap3/static/aldryn_bootstrap3/img/type/spacer.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/divio/aldryn-bootstrap3/bb80aaf6cbe9339718b4240e45907ac61bc0781a/aldryn_bootstrap3/static/aldryn_bootstrap3/img/type/spacer.png -------------------------------------------------------------------------------- /aldryn_bootstrap3/static/aldryn_bootstrap3/js/bootstrap-iconpicker.min.js: -------------------------------------------------------------------------------- 1 | /*!======================================================================== 2 | * Bootstrap: bootstrap-iconpicker.js v1.7.0 by @recktoner 3 | * https://victor-valencia.github.com/bootstrap-iconpicker 4 | * ======================================================================== 5 | * Copyright 2013-2015 Victor Valencia Rico. 6 | * 7 | * Licensed under the Apache License, Version 2.0 (the "License"); 8 | * you may not use this file except in compliance with the License. 9 | * You may obtain a copy of the License at 10 | * 11 | * http://www.apache.org/licenses/LICENSE-2.0 12 | * 13 | * Unless required by applicable law or agreed to in writing, software 14 | * distributed under the License is distributed on an "AS IS" BASIS, 15 | * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. 16 | * See the License for the specific language governing permissions and 17 | * limitations under the License. 18 | * ======================================================================== */ 19 | !function($){"use strict";var Iconpicker=function(element,options){this.$element=$(element),this.options=$.extend({},Iconpicker.DEFAULTS,this.$element.data()),this.options=$.extend({},this.options,options)};Iconpicker.ICONSET_EMPTY={iconClass:"",iconClassFix:"",icons:[]},Iconpicker.ICONSET={_custom:null,elusiveicon:$.iconset_elusiveicon||Iconpicker.ICONSET_EMPTY,fontawesome:$.iconset_fontawesome||Iconpicker.ICONSET_EMPTY,ionicon:$.iconset_ionicon||Iconpicker.ICONSET_EMPTY,glyphicon:$.iconset_glyphicon||Iconpicker.ICONSET_EMPTY,mapicon:$.iconset_mapicon||Iconpicker.ICONSET_EMPTY,materialdesign:$.iconset_materialdesign||Iconpicker.ICONSET_EMPTY,octicon:$.iconset_octicon||Iconpicker.ICONSET_EMPTY,typicon:$.iconset_typicon||Iconpicker.ICONSET_EMPTY,weathericon:$.iconset_weathericon||Iconpicker.ICONSET_EMPTY},Iconpicker.DEFAULTS={align:"center",arrowClass:"btn-primary",arrowNextIconClass:"glyphicon glyphicon-arrow-right",arrowPrevIconClass:"glyphicon glyphicon-arrow-left",cols:4,icon:"",iconset:"glyphicon",header:!0,labelHeader:"{0} / {1}",footer:!0,labelFooter:"{0} - {1} of {2}",placement:"bottom",rows:4,search:!0,searchText:"Search icon",selectedClass:"btn-warning",unselectedClass:"btn-default"},Iconpicker.prototype.bindEvents=function(){var op=this.options,el=this;op.table.find(".btn-previous, .btn-next").off("click").on("click",function(e){e.preventDefault();var inc=parseInt($(this).val(),10);el.changeList(op.page+inc)}),op.table.find(".btn-icon").off("click").on("click",function(e){e.preventDefault(),el.select($(this).val()),op.inline===!1?el.$element.popover("destroy"):op.table.find("i."+$(this).val()).parent().addClass(op.selectedClass)}),op.table.find(".search-control").off("keyup").on("keyup",function(){el.changeList(1)})},Iconpicker.prototype.changeList=function(page){this.filterIcons(),this.updateLabels(page),this.updateIcons(page),this.options.page=page,this.bindEvents()},Iconpicker.prototype.filterIcons=function(){var op=this.options,search=op.table.find(".search-control").val();if(""===search)op.icons=Iconpicker.ICONSET[op.iconset].icons;else{var result=[];$.each(Iconpicker.ICONSET[op.iconset].icons,function(i,v){v.indexOf(search)>-1&&result.push(v)}),op.icons=result}},Iconpicker.prototype.removeAddClass=function(target,remove,add){return this.options.table.find(target).removeClass(remove).addClass(add),add},Iconpicker.prototype.reset=function(){this.updatePicker(),this.changeList(1)},Iconpicker.prototype.select=function(icon){var op=this.options,el=this.$element;op.selected=$.inArray(icon.replace(op.iconClassFix,""),op.icons),-1===op.selected&&(op.selected=0,icon=op.iconClassFix+op.icons[op.selected]),""!==icon&&op.selected>=0&&(op.icon=icon,op.inline===!1&&(el.find("input").val(icon),el.find("i").attr("class","").addClass(op.iconClass).addClass(icon)),icon===op.iconClassFix?el.trigger({type:"change",icon:"empty"}):el.trigger({type:"change",icon:icon}),op.table.find("button."+op.selectedClass).removeClass(op.selectedClass))},Iconpicker.prototype.switchPage=function(icon){var op=this.options;if(op.selected=$.inArray(icon.replace(op.iconClassFix,""),op.icons),op.selected>=0){var page=Math.ceil((op.selected+1)/this.totalIconsPerPage());this.changeList(page)}""===icon?op.table.find("i."+op.iconClassFix).parent().addClass(op.selectedClass):op.table.find("i."+icon).parent().addClass(op.selectedClass)},Iconpicker.prototype.totalPages=function(){return Math.ceil(this.totalIcons()/this.totalIconsPerPage())},Iconpicker.prototype.totalIcons=function(){return this.options.icons.length},Iconpicker.prototype.totalIconsPerPage=function(){return 0===this.options.rows?this.options.icons.length:this.options.cols*this.options.rows},Iconpicker.prototype.updateArrows=function(page){var op=this.options,total_pages=this.totalPages();1===page?op.table.find(".btn-previous").addClass("disabled"):op.table.find(".btn-previous").removeClass("disabled"),page===total_pages||0===total_pages?op.table.find(".btn-next").addClass("disabled"):op.table.find(".btn-next").removeClass("disabled")},Iconpicker.prototype.updateIcons=function(page){var op=this.options,tbody=op.table.find("tbody").empty(),offset=(page-1)*this.totalIconsPerPage(),length=op.rows;0===op.rows&&(length=op.icons.length);for(var i=0;length>i;i++){for(var tr=$(""),j=0;j').hide();if(pos').show(),op.icon===v&&btn.addClass(op.selectedClass).addClass("btn-icon-selected")}tr.append($("").append(btn))}tbody.append(tr)}},Iconpicker.prototype.updateIconsCount=function(){var op=this.options;if(op.footer===!0){var icons_count=["",' ',' '," ",""];op.table.find("tfoot").empty().append(icons_count.join(""))}},Iconpicker.prototype.updateLabels=function(page){var op=this.options,total_icons=this.totalIcons(),total_pages=this.totalPages();op.table.find(".page-count").html(op.labelHeader.replace("{0}",0===total_pages?0:page).replace("{1}",total_pages));var offset=(page-1)*this.totalIconsPerPage(),total=page*this.totalIconsPerPage();op.table.find(".icons-count").html(op.labelFooter.replace("{0}",offset+1).replace("{1}",total_icons>total?total:total_icons).replace("{2}",total_icons)),this.updateArrows(page)},Iconpicker.prototype.updatePagesCount=function(){var op=this.options;if(op.header===!0){for(var tr=$(""),i=0;i');if(0===i||i===op.cols-1){var arrow=['"];td.append(arrow.join("")),tr.append(td)}else 0===tr.find(".page-count").length&&(td.attr("colspan",op.cols-2).append(''),tr.append(td))}op.table.find("thead").empty().append(tr)}},Iconpicker.prototype.updatePicker=function(){var op=this.options;if(op.cols<4)throw"Iconpicker => The number of columns must be greater than or equal to 4. [option.cols = "+op.cols+"]";if(op.rows<0)throw"Iconpicker => The number of rows must be greater than or equal to 0. [option.rows = "+op.rows+"]";this.updatePagesCount(),this.updateSearch(),this.updateIconsCount()},Iconpicker.prototype.updateSearch=function(){var op=this.options,search=["",' ',' '," ",""];search=$(search.join("")),op.search===!0?search.show():search.hide(),op.table.find("thead").append(search)},Iconpicker.prototype.setAlign=function(value){this.$element.removeClass(this.options.align).addClass(value),this.options.align=value},Iconpicker.prototype.setArrowClass=function(value){this.options.arrowClass=this.removeAddClass(".btn-arrow",this.options.arrowClass,value)},Iconpicker.prototype.setArrowNextIconClass=function(value){this.options.arrowNextIconClass=this.removeAddClass(".btn-next > span",this.options.arrowNextIconClass,value)},Iconpicker.prototype.setArrowPrevIconClass=function(value){this.options.arrowPrevIconClass=this.removeAddClass(".btn-previous > span",this.options.arrowPrevIconClass,value)},Iconpicker.prototype.setCols=function(value){this.options.cols=value,this.reset()},Iconpicker.prototype.setFooter=function(value){var footer=this.options.table.find("tfoot");value===!0?footer.show():footer.hide(),this.options.footer=value},Iconpicker.prototype.setHeader=function(value){var header=this.options.table.find("thead");value===!0?header.show():header.hide(),this.options.header=value},Iconpicker.prototype.setIcon=function(value){this.select(value)},Iconpicker.prototype.setIconset=function(value){var op=this.options;$.isPlainObject(value)?(Iconpicker.ICONSET._custom=$.extend(Iconpicker.ICONSET_EMPTY,value),op.iconset="_custom"):Iconpicker.ICONSET.hasOwnProperty(value)?op.iconset=value:op.iconset=Iconpicker.DEFAULTS.iconset,op=$.extend(op,Iconpicker.ICONSET[op.iconset]),this.reset(),this.select(op.icon)},Iconpicker.prototype.setLabelHeader=function(value){this.options.labelHeader=value,this.updateLabels(this.options.page)},Iconpicker.prototype.setLabelFooter=function(value){this.options.labelFooter=value,this.updateLabels(this.options.page)},Iconpicker.prototype.setPlacement=function(value){this.options.placement=value},Iconpicker.prototype.setRows=function(value){this.options.rows=value,this.reset()},Iconpicker.prototype.setSearch=function(value){var search=this.options.table.find(".search-control");value===!0?search.show():search.hide(),search.val(""),this.changeList(1),this.options.search=value},Iconpicker.prototype.setSearchText=function(value){this.options.table.find(".search-control").attr("placeholder",value),this.options.searchText=value},Iconpicker.prototype.setSelectedClass=function(value){this.options.selectedClass=this.removeAddClass(".btn-icon-selected",this.options.selectedClass,value)},Iconpicker.prototype.setUnselectedClass=function(value){this.options.unselectedClass=this.removeAddClass(".btn-icon",this.options.unselectedClass,value)};var old=$.fn.iconpicker;$.fn.iconpicker=function(option,params){return this.each(function(){var $this=$(this),data=$this.data("bs.iconpicker"),options="object"==typeof option&&option;if(data||$this.data("bs.iconpicker",data=new Iconpicker(this,options)),"string"==typeof option){if("undefined"==typeof data[option])throw'Iconpicker => The "'+option+'" method does not exists.';data[option](params)}else{var op=data.options;op=$.extend(op,{inline:!1,page:1,selected:-1,table:$('
')});var name="undefined"!=typeof $this.attr("name")?'name="'+$this.attr("name")+'"':"";"BUTTON"===$this.prop("tagName")?($this.empty().append("").append('").append('').addClass("iconpicker"),data.setIconset(op.iconset),$this.on("click",function(e){e.preventDefault(),$this.popover({animation:!1,trigger:"manual",html:!0,content:op.table,container:"body",placement:op.placement}).on("shown.bs.popover",function(){data.switchPage(op.icon),data.bindEvents()}),$this.data("bs.popover").tip().addClass("iconpicker-popover"),$this.popover("show")})):(op.inline=!0,data.setIconset(op.iconset),$this.empty().append('").append(op.table).addClass("iconpicker").addClass(op.align),data.switchPage(op.icon),data.bindEvents())}})},$.fn.iconpicker.Constructor=Iconpicker,$.fn.iconpicker.noConflict=function(){return $.fn.iconpicker=old,this},$(document).on("click","body",function(e){$(".iconpicker").each(function(){$(this).is(e.target)||0!==$(this).has(e.target).length||0!==$(".popover").has(e.target).length||$(this).popover("destroy")})}),$('button[role="iconpicker"],div[role="iconpicker"]').iconpicker()}(jQuery); -------------------------------------------------------------------------------- /aldryn_bootstrap3/static/aldryn_bootstrap3/js/ckeditor.js: -------------------------------------------------------------------------------- 1 | /* 2 | * Copyright https://github.com/divio/django-cms 3 | */ 4 | 5 | // ############################################################################# 6 | // CKEDITOR 7 | /** 8 | * Default CKEDITOR Styles 9 | * Added within src/settings.py CKEDITOR_SETTINGS.stylesSet 10 | * http://getbootstrap.com/css/#type 11 | * 12 | * @module CKEDITOR 13 | */ 14 | /* global CKEDITOR */ 15 | 16 | CKEDITOR.allElements = ['p', 'h1', 'h2', 'h3', 'h4', 'h5', 'h6', 'div']; 17 | CKEDITOR.stylesSet.add('default', [ 18 | { name: 'Text lead', element: CKEDITOR.allElements, attributes: { class: 'lead' }}, 19 | 20 | { name: 'Text left', element: CKEDITOR.allElements, attributes: { class: 'text-left' }}, 21 | { name: 'Text center', element: CKEDITOR.allElements, attributes: { class: 'text-center' }}, 22 | { name: 'Text right', element: CKEDITOR.allElements, attributes: { class: 'text-right' }}, 23 | { name: 'Text kustify', element: CKEDITOR.allElements, attributes: { class: 'text-justify' }}, 24 | { name: 'Text no wrap', element: CKEDITOR.allElements, attributes: { class: 'text-nowrap' }}, 25 | 26 | { name: 'Abbr initialism', element: 'abbr', attributes: { class: 'initialism' }}, 27 | 28 | { name: 'List unstyled', element: ['ul', 'ol'], attributes: { class: 'list-unstyled' }}, 29 | { name: 'List inline', element: ['ul', 'ol'], attributes: { class: 'list-inline' }}, 30 | { name: 'Horizontal description', element: 'dl', attributes: { class: 'dl-horizontal' }}, 31 | 32 | { name: 'Table', element: 'table', attributes: { class: 'table' }}, 33 | { name: 'Table striped', element: 'table', attributes: { class: 'table-striped' }}, 34 | { name: 'Table bordered', element: 'table', attributes: { class: 'table-bordered' }}, 35 | { name: 'Table hover', element: 'table', attributes: { class: 'table-hover' }}, 36 | { name: 'Table condensed', element: 'table', attributes: { class: 'table-condensed' }}, 37 | { name: 'Table responsive', element: 'table', attributes: { class: 'table-responsive' }}, 38 | 39 | { name: 'Table cell active', element: ['tr', 'th', 'td'], attributes: { class: 'active' }}, 40 | { name: 'Table cell success', element: ['tr', 'th', 'td'], attributes: { class: 'success' }}, 41 | { name: 'Table cell info', element: ['tr', 'th', 'td'], attributes: { class: 'info' }}, 42 | { name: 'Table cell warning', element: ['tr', 'th', 'td'], attributes: { class: 'warning' }}, 43 | { name: 'Table cell danger', element: ['tr', 'th', 'td'], attributes: { class: 'danger' }}, 44 | 45 | { name: 'Text primary', element: 'span', attributes: { class: 'text-primary' }}, 46 | { name: 'Text success', element: 'span', attributes: { class: 'text-success' }}, 47 | { name: 'Text info', element: 'span', attributes: { class: 'text-info' }}, 48 | { name: 'Text warning', element: 'span', attributes: { class: 'text-warning' }}, 49 | { name: 'Text danger', element: 'span', attributes: { class: 'text-danger' }}, 50 | { name: 'Text muted', element: 'span', attributes: { class: 'text-muted' }}, 51 | 52 | { name: 'Image responsive', element: 'img', attributes: { class: 'img-responsive' }}, 53 | { name: 'Image rounded', element: 'img', attributes: { class: 'img-rounded' }}, 54 | { name: 'Image circle', element: 'img', attributes: { class: 'img-circle' }}, 55 | { name: 'Image thumbnail', element: 'img', attributes: { class: 'img-thumbnail' }}, 56 | 57 | { name: 'Blockquote reverse', element: 'blockquote', attributes: { class: 'blockquote-reverse' }}, 58 | 59 | { name: 'Background primary', element: CKEDITOR.allElements, attributes: { class: 'bg-primary' }}, 60 | { name: 'Background success', element: CKEDITOR.allElements, attributes: { class: 'bg-success' }}, 61 | { name: 'Background info', element: CKEDITOR.allElements, attributes: { class: 'bg-info' }}, 62 | { name: 'Background warning', element: CKEDITOR.allElements, attributes: { class: 'bg-warning' }}, 63 | { name: 'Background danger', element: CKEDITOR.allElements, attributes: { class: 'bg-danger' }}, 64 | 65 | { name: 'Pull left', element: CKEDITOR.allElements, attributes: { class: 'pull-left' }}, 66 | { name: 'Pull right', element: CKEDITOR.allElements, attributes: { class: 'pull-right' }}, 67 | { name: 'Center block', element: CKEDITOR.allElements, attributes: { class: 'center-block' }}, 68 | { name: 'Clearfix', element: CKEDITOR.allElements, attributes: { class: 'clearfix' }}, 69 | 70 | { name: 'Screenreader only', element: CKEDITOR.allElements, attributes: { class: 'sr-only' }}, 71 | { name: 'Screenreader only focusable', element: CKEDITOR.allElements, attributes: { class: 'sr-only-focusable' }}, 72 | { name: 'Text hide', element: CKEDITOR.allElements, attributes: { class: 'text-hide' }}, 73 | 74 | // not enabled by default 75 | // http://getbootstrap.com/css/#helper-classes-close 76 | // { name: 'Close', element: CKEDITOR.allElements, attributes: { class: 'center-block' }}, 77 | // http://getbootstrap.com/css/#helper-classes-carets 78 | // { name: 'Caret', element: CKEDITOR.allElements, attributes: { class: 'clearfix' }}, 79 | 80 | // additional classes not included in basic bootstrap 81 | { name: 'Spacer', element: 'div', attributes: { class: 'spacer' }}, 82 | { name: 'Spacer Small', element: 'div', attributes: { class: 'spacer-xs' }}, 83 | { name: 'Spacer Large', element: 'div', attributes: { class: 'spacer-lg' }}, 84 | { name: 'Spacer Zero', element: 'div', attributes: { class: 'spacer-zero' }} 85 | ]); 86 | 87 | /* 88 | * Extend ckeditor default settings 89 | * DOCS: http://docs.ckeditor.com/#!/api/CKEDITOR.dtd 90 | */ 91 | CKEDITOR.dtd.$removeEmpty.span = 0; 92 | -------------------------------------------------------------------------------- /aldryn_bootstrap3/static/aldryn_bootstrap3/js/dropzone.init.js: -------------------------------------------------------------------------------- 1 | // #DROPZONE# 2 | // This script implements the dropzone settings 3 | 'use strict'; 4 | 5 | /* globals Dropzone */ 6 | (function ($) { 7 | $(function () { 8 | var dropzoneSelector = '.js-filer-dropzone'; 9 | var dropzones; 10 | var infoMessage = '.js-filer-dropzone-info-message'; 11 | var errorMessage = '.js-filer-dropzone-error-message'; 12 | var uploadInfo = '.js-filer-dropzone-upload-info'; 13 | var uploadWelcome = '.js-filer-dropzone-upload-welcome'; 14 | var uploadFileName = '.js-filer-dropzone-file-name'; 15 | var uploadProgress = '.js-filer-dropzone-progress'; 16 | var uploadSuccess = '.js-filer-dropzone-upload-success'; 17 | var dragHoverClass = 'dz-drag-hover'; 18 | var originalImage = '.js-original-image'; 19 | var hideMessageTimeout; 20 | var errorMessageTimeout = 2; 21 | 22 | dropzones = $(dropzoneSelector); 23 | if (dropzones.length && Dropzone) { 24 | Dropzone.autoDiscover = false; 25 | dropzones.each(function () { 26 | var dropzone = $(this); 27 | var dropzoneUrl = $(this).data('filer-url'); 28 | new Dropzone(this, { 29 | url: dropzoneUrl, 30 | paramName: 'file', 31 | uploadMultiple: false, 32 | previewTemplate: '
', 33 | clickable: false, 34 | addRemoveLinks: false, 35 | accept: function (file, done) { 36 | if (!file.type.match('image.*')) { 37 | dropzone.find(errorMessage).show(); 38 | clearTimeout(hideMessageTimeout); 39 | hideMessageTimeout = setTimeout(function () { 40 | dropzone.find(errorMessage).hide(); 41 | }, errorMessageTimeout * 1000); 42 | done('Error') 43 | } else { 44 | dropzone.find(errorMessage).hide(); 45 | done(); 46 | } 47 | }, 48 | maxfilesexceeded: function (file) { 49 | this.removeAllFiles(); 50 | this.addFile(file); 51 | }, 52 | dragover: function () { 53 | dropzone.find(uploadSuccess).hide(); 54 | dropzone.find(infoMessage).show(); 55 | dropzone.addClass(dragHoverClass); 56 | }, 57 | dragleave: function () { 58 | clearTimeout(hideMessageTimeout); 59 | hideMessageTimeout = setTimeout(function () { 60 | dropzone.find(infoMessage).hide(); 61 | }, 100); 62 | 63 | dropzone.find(infoMessage).show(); 64 | dropzone.removeClass(dragHoverClass); 65 | }, 66 | drop: function () { 67 | clearTimeout(hideMessageTimeout); 68 | dropzone.find(infoMessage).show(); 69 | dropzone.removeClass(dragHoverClass); 70 | }, 71 | sending: function (file) { 72 | dropzone.find(uploadWelcome).hide(); 73 | dropzone.find(uploadFileName).text(file.name); 74 | dropzone.find(uploadProgress).width(0); 75 | dropzone.find(uploadInfo).show(); 76 | }, 77 | uploadprogress: function (file, progress) { 78 | dropzone.find(uploadProgress).width(progress + '%'); 79 | }, 80 | success: function (file, response) { 81 | dropzone.find(uploadInfo).hide(); 82 | dropzone.find(uploadSuccess).show(); 83 | if (file && file.status === 'success' && response) { 84 | if (response.original_image) { 85 | dropzone.find(originalImage).attr('src', response.original_image) 86 | // TODO this should be CMS.API call 87 | // FIXME only works on 3.2 88 | $('.cms-btn-publish').addClass('cms-btn-publish-active') 89 | .removeClass('cms-btn-disabled') 90 | .parent().show(); 91 | $('.cms-toolbar-revert').removeClass('cms-toolbar-item-navigation-disabled'); 92 | $(window).trigger('resize'); 93 | } 94 | } 95 | }, 96 | queuecomplete: function () { 97 | dropzone.find(infoMessage).hide(); 98 | dropzone.find(uploadSuccess).hide(); 99 | dropzone.find(uploadWelcome).show(); 100 | } 101 | }); 102 | }); 103 | } 104 | }); 105 | })(jQuery); 106 | -------------------------------------------------------------------------------- /aldryn_bootstrap3/static/aldryn_bootstrap3/js/iconset/iconset-fontawesome-4.2.0.min.js: -------------------------------------------------------------------------------- 1 | /*!======================================================================== 2 | * Bootstrap: iconset-fontawesome-4.2.0.js by @recktoner 3 | * https://victor-valencia.github.com/bootstrap-iconpicker 4 | * 5 | * Iconset: Font Awesome 4.2.0 6 | * http://fortawesome.github.io/Font-Awesome/ 7 | * ======================================================================== 8 | * Copyright 2013-2015 Victor Valencia Rico. 9 | * 10 | * Licensed under the Apache License, Version 2.0 (the "License"); 11 | * you may not use this file except in compliance with the License. 12 | * You may obtain a copy of the License at 13 | * 14 | * http://www.apache.org/licenses/LICENSE-2.0 15 | * 16 | * Unless required by applicable law or agreed to in writing, software 17 | * distributed under the License is distributed on an "AS IS" BASIS, 18 | * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. 19 | * See the License for the specific language governing permissions and 20 | * limitations under the License. 21 | * ======================================================================== */ 22 | !function($){$.iconset_fontawesome={iconClass:"fa",iconClassFix:"fa-",icons:["","adjust","anchor","archive","area-chart","arrows","arrows-h","arrows-v","automobile","asterisk","at","ban","bank","bar-chart-o","barcode","bars","beer","bell","bell-o","bell-slash","bell-slash-o","bicycle","binoculars","birthday-cake","bolt","bomb","book","bookmark","bookmark-o","briefcase","bug","building","building-o","bullhorn","bullseye","bus","cab","calculator","calendar","calendar-o","camera","camera-retro","car","caret-square-o-down","caret-square-o-left","caret-square-o-right","caret-square-o-up","cc","cc-amex","cc-discover","cc-mastercard","cc-paypal","cc-stripe","cc-visa","certificate","check","check-circle","check-circle-o","check-square","check-square-o","child","circle","circle-o","circle-thin","clock-o","cloud","cloud-download","cloud-upload","code","code-fork","coffee","cog","cogs","comment","comment-o","comments","comments-o","compass","copyright","credit-card","crop","crosshairs","cube","cubes","cutlery","dashboard","desktop","dashboard","database","desktop","dot-circle-o","download","edit","ellipsis-h","ellipsis-v","envelope","envelope-o","envelope-square","eraser","exchange","exclamation","exclamation-circle","exclamation-triangle","external-link","external-link-square","eye","eye-slash","eyedropper","fax","female","fighter-jet","file-archive-o","file-audio-o","file-code-o","file-excel-o","file-image-o","file-movie-o","file-pdf-o","file-photo-o","file-picture-o","file-powerpoint-o","file-sound-o","file-video-o","file-word-o","file-zip-o","film","filter","fire","fire-extinguisher","flag","flag-checkered","flag-o","flash","flask","folder","folder-o","folder-open","folder-open-o","frown-o","futbol-o","gamepad","gavel","gear","gears","gift","glass","globe","graduation-cap","group","hdd-o","headphones","heart","heart-o","history","home","image","inbox","info","info-circle","institution","key","keyboard-o","language","laptop","leaf","legal","lemon-o","level-down","level-up","life-bouy","life-ring","life-saver","lightbulb-o","line-chart","location-arrow","lock","magic","magnet","mail-forward","mail-reply","mail-reply-all","male","map-marker","meh-o","microphone","microphone-slash","minus","minus-circle","minus-square","minus-square-o","mobile","mobile-phone","money","moon-o","mortar-board","music","navicon","newspaper-o","paint-brush","paper-plane","paper-plane-o","paw","pencil","pencil-square","pencil-square-o","phone","phone-square","photo","picture-o","pie-chart","plane","plug","plus","plus-circle","plus-square","plus-square-o","power-off","print","puzzle-piece","qrcode","question","question-circle","quote-left","quote-right","random","refresh","reorder","reply","reply-all","retweet","road","rocket","rss","rss-square","search","search-minus","search-plus","send","send-o","share","share-alt","share-alt-square","share-square","share-square-o","shield","shopping-cart","sign-in","sign-out","signal","sitemap","sliders","smile-o","soccer-ball-o","sort","sort-alpha-asc","sort-alpha-desc","sort-amount-asc","sort-amount-desc","sort-asc","sort-desc","sort-down","sort-numeric-asc","sort-numeric-desc","sort-up","space-shuttle","spinner","spoon","square","square-o","star","star-half","star-half-empty","star-half-full","star-half-o","star-o","suitcase","sun-o","support","tablet","tachometer","tag","tags","tasks","taxi","terminal","thumb-tack","thumbs-down","thumbs-o-down","thumbs-o-up","thumbs-up","ticket","times","times-circle","times-circle-o","tint","toggle-down","toggle-left","toggle-off","toggle-on","toggle-right","toggle-up","trash","trash-o","tree","trophy","truck","tty","umbrella","university","unlock","unlock-alt","unsorted","upload","user","users","video-camera","volume-down","volume-off","volume-up","warning","wheelchair","wifi","wrench","check-square","check-square-o","circle","circle-o","dot-circle-o","minus-square","minus-square-o","plus-square","plus-square-o","square","square-o","bitcoin","btc","cny","dollar","eur","euro","gbp","ils","inr","jpy","krw","money","rmb","rouble","rub","ruble","rupee","shekel","sheqel","try","turkish-lira","usd","won","yen","align-center","align-justify","align-left","align-right","bold","chain","chain-broken","clipboard","columns","copy","cut","dedent","eraser","file","file-o","file-text","file-text-o","files-o","floppy-o","font","header","indent","italic","link","list","list-alt","list-ol","list-ul","outdent","paperclip","paragraph","paste","repeat","rotate-left","rotate-right","save","scissors","strikethrough","subscript","superscript","table","text-height","text-width","th","th-large","th-list","underline","undo","unlink","angle-double-down","angle-double-left","angle-double-right","angle-double-up","angle-down","angle-left","angle-right","angle-up","arrow-circle-down","arrow-circle-left","arrow-circle-o-down","arrow-circle-o-left","arrow-circle-o-right","arrow-circle-o-up","arrow-circle-right","arrow-circle-up","arrow-down","arrow-left","arrow-right","arrow-up","arrows","arrows-alt","arrows-h","arrows-v","caret-down","caret-left","caret-right","caret-square-o-down","caret-square-o-left","caret-square-o-right","caret-square-o-up","caret-up","chevron-circle-down","chevron-circle-left","chevron-circle-right","chevron-circle-up","chevron-down","chevron-left","chevron-right","chevron-up","hand-o-down","hand-o-left","hand-o-right","hand-o-up","long-arrow-down","long-arrow-left","long-arrow-right","long-arrow-up","toggle-down","toggle-left","toggle-right","toggle-up","arrows-alt","backward","compress","eject","expand","fast-backward","fast-forward","forward","pause","play","play-circle","play-circle-o","step-backward","step-forward","stop","youtube-play","adn","android","angellist","apple","behance","behance-square","bitbucket","bitbucket-square","bitcoin","btc","css3","delicious","digg","dribbble","dropbox","drupal","empire","facebook","facebook-square","flickr","foursquare","ge","git","git-square","github","github-alt","github-square","gittip","google","google-plus","google-plus-square","google-wallet","hacker-news","html5","instagram","ioxhost","joomla","jsfiddle","lastfm","lastfm-square","linkedin","linkedin-square","linux","maxcdn","meanpath","openid","pagelines","paypal","pied-piper","pied-piper-alt","pinterest","pinterest-square","qq","ra","rebel","reddit","reddit-square","renren","share-alt","share-alt-square","skype","slack","slideshare","soundcloud","spotify","stack-exchange","stack-overflow","steam","steam-square","stumbleupon","stumbleupon-circle","tencent-weibo","trello","tumblr","tumblr-square","twitch","twitter","twitter-square","vimeo-square","vine","vk","wechat","weibo","weixin","windows","wordpress","xing","xing-square","yahoo","yelp","youtube","youtube-play","youtube-square","ambulance","h-square","hospital-o","medkit","plus-square","stethoscope","user-md","wheelchair"]}}(jQuery); -------------------------------------------------------------------------------- /aldryn_bootstrap3/static/aldryn_bootstrap3/js/iconset/iconset-glyphicon.min.js: -------------------------------------------------------------------------------- 1 | /*!======================================================================== 2 | * Bootstrap: iconset-glyphicon.js by @recktoner 3 | * https://victor-valencia.github.com/bootstrap-iconpicker 4 | * 5 | * Iconset: Glyphicons 6 | * ======================================================================== 7 | * Copyright 2013-2015 Victor Valencia Rico. 8 | * 9 | * Licensed under the Apache License, Version 2.0 (the "License"); 10 | * you may not use this file except in compliance with the License. 11 | * You may obtain a copy of the License at 12 | * 13 | * http://www.apache.org/licenses/LICENSE-2.0 14 | * 15 | * Unless required by applicable law or agreed to in writing, software 16 | * distributed under the License is distributed on an "AS IS" BASIS, 17 | * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. 18 | * See the License for the specific language governing permissions and 19 | * limitations under the License. 20 | * ======================================================================== */ 21 | !function($){$.iconset_glyphicon={iconClass:"glyphicon",iconClassFix:"glyphicon-",icons:["","adjust","align-center","align-justify","align-left","align-right","arrow-down","arrow-left","arrow-right","arrow-up","asterisk","backward","ban-circle","barcode","bell","bold","book","bookmark","briefcase","bullhorn","calendar","camera","certificate","check","chevron-down","chevron-left","chevron-right","chevron-up","circle-arrow-down","circle-arrow-left","circle-arrow-right","circle-arrow-up","cloud","cloud-download","cloud-upload","cog","collapse-down","collapse-up","comment","compressed","copyright-mark","credit-card","cutlery","dashboard","download","download-alt","earphone","edit","eject","envelope","euro","exclamation-sign","expand","export","eye-close","eye-open","facetime-video","fast-backward","fast-forward","file","film","filter","fire","flag","flash","floppy-disk","floppy-open","floppy-remove","floppy-save","floppy-saved","folder-close","folder-open","font","forward","fullscreen","gbp","gift","glass","globe","hand-down","hand-left","hand-right","hand-up","hd-video","hdd","header","headphones","heart","heart-empty","home","import","inbox","indent-left","indent-right","info-sign","italic","leaf","link","list","list-alt","lock","log-in","log-out","magnet","map-marker","minus","minus-sign","move","music","new-window","off","ok","ok-circle","ok-sign","open","paperclip","pause","pencil","phone","phone-alt","picture","plane","play","play-circle","plus","plus-sign","print","pushpin","qrcode","question-sign","random","record","refresh","registration-mark","remove","remove-circle","remove-sign","repeat","resize-full","resize-horizontal","resize-small","resize-vertical","retweet","road","save","saved","screenshot","sd-video","search","send","share","share-alt","shopping-cart","signal","sort","sort-by-alphabet","sort-by-alphabet-alt","sort-by-attributes","sort-by-attributes-alt","sort-by-order","sort-by-order-alt","sound-5-1","sound-6-1","sound-7-1","sound-dolby","sound-stereo","star","star-empty","stats","step-backward","step-forward","stop","subtitles","tag","tags","tasks","text-height","text-width","th","th-large","th-list","thumbs-down","thumbs-up","time","tint","tower","transfer","trash","tree-conifer","tree-deciduous","unchecked","upload","usd","user","volume-down","volume-off","volume-up","warning-sign","wrench","zoom-in","zoom-out"]}}(jQuery); -------------------------------------------------------------------------------- /aldryn_bootstrap3/templates/admin/aldryn_bootstrap3/base.html: -------------------------------------------------------------------------------- 1 | {% extends "admin/cms/page/plugin/change_form.html" %} 2 | {% load staticfiles %} 3 | 4 | {% block extrahead %} 5 | {{ block.super }} 6 | 7 | 8 | 9 | 10 | 11 | 12 | 13 | 14 | 15 | 16 | 17 | {% endblock %} 18 | -------------------------------------------------------------------------------- /aldryn_bootstrap3/templates/admin/aldryn_bootstrap3/plugins/button/change_form.html: -------------------------------------------------------------------------------- 1 | {% extends "admin/aldryn_bootstrap3/base.html" %} 2 | {% load i18n %} 3 | 4 | {% block field_sets %} 5 |
6 |
7 |

8 | 9 | {% trans "Preview" %} 10 |

11 |

12 | 13 | 14 |   15 | 16 | 17 |

18 |
19 |
20 | 21 | {{ block.super }} 22 | {% endblock %} 23 | -------------------------------------------------------------------------------- /aldryn_bootstrap3/templates/admin/aldryn_bootstrap3/plugins/code/change_form.html: -------------------------------------------------------------------------------- 1 | {% extends "admin/aldryn_bootstrap3/base.html" %} 2 | {% load static %} 3 | 4 | {% block object-tools %} 5 | {{ block.super }} 6 | 7 | 8 | 46 | {% endblock %} 47 | -------------------------------------------------------------------------------- /aldryn_bootstrap3/templates/admin/aldryn_bootstrap3/plugins/column/change_form.html: -------------------------------------------------------------------------------- 1 | {% extends "admin/aldryn_bootstrap3/base.html" %} 2 | 3 | {% block field_sets %} 4 |
5 | {{ block.super }} 6 |
7 | {% endblock %} 8 | -------------------------------------------------------------------------------- /aldryn_bootstrap3/templates/admin/aldryn_bootstrap3/plugins/label/change_form.html: -------------------------------------------------------------------------------- 1 | {% extends "admin/aldryn_bootstrap3/base.html" %} 2 | {% load i18n %} 3 | 4 | {% block field_sets %} 5 |
6 |
7 |

8 | 9 | {% trans "Preview" %} 10 |

11 | 12 |

13 |   14 |

15 |
16 |
17 | 18 | {{ block.super }} 19 | {% endblock %} 20 | -------------------------------------------------------------------------------- /aldryn_bootstrap3/templates/admin/aldryn_bootstrap3/plugins/row/change_form.html: -------------------------------------------------------------------------------- 1 | {% extends "admin/aldryn_bootstrap3/base.html" %} 2 | 3 | {% block field_sets %} 4 |
5 | {{ block.super }} 6 |
7 | {% endblock %} 8 | -------------------------------------------------------------------------------- /aldryn_bootstrap3/templates/admin/aldryn_bootstrap3/widgets/context.html: -------------------------------------------------------------------------------- 1 | {% load static %} 2 | 3 |
4 |
5 | {% if widget %} 6 | {# Django 1.11+ #} 7 | {% for group, options, index in widget.optgroups %} 8 | {% for option in options %} 9 | {% include option.template_name with widget=option %}{% endfor %} 10 | {% endfor %} 11 | {% elif selects %} 12 | {# Django < 1.11 #} 13 | {% for item in selects %} 14 | {{ item }} 15 | {% endfor %} 16 | {% endif %} 17 |
18 |
19 | -------------------------------------------------------------------------------- /aldryn_bootstrap3/templates/admin/aldryn_bootstrap3/widgets/dragndrop.html: -------------------------------------------------------------------------------- 1 | {% comment %} 2 | 3 | NOTE: Drag and drop support has been removed for now, this file is kept 4 | for reference on the old implementation / assets 5 | 6 | DOCS: https://html.spec.whatwg.org/multipage/embedded-content.html#introduction-3:viewport-based-selection-2 7 | the browser assumes size="100vw" by default, which means 8 | "assume this image will be displayed at full width on the 9 | current viewport and pick an image from srcset accordingly". 10 | 11 | {# only load js and css required for dnd upload if toolbar is available #} 12 | {% if request.toolbar and request.toolbar.show_toolbar and request.toolbar.edit_mode %} 13 | {% addtoblock "css" %}{% endaddtoblock %} 14 | {% addtoblock "js" %}{% endaddtoblock %} 15 | {% addtoblock "js" %}{% endaddtoblock %} 16 | {% endif %} 17 | 18 | {% endcomment %} 19 | 20 | {% comment %} 21 | # attached before the image 22 | {% if request.toolbar and request.toolbar.show_toolbar and request.toolbar.edit_mode %} 23 | {% if has_dnd_support %} 24 | 25 | {% endif %} 26 | {% endif %} 27 | 28 | # attached after the image 29 | {% if request.toolbar and request.toolbar.show_toolbar and request.toolbar.edit_mode %} 30 | {% if has_dnd_support %} 31 | 47 | 53 | 54 | {% endif %}{# has_dnd_support #} 55 | {% endif %} 56 | 57 | # attached to the css 58 | {% if request.toolbar and request.toolbar.show_toolbar and request.toolbar.edit_mode %}js-original-image {% endif %} 59 | {% endcomment %} 60 | 61 | {% comment %} 62 | The raw image (original image) can be accessed via: 63 | * {{ instance.file.url }} 64 | There are additional parameters available for thumbnailing purposes: 65 | * {{ instance.srcset.lg }} large 66 | * {{ instance.srcset.md }} medium 67 | * {{ instance.srcset.sm }} small 68 | * {{ instance.srcset.xs }} extra small 69 | Example: {% thumbnail instance.file instance.srcset.lg.size ... %} 70 | 71 | In addition, an iterable object is available via ``instance.srcset.items`` to 72 | access all size settings at once. 73 | Example: {% for device, src in instance.srcset.items %} 74 | {% endcomment %} 75 | -------------------------------------------------------------------------------- /aldryn_bootstrap3/templates/admin/aldryn_bootstrap3/widgets/icon.html: -------------------------------------------------------------------------------- 1 | {% load i18n %} 2 | 3 |
6 | {% if not iconsets %} 7 |
8 | {% trans "No Iconsets configured. Please configure at least one Iconset before using this widget." %} 9 |
10 | {% else %} 11 |
12 | {# label "icon" relates to elements ID #} 13 | {% if not is_required %} 14 | 15 | {% endif %} 16 | 17 | 18 | 25 | 26 | 33 | 34 |
35 | {% endif %} 36 |
37 | -------------------------------------------------------------------------------- /aldryn_bootstrap3/templates/admin/aldryn_bootstrap3/widgets/link_or_button.html: -------------------------------------------------------------------------------- 1 | {% if widget %} 2 | {# Django 1.11+ #} 3 | {% for group, options, index in widget.optgroups %} 4 | {% for option in options %} 5 | {% include option.template_name with widget=option %}{% endfor %} 6 | {% endfor %} 7 | {% elif selects %} 8 | {# Django < 1.11 #} 9 | {% for item in selects %} 10 | {{ item }} 11 | {% endfor %} 12 | {% endif %} -------------------------------------------------------------------------------- /aldryn_bootstrap3/templates/admin/aldryn_bootstrap3/widgets/responsive.html: -------------------------------------------------------------------------------- 1 | {% load i18n %} 2 | 3 |
4 |
5 | 11 | 17 | 23 | 29 | 34 | 40 |
41 | 42 | 45 |
46 | 47 | {% comment %} 48 |
49 | Data structure that can be used to build the UI (only use it if it is helpful. Might be easier to just 50 | hardcode all in the template). 51 | Make sure to prefix the name of any input created here, so the names don't clash with real fields in 52 | the form. 53 |
    54 | {% for device, options in choices %} 55 |
  • 56 | {{ device }} 57 |
      58 | {% for option_value, verbose_name in options %} 59 |
    • {{ verbose_name }} ({{ option_value }})
    • 60 | {% endfor %} 61 |
    62 |
  • 63 | {% endfor %} 64 |
65 |
66 | 67 |
68 | Save the resulting selection as a space seperated list of css classes into the textarea with 69 | name={{ name }}. It expects something like: 70 |
71 | hidden-xs visible-sm-inline-block visible-lg-block
72 | 
73 | In the example "None" was selected for md, so there is no entry for it. I don't do any server side 74 | validation, so please make sure there are no conflicting entries. 75 |
76 | {{ widget_html }} 77 | 78 |
79 | Other Template variables: 80 |
81 |     id: {{ id }} (css id of the textarea)
82 |     name: {{ name }}
83 |     value: {{ value }}
84 | 
85 |
86 | {% endcomment %} 87 | -------------------------------------------------------------------------------- /aldryn_bootstrap3/templates/admin/aldryn_bootstrap3/widgets/responsive_print.html: -------------------------------------------------------------------------------- 1 | {% load i18n %} 2 | 3 |
4 |
5 | 11 | 16 | 22 |
23 | 24 | 27 |
28 | 29 | {% comment %} 30 |
31 | Data structure that can be used to build the UI (only use it if it is helpful. Might be easier to just 32 | hardcode all in the template). 33 | Make sure to prefix the name of any input created here, so the names don't clash with real fields in 34 | the form. 35 |
    36 | {% for value, verbose_name in choices %} 37 |
  • {{ verbose_name }} ({{ value }})
  • 38 | {% endfor %} 39 |
40 |
41 | 42 |
43 | Save the resulting selection as a class name into the textarea with 44 | name={{ name }}. It expects something like: 45 |
46 | visible-print-block
47 | 
48 | 49 |
50 | {{ widget_html }} 51 | 52 |
53 | Other Template variables: 54 |
55 |     id: {{ id }} (css id of the textarea)
56 |     name: {{ name }}
57 |     value: {{ value }}
58 | 
59 |
60 | {% endcomment %} 61 | -------------------------------------------------------------------------------- /aldryn_bootstrap3/templates/admin/aldryn_bootstrap3/widgets/size.html: -------------------------------------------------------------------------------- 1 |
2 | {% if widget %} 3 | {# Django 1.11+ #} 4 | {% for group, options, index in widget.optgroups %} 5 | {% for option in options %} 6 | {% include option.template_name with widget=option %}{% endfor %} 7 | {% endfor %} 8 | {% elif selects %} 9 | {# Django < 1.11 #} 10 | {% for item in selects %} 11 | {{ item }} 12 | {% endfor %} 13 | {% endif %} 14 |
15 | -------------------------------------------------------------------------------- /aldryn_bootstrap3/templates/aldryn_bootstrap3/plugins/accordion.html: -------------------------------------------------------------------------------- 1 | {% load cms_tags %} 2 | 3 |
10 | 11 | {% for plugin in instance.child_plugin_instances %} 12 | {% with parentloop=forloop index=instance.index %} 13 | {% render_plugin plugin %} 14 | {% endwith %} 15 | {% endfor %} 16 |
17 | -------------------------------------------------------------------------------- /aldryn_bootstrap3/templates/aldryn_bootstrap3/plugins/accordion_item.html: -------------------------------------------------------------------------------- 1 | {% load cms_tags %} 2 | 3 |
7 | 8 | 20 | 21 |
25 |
26 | {% for plugin in item.child_plugin_instances %} 27 | {% render_plugin plugin %} 28 | {% endfor %} 29 |
30 |
31 |
32 | -------------------------------------------------------------------------------- /aldryn_bootstrap3/templates/aldryn_bootstrap3/plugins/alert.html: -------------------------------------------------------------------------------- 1 | {% load cms_tags %} 2 | 3 |
7 | 8 | {% if instance.icon %} 9 | {% with icon_class=instance.icon extra_css_classes="pull-left" %}{% include 'aldryn_bootstrap3/plugins/includes/icon.html' %}{% endwith %} 10 | {% endif %} 11 | 12 | {% for plugin in instance.child_plugin_instances %} 13 | {% render_plugin plugin %} 14 | {% endfor %} 15 |
16 | -------------------------------------------------------------------------------- /aldryn_bootstrap3/templates/aldryn_bootstrap3/plugins/blockquote.html: -------------------------------------------------------------------------------- 1 | {% load cms_tags %} 2 | 3 |
7 | 8 | {% for plugin in instance.child_plugin_instances %} 9 | {% render_plugin plugin %} 10 | {% endfor %} 11 |
12 | -------------------------------------------------------------------------------- /aldryn_bootstrap3/templates/aldryn_bootstrap3/plugins/button.html: -------------------------------------------------------------------------------- 1 | {% load cms_tags %}{% spaceless %} 22 | {% if instance.icon_left %}{% with icon_class=instance.icon_left %}{% include 'aldryn_bootstrap3/plugins/includes/icon.html' %}{% endwith %}{% endif %} 23 | 24 | {{ instance.label }} 25 | 26 | {% for plugin in instance.child_plugin_instances %} 27 | {% render_plugin plugin %} 28 | {% endfor %} 29 | 30 | {% if instance.icon_right %}{% with icon_class=instance.icon_right %}{% include 'aldryn_bootstrap3/plugins/includes/icon.html' %}{% endwith %}{% endif %} 31 | {% endspaceless %} -------------------------------------------------------------------------------- /aldryn_bootstrap3/templates/aldryn_bootstrap3/plugins/carousel/base.html: -------------------------------------------------------------------------------- 1 | {% load static sekizai_tags %} 2 | 3 | {# DOCS: http://getbootstrap.com/javascript/#carousel #} 4 | 21 | -------------------------------------------------------------------------------- /aldryn_bootstrap3/templates/aldryn_bootstrap3/plugins/carousel/standard/carousel.html: -------------------------------------------------------------------------------- 1 | {% extends "aldryn_bootstrap3/plugins/carousel/base.html" %} 2 | {% load i18n cms_tags %} 3 | 4 | {% block content_carousel %} 5 | {% with carousel=instance %} 6 | {# INFO: indicators #} 7 | 12 | 13 | {# Wrapper for slides #} 14 | 19 | 20 | {# INFO: controls #} 21 | 22 | 23 | {% trans "Previous" %} 24 | 25 | 26 | 27 | {% trans "Next" %} 28 | 29 | {% endwith %} 30 | {% endblock content_carousel %} 31 | -------------------------------------------------------------------------------- /aldryn_bootstrap3/templates/aldryn_bootstrap3/plugins/carousel/standard/image_slide.html: -------------------------------------------------------------------------------- 1 | {# INFO: slide for a filer.Image instance #} 2 |
3 | {% with srcset=carousel.srcset %}{% include 'aldryn_bootstrap3/plugins/carousel/standard/includes/image.html' %}{% endwith %} 4 |
5 | -------------------------------------------------------------------------------- /aldryn_bootstrap3/templates/aldryn_bootstrap3/plugins/carousel/standard/includes/image.html: -------------------------------------------------------------------------------- 1 | {% load cms_tags thumbnail %} 2 | {{ image.default_alt_text|default:'' }} 17 | -------------------------------------------------------------------------------- /aldryn_bootstrap3/templates/aldryn_bootstrap3/plugins/carousel/standard/slide.html: -------------------------------------------------------------------------------- 1 | {% load cms_tags %} 2 | 3 | {# INFO: slide for a SlideCMSPlugin instance #} 4 |
7 | {% with link=instance.get_link_url image=instance.image %} 8 | {% if link %} 9 | 10 | {% if image %} 11 | {% with image=instance.image srcset=carousel.srcset %}{% include 'aldryn_bootstrap3/plugins/carousel/standard/includes/image.html' %}{% endwith %} 12 | {% else %} 13 | {{ instance.link_text }} 14 | {% endif %} 15 | 16 | {% elif image %} 17 | {% with image=instance.image srcset=carousel.srcset %}{% include 'aldryn_bootstrap3/plugins/carousel/standard/includes/image.html' %}{% endwith %} 18 | {% endif %} 19 | {% endwith %} 20 | 21 | {% if instance.content or instance.child_plugin_instances %} 22 | 28 | {% endif %} 29 |
30 | -------------------------------------------------------------------------------- /aldryn_bootstrap3/templates/aldryn_bootstrap3/plugins/carousel/standard/slide_folder.html: -------------------------------------------------------------------------------- 1 | {% for image in instance.folder.files %} 2 | {% include slide_template %} 3 | {% endfor %} 4 | -------------------------------------------------------------------------------- /aldryn_bootstrap3/templates/aldryn_bootstrap3/plugins/cite.html: -------------------------------------------------------------------------------- 1 | {% load cms_tags %} 2 | 3 | 6 | {% for plugin in instance.child_plugin_instances %} 7 | {% render_plugin plugin %} 8 | {% endfor %} 9 | 10 | -------------------------------------------------------------------------------- /aldryn_bootstrap3/templates/aldryn_bootstrap3/plugins/code.html: -------------------------------------------------------------------------------- 1 | <{{ instance.code_type }} 2 | {% if instance.classes %} class="{{ instance.classes }}"{% endif %} 3 | {{ instance.attributes_str }}>{{ instance.code }} -------------------------------------------------------------------------------- /aldryn_bootstrap3/templates/aldryn_bootstrap3/plugins/column.html: -------------------------------------------------------------------------------- 1 | {% load cms_tags %} 2 | 3 | <{{ instance.tag }} class="{{ instance.get_column_classes }} 4 | {% if instance.classes %} {{ instance.classes }}{% endif %}" 5 | {{ instance.attributes_str }}> 6 | 7 | {% for plugin in instance.child_plugin_instances %} 8 | {% render_plugin plugin %} 9 | {% endfor %} 10 | 11 | -------------------------------------------------------------------------------- /aldryn_bootstrap3/templates/aldryn_bootstrap3/plugins/file.html: -------------------------------------------------------------------------------- 1 | 5 | {% if instance.icon_left %} 6 | {% with icon_class=instance.icon_left extra_css_classes=instance.icon_left.classes %} 7 | {% include 'aldryn_bootstrap3/plugins/includes/icon.html' %} 8 | {% endwith %} 9 | {% endif %} 10 | 11 | {% if instance.name %} 12 | {{ instance.name }} 13 | {% else %} 14 | {{ instance.file }} 15 | {% endif %} 16 | {% if instance.show_file_size %} 17 | {{ instance.file.size|filesizeformat }} 18 | {% endif %} 19 | 20 | {% if instance.icon_right %} 21 | {% with icon_class=instance.icon_right extra_css_classes=instance.icon_right.classes %} 22 | {% include 'aldryn_bootstrap3/plugins/includes/icon.html' %} 23 | {% endwith %} 24 | {% endif %} 25 | 26 | -------------------------------------------------------------------------------- /aldryn_bootstrap3/templates/aldryn_bootstrap3/plugins/icon.html: -------------------------------------------------------------------------------- 1 | {% load cms_tags %}{% spaceless %} 2 | {% with icon_class=instance.icon extra_css_classes=instance.classes %}{% include 'aldryn_bootstrap3/plugins/includes/icon.html' %}{% endwith %} 3 | {% endspaceless %} 4 | -------------------------------------------------------------------------------- /aldryn_bootstrap3/templates/aldryn_bootstrap3/plugins/image.html: -------------------------------------------------------------------------------- 1 | {% load i18n cms_tags thumbnail staticfiles sekizai_tags %}{% comment %} 2 | The raw image (original image) can be accessed via: 3 | * {{ instance.file.url }} 4 | There are additional parameters available for thumbnailing purposes: 5 | * {{ instance.srcset.lg }} large 6 | * {{ instance.srcset.md }} medium 7 | * {{ instance.srcset.sm }} small 8 | * {{ instance.srcset.xs }} extra small 9 | Example: {% thumbnail instance.file instance.srcset.lg.size ... %} 10 | 11 | In addition, an iterable object is available via ``instance.srcset.items`` to 12 | access all size settings at once. 13 | Example: {% for device, src in instance.srcset.items %} 14 | {% endcomment %}{{ instance.alt }}{# include "admin/aldryn_bootstrap3/widgets/dragndrop.html" #} 46 | -------------------------------------------------------------------------------- /aldryn_bootstrap3/templates/aldryn_bootstrap3/plugins/includes/icon.html: -------------------------------------------------------------------------------- 1 | {% load aldryn_bootstrap3_tags %} 2 | 3 | 6 | -------------------------------------------------------------------------------- /aldryn_bootstrap3/templates/aldryn_bootstrap3/plugins/jumbotron.html: -------------------------------------------------------------------------------- 1 | {% load cms_tags %} 2 | 3 |
6 | {% if instance.grid %}
{% endif %} 7 | {% for plugin in instance.child_plugin_instances %} 8 | {% render_plugin plugin %} 9 | {% endfor %} 10 | {% if instance.grid %}
{% endif %} 11 |
12 | -------------------------------------------------------------------------------- /aldryn_bootstrap3/templates/aldryn_bootstrap3/plugins/label.html: -------------------------------------------------------------------------------- 1 | {% load cms_tags %}{{ instance.label }}{% for plugin in instance.child_plugin_instances %} {% render_plugin plugin %} {% endfor %} 4 | -------------------------------------------------------------------------------- /aldryn_bootstrap3/templates/aldryn_bootstrap3/plugins/list_group.html: -------------------------------------------------------------------------------- 1 | {% load cms_tags %} 2 | 3 |
6 | 7 | {% for plugin in instance.child_plugin_instances %} 8 | {% with parentloop=forloop list_group_instance=instance %}{% render_plugin plugin %}{% endwith %} 9 | {% endfor %} 10 |
11 | -------------------------------------------------------------------------------- /aldryn_bootstrap3/templates/aldryn_bootstrap3/plugins/list_group_item.html: -------------------------------------------------------------------------------- 1 | {% load cms_tags %} 2 | 3 |
8 | 9 | {% if instance.title %} 10 |

{{ instance.title }}

11 | {% endif %} 12 | 13 | {% for plugin in item.child_plugin_instances %} 14 | {% render_plugin plugin %} 15 | {% endfor %} 16 |
17 | -------------------------------------------------------------------------------- /aldryn_bootstrap3/templates/aldryn_bootstrap3/plugins/panel.html: -------------------------------------------------------------------------------- 1 | {% load cms_tags %} 2 | 3 |
7 | 8 | {% for plugin in instance.child_plugin_instances %} 9 | {% render_plugin plugin %} 10 | {% endfor %} 11 |
12 | -------------------------------------------------------------------------------- /aldryn_bootstrap3/templates/aldryn_bootstrap3/plugins/panel_body.html: -------------------------------------------------------------------------------- 1 | {% load cms_tags %} 2 | 3 |
6 | 7 | {% for plugin in instance.child_plugin_instances %} 8 | {% render_plugin plugin %} 9 | {% endfor %} 10 |
11 | -------------------------------------------------------------------------------- /aldryn_bootstrap3/templates/aldryn_bootstrap3/plugins/panel_footer.html: -------------------------------------------------------------------------------- 1 | {% load cms_tags %} 2 | 3 | 11 | -------------------------------------------------------------------------------- /aldryn_bootstrap3/templates/aldryn_bootstrap3/plugins/panel_heading.html: -------------------------------------------------------------------------------- 1 | {% load cms_tags %} 2 | 3 |
6 | 7 | {% if instance.title %} 8 |

{{ instance.title }}

9 | {% endif %} 10 | 11 | {% for plugin in instance.child_plugin_instances %} 12 | {% render_plugin plugin %} 13 | {% endfor %} 14 |
15 | -------------------------------------------------------------------------------- /aldryn_bootstrap3/templates/aldryn_bootstrap3/plugins/responsive.html: -------------------------------------------------------------------------------- 1 | {% load cms_tags %}
5 | {% for plugin in instance.child_plugin_instances %} 6 | {% render_plugin plugin %} 7 | {% endfor %} 8 |
-------------------------------------------------------------------------------- /aldryn_bootstrap3/templates/aldryn_bootstrap3/plugins/row.html: -------------------------------------------------------------------------------- 1 | {% load cms_tags %} 2 | 3 |
6 | 7 | {% for plugin in instance.child_plugin_instances %} 8 | {% with forloop as parentloop %}{% render_plugin plugin %}{% endwith %} 9 | {% endfor %} 10 |
11 | -------------------------------------------------------------------------------- /aldryn_bootstrap3/templates/aldryn_bootstrap3/plugins/spacer.html: -------------------------------------------------------------------------------- 1 |
5 | -------------------------------------------------------------------------------- /aldryn_bootstrap3/templates/aldryn_bootstrap3/plugins/tab.html: -------------------------------------------------------------------------------- 1 | {% load cms_tags %} 2 | 3 |
6 | 7 | 19 | 20 |
21 | {% for plugin in instance.child_plugin_instances %} 22 | {% render_plugin plugin %} 23 | {% endfor %} 24 |
25 |
26 | -------------------------------------------------------------------------------- /aldryn_bootstrap3/templates/aldryn_bootstrap3/plugins/tab_item.html: -------------------------------------------------------------------------------- 1 | {% load cms_tags %} 2 | 3 |
10 | 11 | {% for plugin in instance.child_plugin_instances %} 12 | {% render_plugin plugin %} 13 | {% endfor %} 14 |
15 | -------------------------------------------------------------------------------- /aldryn_bootstrap3/templates/aldryn_bootstrap3/plugins/well.html: -------------------------------------------------------------------------------- 1 | {% load cms_tags %} 2 | 3 |
7 | 8 | {% for plugin in instance.child_plugin_instances %} 9 | {% render_plugin plugin %} 10 | {% endfor %} 11 |
12 | -------------------------------------------------------------------------------- /aldryn_bootstrap3/templatetags/__init__.py: -------------------------------------------------------------------------------- 1 | # -*- coding: utf-8 -*- 2 | -------------------------------------------------------------------------------- /aldryn_bootstrap3/templatetags/aldryn_bootstrap3_tags.py: -------------------------------------------------------------------------------- 1 | # -*- coding: utf-8 -*- 2 | from __future__ import unicode_literals, absolute_import 3 | 4 | from django import template 5 | from django.template.defaultfilters import stringfilter 6 | 7 | 8 | register = template.Library() 9 | 10 | 11 | @register.filter(name='iconset_from_class') 12 | @stringfilter 13 | def iconset_from_class(value): 14 | """ 15 | extracts the iconset from a class definition 16 | "fa-flask" -> "fa" 17 | :param value: 18 | :return: 19 | """ 20 | if '-' in value: 21 | return value.split('-')[0] 22 | return '' 23 | -------------------------------------------------------------------------------- /aldryn_bootstrap3/widgets.py: -------------------------------------------------------------------------------- 1 | # -*- coding: utf-8 -*- 2 | from __future__ import unicode_literals, absolute_import 3 | 4 | import django.forms.widgets 5 | from django.template.loader import render_to_string 6 | 7 | from .conf import settings 8 | 9 | 10 | class SelectFieldCompatMixin(object): 11 | """ 12 | This class is only needed for Django < 1.11 compatibility 13 | """ 14 | 15 | @property 16 | def renderer(self): 17 | class Renderer(django.forms.widgets.RadioFieldRenderer): 18 | template_name = self.template_name 19 | 20 | def render(self): 21 | return render_to_string(self.template_name, {'selects': self}) 22 | return Renderer 23 | 24 | 25 | class Context(SelectFieldCompatMixin, django.forms.widgets.RadioSelect): 26 | template_name = 'admin/aldryn_bootstrap3/widgets/context.html' 27 | 28 | 29 | class Size(SelectFieldCompatMixin, django.forms.widgets.RadioSelect): 30 | template_name = 'admin/aldryn_bootstrap3/widgets/size.html' 31 | 32 | 33 | class LinkOrButton(SelectFieldCompatMixin, django.forms.widgets.RadioSelect): 34 | template_name = 'admin/aldryn_bootstrap3/widgets/link_or_button.html' 35 | 36 | 37 | class Icon(django.forms.widgets.TextInput): 38 | def render(self, name, value, attrs=None, **kwargs): 39 | input_html = super(Icon, self).render(name, value, attrs=attrs, **kwargs) 40 | if value is None: 41 | value = '' 42 | iconset = value.split('-')[0] if value and '-' in value else '' 43 | iconset_prefexes = [s[1] for s in settings.ALDRYN_BOOTSTRAP3_ICONSETS] 44 | if len(settings.ALDRYN_BOOTSTRAP3_ICONSETS) and iconset not in iconset_prefexes: 45 | # invalid iconset! maybe because the iconset was removed from 46 | # the project. set it to the first in the list. 47 | iconset = settings.ALDRYN_BOOTSTRAP3_ICONSETS[0][1] 48 | rendered = render_to_string( 49 | 'admin/aldryn_bootstrap3/widgets/icon.html', 50 | { 51 | 'input_html': input_html, 52 | 'value': value, 53 | 'name': name, 54 | 'iconset': iconset, 55 | 'is_required': self.is_required, 56 | 'iconsets': settings.ALDRYN_BOOTSTRAP3_ICONSETS, 57 | }, 58 | ) 59 | return rendered 60 | 61 | 62 | class MiniTextarea(django.forms.widgets.Textarea): 63 | def __init__(self, attrs=None): 64 | if attrs is None: 65 | attrs = {} 66 | attrs['cols'] = '120' 67 | attrs['rows'] = '1' 68 | super(MiniTextarea, self).__init__(attrs) 69 | 70 | 71 | class Responsive(django.forms.widgets.Textarea): 72 | def render(self, name, value, attrs=None): 73 | widget_html = super(Responsive, self).render(name=name, value=value, attrs=attrs) 74 | 75 | rendered = render_to_string( 76 | 'admin/aldryn_bootstrap3/widgets/responsive.html', 77 | { 78 | 'widget_html': widget_html, 79 | 'widget': self, 80 | 'value': value, 81 | 'name': name, 82 | 'id': attrs.get('id', None), 83 | 'attrs': attrs, 84 | }, 85 | ) 86 | return rendered 87 | 88 | 89 | class ResponsivePrint(django.forms.widgets.Textarea): 90 | def render(self, name, value, attrs=None): 91 | widget_html = super(ResponsivePrint, self).render( 92 | name=name, value=value, attrs=attrs) 93 | 94 | rendered = render_to_string( 95 | 'admin/aldryn_bootstrap3/widgets/responsive_print.html', 96 | { 97 | 'widget_html': widget_html, 98 | 'widget': self, 99 | 'value': value, 100 | 'name': name, 101 | 'id': attrs.get('id', None), 102 | 'attrs': attrs, 103 | }, 104 | ) 105 | return rendered 106 | -------------------------------------------------------------------------------- /aldryn_config.py: -------------------------------------------------------------------------------- 1 | # -*- coding: utf-8 -*- 2 | from aldryn_client import forms 3 | 4 | 5 | def split_and_strip(string): 6 | return [item.strip() for item in string.split(',') if item] 7 | 8 | 9 | class Form(forms.BaseForm): 10 | grid_size = forms.NumberField( 11 | 'Maximum columns to support', 12 | required=False 13 | ) 14 | enable_glyphicons = forms.CheckboxField( 15 | 'Enable Glyphicons', 16 | required=False, 17 | initial=True, 18 | help_text='If you disable this, remember to also update your sass config to not load the font.', 19 | ) 20 | enable_fontawesome = forms.CheckboxField( 21 | 'Enable Fontawesome', 22 | required=False, 23 | initial=True, 24 | help_text='If you disable this, remember to also update your sass config to not load the font.', 25 | ) 26 | carousel_styles = forms.CharField( 27 | 'List of additional carousel styles (comma separated)', 28 | required=False 29 | ) 30 | 31 | def clean(self): 32 | data = super(Form, self).clean() 33 | 34 | # older versions of this addon had a bug where the values would be 35 | # saved to settings.json as a list instead of a string. 36 | if isinstance(data['carousel_styles'], list): 37 | data['carousel_styles'] = ', '.join(data['carousel_styles']) 38 | 39 | # prettify 40 | data['carousel_styles'] = ', '.join(split_and_strip(data['carousel_styles'])) 41 | return data 42 | 43 | def to_settings(self, data, settings): 44 | choices = [] 45 | if data['grid_size']: 46 | settings['ALDRYN_BOOTSTRAP3_GRID_SIZE'] = int(data['grid_size']) 47 | if data['enable_glyphicons']: 48 | choices.append( 49 | ('glyphicons', 'glyphicons', 'Glyphicons') 50 | ) 51 | if data['enable_fontawesome']: 52 | choices.append( 53 | ('fontawesome', 'fa', 'Font Awesome') 54 | ) 55 | if choices: 56 | settings['ALDRYN_BOOTSTRAP3_ICONSETS'] = choices 57 | 58 | if data['carousel_styles']: 59 | settings['ALDRYN_BOOTSTRAP3_CAROUSEL_STYLES'] = [ 60 | (item, item) 61 | for item in split_and_strip(data['carousel_styles']) 62 | ] 63 | 64 | return settings 65 | -------------------------------------------------------------------------------- /preview.gif: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/divio/aldryn-bootstrap3/bb80aaf6cbe9339718b4240e45907ac61bc0781a/preview.gif -------------------------------------------------------------------------------- /setup.py: -------------------------------------------------------------------------------- 1 | #!/usr/bin/env python 2 | # -*- coding: utf-8 -*- 3 | from setuptools import find_packages, setup 4 | 5 | from aldryn_bootstrap3 import __version__ 6 | 7 | 8 | REQUIREMENTS = [ 9 | 'django-appconf>=1.0.0', 10 | 'django-cms>=3.3.0', 11 | 'django-filer>=0.9.11', 12 | 'djangocms-text-ckeditor>=3.1.0', 13 | 'djangocms-attributes-field>=0.1.1', 14 | ] 15 | 16 | 17 | CLASSIFIERS = [ 18 | 'Development Status :: 5 - Production/Stable', 19 | 'Environment :: Web Environment', 20 | 'Framework :: Django', 21 | 'Intended Audience :: Developers', 22 | 'License :: OSI Approved :: BSD License', 23 | 'Operating System :: OS Independent', 24 | 'Programming Language :: Python', 25 | 'Programming Language :: Python :: 2', 26 | 'Programming Language :: Python :: 2.7', 27 | 'Programming Language :: Python :: 3', 28 | 'Programming Language :: Python :: 3.4', 29 | 'Programming Language :: Python :: 3.5', 30 | 'Topic :: Internet :: WWW/HTTP', 31 | 'Topic :: Internet :: WWW/HTTP :: Dynamic Content', 32 | 'Topic :: Software Development :: Libraries :: Application Frameworks', 33 | 'Topic :: Software Development :: Libraries :: Python Modules', 34 | ] 35 | 36 | 37 | setup( 38 | name='aldryn-bootstrap3', 39 | version=__version__, 40 | author='Divio AG', 41 | author_email='info@divio.ch', 42 | url='https://github.com/aldryn/aldryn-bootstrap3', 43 | license='BSD', 44 | description=('Adds Bootstrap 3 components as plugins.'), 45 | long_description=open('README.rst').read(), 46 | packages=find_packages(), 47 | include_package_data=True, 48 | zip_safe=False, 49 | install_requires=REQUIREMENTS, 50 | classifiers=CLASSIFIERS, 51 | test_suite='tests.settings.run', 52 | ) 53 | -------------------------------------------------------------------------------- /tests/__init__.py: -------------------------------------------------------------------------------- 1 | # -*- coding: utf-8 -*- 2 | -------------------------------------------------------------------------------- /tests/requirements.txt: -------------------------------------------------------------------------------- 1 | # requirements from setup.py 2 | djangocms-text-ckeditor 3 | # other requirements 4 | djangocms-helper>=0.9.2,<0.10 5 | tox 6 | coverage 7 | -------------------------------------------------------------------------------- /tests/settings.py: -------------------------------------------------------------------------------- 1 | #!/usr/bin/env python 2 | # -*- coding: utf-8 -*- 3 | 4 | HELPER_SETTINGS = { 5 | 'INSTALLED_APPS': [ 6 | 'easy_thumbnails', 7 | 'filer', 8 | 'mptt', 9 | 'djangocms_text_ckeditor', 10 | ], 11 | 'ALLOWED_HOSTS': ['localhost'], 12 | 'CMS_LANGUAGES': { 13 | 1: [{ 14 | 'code': 'en', 15 | 'name': 'English', 16 | }] 17 | }, 18 | 'LANGUAGE_CODE': 'en', 19 | } 20 | 21 | def run(): 22 | from djangocms_helper import runner 23 | runner.cms('aldryn_bootstrap3') 24 | 25 | if __name__ == '__main__': 26 | run() 27 | -------------------------------------------------------------------------------- /tests/tests_models.py: -------------------------------------------------------------------------------- 1 | # -*- coding: utf-8 -*- 2 | from django.test import TestCase 3 | 4 | from aldryn_bootstrap3.models import Boostrap3ButtonPlugin 5 | 6 | 7 | class Boostrap3ButtonPluginTestCase(TestCase): 8 | 9 | def setUp(self): 10 | Boostrap3ButtonPlugin.objects.create( 11 | label='test', 12 | ) 13 | 14 | def test_bootstrap3_button_instance(self): 15 | """Button instance has been created""" 16 | button = Boostrap3ButtonPlugin.objects.get(label='test') 17 | self.assertEqual(button.label, 'test') 18 | -------------------------------------------------------------------------------- /tox.ini: -------------------------------------------------------------------------------- 1 | [tox] 2 | envlist = 3 | flake8 4 | py{34,27}-latest 5 | py{34,27}-dj18-cms{34,33} 6 | py{34,27}-dj19-cms{34,33} 7 | 8 | skip_missing_interpreters=True 9 | 10 | 11 | [testenv] 12 | deps = 13 | -r{toxinidir}/tests/requirements.txt 14 | dj18: Django>=1.8,<1.9 15 | dj19: Django>=1.9,<1.10 16 | latest: django-cms 17 | cms33: django-cms>=3.3,<3.4 18 | cms34: django-cms>=3.4,<3.5 19 | commands = 20 | {envpython} --version 21 | {env:COMMAND:coverage} erase 22 | {env:COMMAND:coverage} run setup.py test 23 | {env:COMMAND:coverage} report 24 | 25 | [flake8] 26 | max-line-length = 120 27 | exclude = */docs/*,*/migrations/* 28 | --------------------------------------------------------------------------------