diff options
author | Evgeny Fadeev <evgeny.fadeev@gmail.com> | 2012-05-16 18:25:08 -0400 |
---|---|---|
committer | Evgeny Fadeev <evgeny.fadeev@gmail.com> | 2012-05-16 18:25:08 -0400 |
commit | b96aa66f7a2dceb9d86e8e2f35e9d42b7959b46c (patch) | |
tree | 0dc07e85746a3646c1d5608c48e1b5130668d988 | |
parent | bb5372083338f1502c8537504167194709e2b6f6 (diff) | |
parent | cbebe08a0cc993693a7a90cbd1ddc82bb89c4194 (diff) | |
download | askbot-b96aa66f7a2dceb9d86e8e2f35e9d42b7959b46c.tar.gz askbot-b96aa66f7a2dceb9d86e8e2f35e9d42b7959b46c.tar.bz2 askbot-b96aa66f7a2dceb9d86e8e2f35e9d42b7959b46c.zip |
Merge branch 'user-groups' into tag-editor
37 files changed, 890 insertions, 336 deletions
@@ -47,3 +47,4 @@ run recaptcha /.ve /db.sq3 +*.DS_Store diff --git a/askbot/__init__.py b/askbot/__init__.py index 12517182..859b2695 100644 --- a/askbot/__init__.py +++ b/askbot/__init__.py @@ -9,7 +9,7 @@ import smtplib import sys import logging -VERSION = (0, 7, 42) +VERSION = (0, 7, 43) #keys are module names used by python imports, #values - the package qualifier to use for pip diff --git a/askbot/askbot b/askbot/askbot new file mode 100644 index 00000000..e69de29b --- /dev/null +++ b/askbot/askbot diff --git a/askbot/conf/settings_wrapper.py b/askbot/conf/settings_wrapper.py index 78d16397..b6b5f302 100644 --- a/askbot/conf/settings_wrapper.py +++ b/askbot/conf/settings_wrapper.py @@ -58,8 +58,14 @@ class ConfigSettings(object): self.update(key, self.get_default(key)) def update(self, key, value): - setting = config_get(self.__group_map[key], key) - setting.update(value) + try: + setting = config_get(self.__group_map[key], key) + setting.update(value) + except: + from askbot.deps.livesettings.models import Setting + setting = Setting.objects.get(key=key) + setting.value = value + setting.save() #self.prime_cache() def register(self, value): diff --git a/askbot/conf/site_modes.py b/askbot/conf/site_modes.py index a88103b4..efbbcca0 100644 --- a/askbot/conf/site_modes.py +++ b/askbot/conf/site_modes.py @@ -76,9 +76,9 @@ settings.register( "Bootstrap mode lowers reputation and certain badge " "thresholds, to values, more suitable " "for the smaller communities, " - "<strong>WARNING:</strong> your current value for " + "<strong>WARNING:</strong> your current values for " "Minimum reputation, " - "Bagde Settings and " + "Badge Settings and " "Vote Rules will " "be changed after you modify this setting." ), diff --git a/askbot/conf/skin_general_settings.py b/askbot/conf/skin_general_settings.py index d81c984b..323550ce 100644 --- a/askbot/conf/skin_general_settings.py +++ b/askbot/conf/skin_general_settings.py @@ -30,6 +30,42 @@ settings.register( ) ) +LANGUAGE_CHOICES = ( + ('en', _("English")), + ('es', _("Spanish")), + ('ca', _("Catalan")), + ('de', _("German")), + ('el', _("Greek")), + ('fi', _("Finnish")), + ('fr', _("French")), + ('hi', _("Hindi")), + ('hu', _("Hungarian")), + ('it', _("Italian")), + ('ja', _("Japanese")), + ('ko', _("Korean")), + ('pt', _("Portuguese")), + ('pt_BR', _("Brazilian Portuguese")), + ('ro', _("Romanian")), + ('ru', _("Russian")), + ('sr', _("Serbian")), + ('tr', _("Turkish")), + ('vi', _("Vietnamese")), + ('zh_CN', _("Chinese")), + ('zh_TW', _("Chinese (Taiwan)")), + ) + +""" +settings.register( + values.StringValue( + GENERAL_SKIN_SETTINGS, + 'ASKBOT_LANGUAGE', + default = 'en', + choices = LANGUAGE_CHOICES, + description = _('Select Language'), + ) +) +""" + settings.register( values.BooleanValue( GENERAL_SKIN_SETTINGS, @@ -198,7 +234,7 @@ settings.register( description = _('Apply custom style sheet (CSS)'), help_text = _( 'Check if you want to change appearance ' - 'of your form by adding custom style sheet rules ' + 'of your form by adding custom style sheet rules ' '(please see the next item)' ), default = False @@ -214,7 +250,7 @@ settings.register( '<strong>To use this function</strong>, check ' '"Apply custom style sheet" option above. ' 'The CSS rules added in this window will be applied ' - 'after the default style sheet rules. ' + 'after the default style sheet rules. ' 'The custom style sheet will be served dynamically at ' 'url "<forum url>/custom.css", where ' 'the "<forum url> part depends (default is ' diff --git a/askbot/context.py b/askbot/context.py index ea10a890..03a2d1d8 100644 --- a/askbot/context.py +++ b/askbot/context.py @@ -26,7 +26,16 @@ def application_settings(request): my_settings['LANGUAGE_CODE'] = getattr(request, 'LANGUAGE_CODE', settings.LANGUAGE_CODE) my_settings['ASKBOT_URL'] = settings.ASKBOT_URL my_settings['STATIC_URL'] = settings.STATIC_URL - my_settings['ASKBOT_CSS_DEVEL'] = getattr(settings, 'ASKBOT_CSS_DEVEL', False) + my_settings['ASKBOT_CSS_DEVEL'] = getattr( + settings, + 'ASKBOT_CSS_DEVEL', + False + ) + my_settings['USE_LOCAL_FONTS'] = getattr( + settings, + 'ASKBOT_USE_LOCAL_FONTS', + False + ) my_settings['DEBUG'] = settings.DEBUG my_settings['USING_RUNSERVER'] = 'runserver' in sys.argv my_settings['ASKBOT_VERSION'] = askbot.get_version() diff --git a/askbot/cron/askbot_cron_job b/askbot/cron/askbot_cron_job index 38bf0337..04ba2303 100644 --- a/askbot/cron/askbot_cron_job +++ b/askbot/cron/askbot_cron_job @@ -9,7 +9,7 @@ PROJECT_PARENT_DIR=/path/to/dir_containing_askbot_site PROJECT_DIR_NAME=askbot_site export PYTHONPATH=$PROJECT_PARENT_DIR:$PYTHONPATH -PROJECT_ROOT=$PYTHONPATH/$PROJECT_NAME +PROJECT_ROOT=$PROJECT_DIR_NAME/$PROJECT_NAME #these are actual commands that are to be run python $PROJECT_ROOT/manage.py send_email_alerts diff --git a/askbot/doc/source/changelog.rst b/askbot/doc/source/changelog.rst index 25d96e88..e005e019 100644 --- a/askbot/doc/source/changelog.rst +++ b/askbot/doc/source/changelog.rst @@ -1,13 +1,15 @@ Changes in Askbot ================= -Future version --------------- +0.7.43 (May 14, 2012) +--------------------- * User groups (Evgeny) * Public/Private/Hidden reputation (Evgeny) * Enabling/disabling the badges system (Evgeny) * Created a basic post moderation feature (Evgeny) * Created a way to specify reasons for rejecting posts in a modal dialog (Evgeny) +* A number of bug fixes (Adolfo Fitoria, Jim Tittsler, + Evgeny Fadeev, Robin Stocker, Radim Řehůřek, Silvio Heuberger) 0.7.41, 0.7.42 (April 21, 2012) ------------------------------- diff --git a/askbot/doc/source/contributors.rst b/askbot/doc/source/contributors.rst index 71bc5cc9..81729979 100644 --- a/askbot/doc/source/contributors.rst +++ b/askbot/doc/source/contributors.rst @@ -38,6 +38,7 @@ Programming and documentation * `Radim Řehůřek <https://github.com/piskvorky>`_ * `monkut <https://github.com/monkut>`_ * `Jim Tittsler <http://wikieducator.org/User:JimTittsler>`_ +* Silvio Heuberger Translations ------------ diff --git a/askbot/doc/source/index.rst b/askbot/doc/source/index.rst index 81f21fcc..353b9105 100644 --- a/askbot/doc/source/index.rst +++ b/askbot/doc/source/index.rst @@ -26,6 +26,7 @@ at the forum_ or by email at admin@askbot.org Appendix C: Optional modules <optional-modules> Appendix D: Askbot as reusable Django application <askbot-as-reusable-django-application> Appendix E: Customizing skin in askbot <customizing-skin-in-askbot> + Appendix F: Intranet setup <intranet-setup> Footnotes <footnotes> Contributors <contributors> Changelog<changelog> diff --git a/askbot/doc/source/intranet-setup.rst b/askbot/doc/source/intranet-setup.rst new file mode 100644 index 00000000..224ffb89 --- /dev/null +++ b/askbot/doc/source/intranet-setup.rst @@ -0,0 +1,14 @@ +========================================================== +Setting up Askbot for use on the closed network (Intranet) +========================================================== + +When using Askbot on the Intranet (for example - within your +Company network), it will be useful to disable references to +all external resources - such as custom fonts, gravatars. + +Please change the following settings in your ``settings.py`` file:: + + ASKBOT_USE_LOCAL_FONTS=True + +In addition, in the "live settings": +* disable gravatar in "settings->User settings" diff --git a/askbot/feed.py b/askbot/feed.py index c1933afe..776aad5e 100644 --- a/askbot/feed.py +++ b/askbot/feed.py @@ -25,20 +25,29 @@ from askbot.conf import settings as askbot_settings class RssIndividualQuestionFeed(Feed): """rss feed class for particular questions """ - title = askbot_settings.APP_TITLE + _(' - ')+ _('Individual question feed') - link = askbot_settings.APP_URL - description = askbot_settings.APP_DESCRIPTION - copyright = askbot_settings.APP_COPYRIGHT + + def title(self): + return askbot_settings.APP_TITLE + _(' - ') + \ + _('Individual question feed') + + def feed_copyright(self): + return askbot_settings.APP_COPYRIGHT + + def description(self): + return askbot_settings.APP_DESCRIPTION def get_object(self, bits): if len(bits) != 1: raise ObjectDoesNotExist return Post.objects.get_questions().get(id__exact = bits[0]) - + def item_link(self, item): """get full url to the item """ - return self.link + item.get_absolute_url() + return askbot_settings.APP_URL + item.get_absolute_url() + + def link(self): + return askbot_settings.APP_URL def item_pubdate(self, item): """get date of creation for the item @@ -56,7 +65,7 @@ class RssIndividualQuestionFeed(Feed): chain_elements.append( Post.objects.get_comments().filter(parent=item) ) - + answers = Post.objects.get_answers().filter(thread = item.thread) for answer in answers: chain_elements.append([answer,]) @@ -65,7 +74,7 @@ class RssIndividualQuestionFeed(Feed): ) return itertools.chain(*chain_elements) - + def item_title(self, item): """returns the title for the item """ @@ -77,7 +86,7 @@ class RssIndividualQuestionFeed(Feed): elif item.post_type == "comment": title = "Comment by %s for %s" % (item.author, self.title) return title - + def item_description(self, item): """returns the description for the item """ @@ -87,16 +96,24 @@ class RssIndividualQuestionFeed(Feed): class RssLastestQuestionsFeed(Feed): """rss feed class for the latest questions """ - title = askbot_settings.APP_TITLE + _(' - ')+ _('latest questions') - link = askbot_settings.APP_URL - description = askbot_settings.APP_DESCRIPTION - #ttl = 10 - copyright = askbot_settings.APP_COPYRIGHT + + def title(self): + return askbot_settings.APP_TITLE + _(' - ') + \ + _('Individual question feed') + + def feed_copyright(self): + return askbot_settings.APP_COPYRIGHT + + def description(self): + return askbot_settings.APP_DESCRIPTION def item_link(self, item): """get full url to the item """ - return self.link + item.get_absolute_url() + return askbot_settings.APP_URL + item.get_absolute_url() + + def link(self): + return askbot_settings.APP_URL def item_author_name(self, item): """get name of author @@ -117,10 +134,10 @@ class RssLastestQuestionsFeed(Feed): """returns url without the slug because the slug can change """ - return self.link + item.get_absolute_url(no_slug = True) - + return askbot_settings.APP_URL + item.get_absolute_url(no_slug = True) + def item_description(self, item): - """returns the desciption for the item + """returns the description for the item """ return item.text @@ -142,12 +159,12 @@ class RssLastestQuestionsFeed(Feed): if tags: #if there are tags in GET, filter the #questions additionally - for tag in tags: + for tag in tags: qs = qs.filter(thread__tags__name = tag) - + return qs.order_by('-thread__last_activity_at')[:30] - + def main(): """main function for use as a script diff --git a/askbot/management/commands/send_email_alerts.py b/askbot/management/commands/send_email_alerts.py index 218bd9a9..b7624e21 100644 --- a/askbot/management/commands/send_email_alerts.py +++ b/askbot/management/commands/send_email_alerts.py @@ -475,7 +475,7 @@ class Command(NoArgsCommand): text += _( '<p>Please remember that you can always <a ' - 'hrefl"%(email_settings_link)s">adjust</a> frequency of the email updates or ' + 'href="%(email_settings_link)s">adjust</a> frequency of the email updates or ' 'turn them off entirely.<br/>If you believe that this message was sent in an ' 'error, please email about it the forum administrator at %(admin_email)s.</' 'p><p>Sincerely,</p><p>Your friendly %(sitename)s server.</p>' diff --git a/askbot/middleware/locale.py b/askbot/middleware/locale.py new file mode 100644 index 00000000..c92e977a --- /dev/null +++ b/askbot/middleware/locale.py @@ -0,0 +1,26 @@ +"Taken from django.middleware.locale: this is the locale selecting middleware that will look at accept headers" + +from django.utils.cache import patch_vary_headers +from django.utils import translation +from askbot.conf import settings + +class LocaleMiddleware(object): + """ + This is a very simple middleware that parses a request + and decides what translation object to install in the current + thread context. This allows pages to be dynamically + translated to the language the user desires (if the language + is available, of course). + """ + + def process_request(self, request): + language = settings.ASKBOT_LANGUAGE + translation.activate(language) + request.LANGUAGE_CODE = translation.get_language() + + def process_response(self, request, response): + patch_vary_headers(response, ('Accept-Language',)) + if 'Content-Language' not in response: + response['Content-Language'] = translation.get_language() + translation.deactivate() + return response diff --git a/askbot/migrations/0032_auto__del_field_badgedata_multiple__del_field_badgedata_description__d.py b/askbot/migrations/0032_auto__del_field_badgedata_multiple__del_field_badgedata_description__d.py index d26bdeb0..70ef2f8d 100644 --- a/askbot/migrations/0032_auto__del_field_badgedata_multiple__del_field_badgedata_description__d.py +++ b/askbot/migrations/0032_auto__del_field_badgedata_multiple__del_field_badgedata_description__d.py @@ -5,7 +5,7 @@ from south.v2 import SchemaMigration from django.db import models class Migration(SchemaMigration): - + def forwards(self, orm): # Removing unique constraint on 'BadgeData', fields ['type', 'name'] @@ -34,10 +34,10 @@ class Migration(SchemaMigration): except: db.rollback_transaction() - - + + def backwards(self, orm): - + # Adding field 'BadgeData.multiple' db.add_column('askbot_badgedata', 'multiple', self.gf('django.db.models.fields.BooleanField')(default=False, blank=True), keep_default=False) @@ -55,8 +55,8 @@ class Migration(SchemaMigration): # Removing unique constraint on 'BadgeData', fields ['slug'] db.delete_unique('askbot_badgedata', ['slug']) - - + + models = { 'askbot.activity': { 'Meta': {'object_name': 'Activity', 'db_table': "u'activity'"}, @@ -335,5 +335,5 @@ class Migration(SchemaMigration): 'name': ('django.db.models.fields.CharField', [], {'max_length': '100'}) } } - + complete_apps = ['askbot'] diff --git a/askbot/setup_templates/settings.py b/askbot/setup_templates/settings.py index 191d13f3..32af9920 100644 --- a/askbot/setup_templates/settings.py +++ b/askbot/setup_templates/settings.py @@ -98,6 +98,7 @@ TEMPLATE_LOADERS = ( MIDDLEWARE_CLASSES = ( #'django.middleware.gzip.GZipMiddleware', + #'askbot.middleware.locale.LocaleMiddleware', 'django.contrib.sessions.middleware.SessionMiddleware', #'django.middleware.cache.UpdateCacheMiddleware', 'django.middleware.common.CommonMiddleware', diff --git a/askbot/setup_templates/settings.py.mustache b/askbot/setup_templates/settings.py.mustache index 3287fb18..eb1cb1c1 100644 --- a/askbot/setup_templates/settings.py.mustache +++ b/askbot/setup_templates/settings.py.mustache @@ -97,6 +97,7 @@ TEMPLATE_LOADERS = ( MIDDLEWARE_CLASSES = ( #'django.middleware.gzip.GZipMiddleware', + 'askbot.middleware.locale.LocaleMiddleware', 'django.contrib.sessions.middleware.SessionMiddleware', #'django.middleware.cache.UpdateCacheMiddleware', 'django.middleware.common.CommonMiddleware', diff --git a/askbot/skins/default/media/bootstrap/css/bootstrap.css b/askbot/skins/default/media/bootstrap/css/bootstrap.css index 9447a9a2..3e829732 100644 --- a/askbot/skins/default/media/bootstrap/css/bootstrap.css +++ b/askbot/skins/default/media/bootstrap/css/bootstrap.css @@ -918,18 +918,6 @@ input, textarea, select, .uneditable-input { - display: inline-block; - width: 210px; - height: 18px; - padding: 4px; - margin-bottom: 9px; - font-size: 13px; - line-height: 18px; - color: #555555; - border: 1px solid #cccccc; - -webkit-border-radius: 3px; - -moz-border-radius: 3px; - border-radius: 3px; } .uneditable-textarea { width: auto; diff --git a/askbot/skins/default/media/images/OFL.txt b/askbot/skins/default/media/images/OFL.txt new file mode 100644 index 00000000..3bc11311 --- /dev/null +++ b/askbot/skins/default/media/images/OFL.txt @@ -0,0 +1,93 @@ +Copyright (c) 2010, Jan Gerner (post@yanone.de)
+
+This Font Software is licensed under the SIL Open Font License, Version 1.1.
+This license is copied below, and is also available with a FAQ at:
+http://scripts.sil.org/OFL
+
+
+-----------------------------------------------------------
+SIL OPEN FONT LICENSE Version 1.1 - 26 February 2007
+-----------------------------------------------------------
+
+PREAMBLE
+The goals of the Open Font License (OFL) are to stimulate worldwide
+development of collaborative font projects, to support the font creation
+efforts of academic and linguistic communities, and to provide a free and
+open framework in which fonts may be shared and improved in partnership
+with others.
+
+The OFL allows the licensed fonts to be used, studied, modified and
+redistributed freely as long as they are not sold by themselves. The
+fonts, including any derivative works, can be bundled, embedded,
+redistributed and/or sold with any software provided that any reserved
+names are not used by derivative works. The fonts and derivatives,
+however, cannot be released under any other type of license. The
+requirement for fonts to remain under this license does not apply
+to any document created using the fonts or their derivatives.
+
+DEFINITIONS
+"Font Software" refers to the set of files released by the Copyright
+Holder(s) under this license and clearly marked as such. This may
+include source files, build scripts and documentation.
+
+"Reserved Font Name" refers to any names specified as such after the
+copyright statement(s).
+
+"Original Version" refers to the collection of Font Software components as
+distributed by the Copyright Holder(s).
+
+"Modified Version" refers to any derivative made by adding to, deleting,
+or substituting -- in part or in whole -- any of the components of the
+Original Version, by changing formats or by porting the Font Software to a
+new environment.
+
+"Author" refers to any designer, engineer, programmer, technical
+writer or other person who contributed to the Font Software.
+
+PERMISSION & CONDITIONS
+Permission is hereby granted, free of charge, to any person obtaining
+a copy of the Font Software, to use, study, copy, merge, embed, modify,
+redistribute, and sell modified and unmodified copies of the Font
+Software, subject to the following conditions:
+
+1) Neither the Font Software nor any of its individual components,
+in Original or Modified Versions, may be sold by itself.
+
+2) Original or Modified Versions of the Font Software may be bundled,
+redistributed and/or sold with any software, provided that each copy
+contains the above copyright notice and this license. These can be
+included either as stand-alone text files, human-readable headers or
+in the appropriate machine-readable metadata fields within text or
+binary files as long as those fields can be easily viewed by the user.
+
+3) No Modified Version of the Font Software may use the Reserved Font
+Name(s) unless explicit written permission is granted by the corresponding
+Copyright Holder. This restriction only applies to the primary font name as
+presented to the users.
+
+4) The name(s) of the Copyright Holder(s) or the Author(s) of the Font
+Software shall not be used to promote, endorse or advertise any
+Modified Version, except to acknowledge the contribution(s) of the
+Copyright Holder(s) and the Author(s) or with their explicit written
+permission.
+
+5) The Font Software, modified or unmodified, in part or in whole,
+must be distributed entirely under this license, and must not be
+distributed under any other license. The requirement for fonts to
+remain under this license does not apply to any document created
+using the Font Software.
+
+TERMINATION
+This license becomes null and void if any of the above conditions are
+not met.
+
+DISCLAIMER
+THE FONT SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND,
+EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO ANY WARRANTIES OF
+MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT
+OF COPYRIGHT, PATENT, TRADEMARK, OR OTHER RIGHT. IN NO EVENT SHALL THE
+COPYRIGHT HOLDER BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY,
+INCLUDING ANY GENERAL, SPECIAL, INDIRECT, INCIDENTAL, OR CONSEQUENTIAL
+DAMAGES, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING
+FROM, OUT OF THE USE OR INABILITY TO USE THE FONT SOFTWARE OR FROM
+OTHER DEALINGS IN THE FONT SOFTWARE.
diff --git a/askbot/skins/default/media/images/YanoneKaffeesatz-Bold.ttf b/askbot/skins/default/media/images/YanoneKaffeesatz-Bold.ttf Binary files differnew file mode 100644 index 00000000..c693c4b3 --- /dev/null +++ b/askbot/skins/default/media/images/YanoneKaffeesatz-Bold.ttf diff --git a/askbot/skins/default/media/images/YanoneKaffeesatz-ExtraLight.ttf b/askbot/skins/default/media/images/YanoneKaffeesatz-ExtraLight.ttf Binary files differnew file mode 100644 index 00000000..b59e4894 --- /dev/null +++ b/askbot/skins/default/media/images/YanoneKaffeesatz-ExtraLight.ttf diff --git a/askbot/skins/default/media/images/YanoneKaffeesatz-Light.ttf b/askbot/skins/default/media/images/YanoneKaffeesatz-Light.ttf Binary files differnew file mode 100644 index 00000000..5026d3bd --- /dev/null +++ b/askbot/skins/default/media/images/YanoneKaffeesatz-Light.ttf diff --git a/askbot/skins/default/media/images/YanoneKaffeesatz-Regular.ttf b/askbot/skins/default/media/images/YanoneKaffeesatz-Regular.ttf Binary files differnew file mode 100644 index 00000000..808ce0d0 --- /dev/null +++ b/askbot/skins/default/media/images/YanoneKaffeesatz-Regular.ttf diff --git a/askbot/skins/default/media/images/Yanone_Kaffeesatz.zip b/askbot/skins/default/media/images/Yanone_Kaffeesatz.zip Binary files differnew file mode 100644 index 00000000..55e9731a --- /dev/null +++ b/askbot/skins/default/media/images/Yanone_Kaffeesatz.zip diff --git a/askbot/skins/default/media/style/lib_style.css b/askbot/skins/default/media/style/lib_style.css new file mode 100644 index 00000000..a92af477 --- /dev/null +++ b/askbot/skins/default/media/style/lib_style.css @@ -0,0 +1,22 @@ +/* General Predifined classes, read more in lesscss.org */ +/* Variables for Colors*/ +/* Variables for fonts*/ +/* "Trebuchet MS", sans-serif;*/ +/* Buttons */ +.button-style-hover { + background-color: #cde5e9; + background-repeat: no-repeat; + background-image: -webkit-gradient(linear, 0 0, 0 100%, from(#cde5e9), color-stop(25%, #cde5e9), to(#94b3ba)); + background-image: -webkit-linear-gradient(#cde5e9, #cde5e9 25%, #94b3ba); + background-image: -moz-linear-gradient(top, #cde5e9, #cde5e9 25%, #94b3ba); + background-image: -ms-linear-gradient(#cde5e9, #cde5e9 25%, #94b3ba); + background-image: -o-linear-gradient(#cde5e9, #cde5e9 25%, #94b3ba); + background-image: linear-gradient(#cde5e9, #cde5e9 25%, #94b3ba); + text-decoration: none; + text-shadow: 0px 1px 0px #c6d9dd; + -moz-text-shadow: 0px 1px 0px #c6d9dd; + -webkit-text-shadow: 0px 1px 0px #c6d9dd; +} +/* General styles for gradients */ +/* Receive exactly positions for background Sprite */ +/* CSS3 Elements */ diff --git a/askbot/skins/default/media/style/lib_style.less b/askbot/skins/default/media/style/lib_style.less index 795733e5..63389526 100644 --- a/askbot/skins/default/media/style/lib_style.less +++ b/askbot/skins/default/media/style/lib_style.less @@ -17,6 +17,43 @@ @main-font:'Yanone Kaffeesatz', Arial, sans-serif; @secondary-font:Arial; +/* Buttons */ + +.button-style(@w:100px ,@h:20px, @f:14px){ + width:@w; + height:@h; + font-size:@f; + text-align:center; + text-decoration:none; + cursor:pointer; + color:@button-label; + font-family:@main-font; + .text-shadow(0px,1px,0px,#c6d9dd); + border-top:#eaf2f3 1px solid; + .linear-gradient(#d1e2e5,#a9c2c7); + .rounded-corners(4px); + .box-shadow(1px, 1px, 2px, #636363) +} + +.button-style-hover{ + .linear-gradient(#cde5e9,#94b3ba); + text-decoration:none; + .text-shadow(0px, 1px, 0px, #c6d9dd); +} + +/* General styles for gradients */ + +.linear-gradient(@start:#eee,@end:#fff,@stop:25%){ + background-color: @start; + background-repeat: no-repeat; + background-image: -webkit-gradient(linear, 0 0, 0 100%, from(@start), color-stop(@stop, @start), to(@end)); + background-image: -webkit-linear-gradient(@start, @start @stop, @end); + background-image: -moz-linear-gradient(top, @start, @start @stop, @end); + background-image: -ms-linear-gradient(@start, @start @stop, @end); + background-image: -o-linear-gradient(@start, @start @stop, @end); + background-image: linear-gradient(@start, @start @stop, @end); +} + /* Receive exactly positions for background Sprite */ .sprites(@hor,@vert,@back:url(../images/sprites.png)){ diff --git a/askbot/skins/default/media/style/style.css b/askbot/skins/default/media/style/style.css index 73664c57..3d53eba8 100644 --- a/askbot/skins/default/media/style/style.css +++ b/askbot/skins/default/media/style/style.css @@ -3,6 +3,22 @@ /* Variables for Colors*/ /* Variables for fonts*/ /* "Trebuchet MS", sans-serif;*/ +/* Buttons */ +.button-style-hover { + background-color: #cde5e9; + background-repeat: no-repeat; + background-image: -webkit-gradient(linear, 0 0, 0 100%, from(#cde5e9), color-stop(25%, #cde5e9), to(#94b3ba)); + background-image: -webkit-linear-gradient(#cde5e9, #cde5e9 25%, #94b3ba); + background-image: -moz-linear-gradient(top, #cde5e9, #cde5e9 25%, #94b3ba); + background-image: -ms-linear-gradient(#cde5e9, #cde5e9 25%, #94b3ba); + background-image: -o-linear-gradient(#cde5e9, #cde5e9 25%, #94b3ba); + background-image: linear-gradient(#cde5e9, #cde5e9 25%, #94b3ba); + text-decoration: none; + text-shadow: 0px 1px 0px #c6d9dd; + -moz-text-shadow: 0px 1px 0px #c6d9dd; + -webkit-text-shadow: 0px 1px 0px #c6d9dd; +} +/* General styles for gradients */ /* Receive exactly positions for background Sprite */ /* CSS3 Elements */ /* Library of predifined less functions styles */ @@ -148,7 +164,7 @@ a:hover { } h1 { font-size: 24px; - padding: 10px 0 5px 0px; + padding: 0px 0 5px 0px; } /* ----- Extra space above for messages ----- */ body.user-messages { @@ -179,7 +195,7 @@ body.user-messages { text-align: center; background-color: #f5dd69; border-top: #fff 1px solid; - font-family: 'Yanone Kaffeesatz', sans-serif; + font-family: 'Yanone Kaffeesatz', Arial, sans-serif; } .notify p.notification { margin-top: 6px; @@ -206,7 +222,7 @@ body.user-messages { #header { margin-top: 0px; background: #16160f; - font-family: 'Yanone Kaffeesatz', sans-serif; + font-family: 'Yanone Kaffeesatz', Arial, sans-serif; } .content-wrapper { /* wrapper positioning class */ @@ -295,6 +311,9 @@ body.user-messages { #metaNav #navUsers { background: -125px -5px url(../images/sprites.png) no-repeat; } +#metaNav #navGroups { + background: -125px -5px url(../images/sprites.png) no-repeat; +} #metaNav #navBadges { background: -210px -5px url(../images/sprites.png) no-repeat; } @@ -318,7 +337,7 @@ body.user-messages { border-bottom: #d3d3c2 1px solid; border-top: #fcfcfc 1px solid; margin-bottom: 10px; - font-family: 'Yanone Kaffeesatz', sans-serif; + font-family: 'Yanone Kaffeesatz', Arial, sans-serif; } #secondaryHeader #homeButton { border-right: #afaf9e 1px solid; @@ -427,28 +446,49 @@ body.anon #searchBar .searchInputCancelable { #askButton { /* check blocks/secondary_header.html and widgets/ask_button.html*/ - background: url(../images/bigbutton.png) repeat-x bottom; line-height: 44px; - text-align: center; + margin-top: 6px; + float: right; + text-transform: uppercase; width: 200px; height: 42px; font-size: 23px; + text-align: center; + text-decoration: none; + cursor: pointer; color: #4a757f; - margin-top: 7px; - float: right; - text-transform: uppercase; - border-radius: 5px; - -ms-border-radius: 5px; - -moz-border-radius: 5px; - -webkit-border-radius: 5px; - -khtml-border-radius: 5px; + font-family: 'Yanone Kaffeesatz', Arial, sans-serif; + text-shadow: 0px 1px 0px #c6d9dd; + -moz-text-shadow: 0px 1px 0px #c6d9dd; + -webkit-text-shadow: 0px 1px 0px #c6d9dd; + border-top: #eaf2f3 1px solid; + background-color: #d1e2e5; + background-repeat: no-repeat; + background-image: -webkit-gradient(linear, 0 0, 0 100%, from(#d1e2e5), color-stop(25%, #d1e2e5), to(#a9c2c7)); + background-image: -webkit-linear-gradient(#d1e2e5, #d1e2e5 25%, #a9c2c7); + background-image: -moz-linear-gradient(top, #d1e2e5, #d1e2e5 25%, #a9c2c7); + background-image: -ms-linear-gradient(#d1e2e5, #d1e2e5 25%, #a9c2c7); + background-image: -o-linear-gradient(#d1e2e5, #d1e2e5 25%, #a9c2c7); + background-image: linear-gradient(#d1e2e5, #d1e2e5 25%, #a9c2c7); + border-radius: 4px; + -ms-border-radius: 4px; + -moz-border-radius: 4px; + -webkit-border-radius: 4px; + -khtml-border-radius: 4px; -webkit-box-shadow: 1px 1px 2px #636363; -moz-box-shadow: 1px 1px 2px #636363; box-shadow: 1px 1px 2px #636363; } #askButton:hover { + background-color: #cde5e9; + background-repeat: no-repeat; + background-image: -webkit-gradient(linear, 0 0, 0 100%, from(#cde5e9), color-stop(25%, #cde5e9), to(#94b3ba)); + background-image: -webkit-linear-gradient(#cde5e9, #cde5e9 25%, #94b3ba); + background-image: -moz-linear-gradient(top, #cde5e9, #cde5e9 25%, #94b3ba); + background-image: -ms-linear-gradient(#cde5e9, #cde5e9 25%, #94b3ba); + background-image: -o-linear-gradient(#cde5e9, #cde5e9 25%, #94b3ba); + background-image: linear-gradient(#cde5e9, #cde5e9 25%, #94b3ba); text-decoration: none; - background: url(../images/bigbutton.png) repeat-x top; text-shadow: 0px 1px 0px #c6d9dd; -moz-text-shadow: 0px 1px 0px #c6d9dd; -webkit-text-shadow: 0px 1px 0px #c6d9dd; @@ -481,6 +521,8 @@ body.anon #searchBar .searchInputCancelable { } .box p { margin-bottom: 4px; + color: #707070; + font-family: 'Yanone Kaffeesatz', Arial, sans-serif; } .box p.info-box-follow-up-links { text-align: right; @@ -497,14 +539,15 @@ body.anon #searchBar .searchInputCancelable { color: #656565; padding-right: 10px; margin-bottom: 10px; - font-family: 'Yanone Kaffeesatz', sans-serif; + font-family: 'Yanone Kaffeesatz', Arial, sans-serif; + width: 190px; } .box h3 { color: #4a757f; font-size: 18px; text-align: left; font-weight: normal; - font-family: 'Yanone Kaffeesatz', sans-serif; + font-family: 'Yanone Kaffeesatz', Arial, sans-serif; padding-left: 0px; } .box .contributorback { @@ -516,12 +559,13 @@ body.anon #searchBar .searchInputCancelable { display: block; float: right; text-align: left; - font-family: 'Yanone Kaffeesatz', sans-serif; + font-family: 'Yanone Kaffeesatz', Arial, sans-serif; width: 80px; margin-right: 18px; } -.box #displayTagFilterControl label { - /*Especial width just for the display tag filter box in index page*/ +.box #displayTagFilterControl label, +.box #emailTagFilterControl label { + /*Especial width just for the tag filter boxes in index page*/ width: 160px; } @@ -547,57 +591,108 @@ body.anon #searchBar .searchInputCancelable { font-size: 15px; } .box .inputs #interestingTagInput, -.box .inputs #ignoredTagInput { +.box .inputs #ignoredTagInput, +.box .inputs #subscribedTagInput, +.box .inputs #ab-tag-search { width: 153px; padding-left: 5px; border: #c9c9b5 1px solid; height: 25px; } +.box .inputs #ab-tag-search { + width: 135px; +} .box .inputs #interestingTagAdd, -.box .inputs #ignoredTagAdd { - background: url(../images/small-button-blue.png) repeat-x top; +.box .inputs #ignoredTagAdd, +.box .inputs #subscribedTagAdd, +.box .inputs #ab-tag-search-add { border: 0; - color: #4a757f; font-weight: bold; - font-size: 12px; + margin-top: -2px; width: 30px; height: 27px; - margin-top: -2px; + font-size: 14px; + text-align: center; + text-decoration: none; cursor: pointer; + color: #4a757f; + font-family: 'Yanone Kaffeesatz', Arial, sans-serif; + text-shadow: 0px 1px 0px #c6d9dd; + -moz-text-shadow: 0px 1px 0px #c6d9dd; + -webkit-text-shadow: 0px 1px 0px #c6d9dd; + border-top: #eaf2f3 1px solid; + background-color: #d1e2e5; + background-repeat: no-repeat; + background-image: -webkit-gradient(linear, 0 0, 0 100%, from(#d1e2e5), color-stop(25%, #d1e2e5), to(#a9c2c7)); + background-image: -webkit-linear-gradient(#d1e2e5, #d1e2e5 25%, #a9c2c7); + background-image: -moz-linear-gradient(top, #d1e2e5, #d1e2e5 25%, #a9c2c7); + background-image: -ms-linear-gradient(#d1e2e5, #d1e2e5 25%, #a9c2c7); + background-image: -o-linear-gradient(#d1e2e5, #d1e2e5 25%, #a9c2c7); + background-image: linear-gradient(#d1e2e5, #d1e2e5 25%, #a9c2c7); + border-radius: 4px; + -ms-border-radius: 4px; + -moz-border-radius: 4px; + -webkit-border-radius: 4px; + -khtml-border-radius: 4px; + -webkit-box-shadow: 1px 1px 2px #636363; + -moz-box-shadow: 1px 1px 2px #636363; + box-shadow: 1px 1px 2px #636363; border-radius: 4px; -ms-border-radius: 4px; -moz-border-radius: 4px; -webkit-border-radius: 4px; -khtml-border-radius: 4px; - text-shadow: 0px 1px 0px #e6f6fa; - -moz-text-shadow: 0px 1px 0px #e6f6fa; - -webkit-text-shadow: 0px 1px 0px #e6f6fa; - -webkit-box-shadow: 1px 1px 2px #808080; - -moz-box-shadow: 1px 1px 2px #808080; - box-shadow: 1px 1px 2px #808080; } .box .inputs #interestingTagAdd:hover, -.box .inputs #ignoredTagAdd:hover { - background: url(../images/small-button-blue.png) repeat-x bottom; +.box .inputs #ignoredTagAdd:hover, +.box .inputs #ab-tag-search-add:hover { + background-color: #cde5e9; + background-repeat: no-repeat; + background-image: -webkit-gradient(linear, 0 0, 0 100%, from(#cde5e9), color-stop(25%, #cde5e9), to(#94b3ba)); + background-image: -webkit-linear-gradient(#cde5e9, #cde5e9 25%, #94b3ba); + background-image: -moz-linear-gradient(top, #cde5e9, #cde5e9 25%, #94b3ba); + background-image: -ms-linear-gradient(#cde5e9, #cde5e9 25%, #94b3ba); + background-image: -o-linear-gradient(#cde5e9, #cde5e9 25%, #94b3ba); + background-image: linear-gradient(#cde5e9, #cde5e9 25%, #94b3ba); + text-decoration: none; + text-shadow: 0px 1px 0px #c6d9dd; + -moz-text-shadow: 0px 1px 0px #c6d9dd; + -webkit-text-shadow: 0px 1px 0px #c6d9dd; +} +.box .inputs #ab-tag-search-add { + width: 47px; + margin-left: 3px; } .box img.gravatar { margin: 1px; } .box a.followed, .box a.follow { - background: url(../images/medium-button.png) top repeat-x; - height: 34px; line-height: 34px; - text-align: center; border: 0; - font-family: 'Yanone Kaffeesatz', sans-serif; - color: #4a757f; font-weight: normal; - font-size: 21px; margin-top: 3px; display: block; width: 120px; + height: 34px; + font-size: 21px; + text-align: center; text-decoration: none; + cursor: pointer; + color: #4a757f; + font-family: 'Yanone Kaffeesatz', Arial, sans-serif; + text-shadow: 0px 1px 0px #c6d9dd; + -moz-text-shadow: 0px 1px 0px #c6d9dd; + -webkit-text-shadow: 0px 1px 0px #c6d9dd; + border-top: #eaf2f3 1px solid; + background-color: #d1e2e5; + background-repeat: no-repeat; + background-image: -webkit-gradient(linear, 0 0, 0 100%, from(#d1e2e5), color-stop(25%, #d1e2e5), to(#a9c2c7)); + background-image: -webkit-linear-gradient(#d1e2e5, #d1e2e5 25%, #a9c2c7); + background-image: -moz-linear-gradient(top, #d1e2e5, #d1e2e5 25%, #a9c2c7); + background-image: -ms-linear-gradient(#d1e2e5, #d1e2e5 25%, #a9c2c7); + background-image: -o-linear-gradient(#d1e2e5, #d1e2e5 25%, #a9c2c7); + background-image: linear-gradient(#d1e2e5, #d1e2e5 25%, #a9c2c7); border-radius: 4px; -ms-border-radius: 4px; -moz-border-radius: 4px; @@ -611,8 +706,18 @@ body.anon #searchBar .searchInputCancelable { } .box a.followed:hover, .box a.follow:hover { + background-color: #cde5e9; + background-repeat: no-repeat; + background-image: -webkit-gradient(linear, 0 0, 0 100%, from(#cde5e9), color-stop(25%, #cde5e9), to(#94b3ba)); + background-image: -webkit-linear-gradient(#cde5e9, #cde5e9 25%, #94b3ba); + background-image: -moz-linear-gradient(top, #cde5e9, #cde5e9 25%, #94b3ba); + background-image: -ms-linear-gradient(#cde5e9, #cde5e9 25%, #94b3ba); + background-image: -o-linear-gradient(#cde5e9, #cde5e9 25%, #94b3ba); + background-image: linear-gradient(#cde5e9, #cde5e9 25%, #94b3ba); text-decoration: none; - background: url(../images/medium-button.png) bottom repeat-x; + text-shadow: 0px 1px 0px #c6d9dd; + -moz-text-shadow: 0px 1px 0px #c6d9dd; + -webkit-text-shadow: 0px 1px 0px #c6d9dd; text-shadow: 0px 1px 0px #c6d9dd; -moz-text-shadow: 0px 1px 0px #c6d9dd; -webkit-text-shadow: 0px 1px 0px #c6d9dd; @@ -638,6 +743,10 @@ body.anon #searchBar .searchInputCancelable { .box .notify-sidebar #question-subscribe-sidebar { margin: 7px 0 0 3px; } +.users-page .box label { + display: inline; + float: none; +} .statsWidget p { color: #707070; font-size: 16px; @@ -730,8 +839,7 @@ body.anon #searchBar .searchInputCancelable { .tabsC .label { float: left; color: #646464; - margin-top: 4px; - margin-right: 5px; + margin: 4px 5px 0px 8px; } .main-page .tabsA .label { margin-left: 8px; @@ -776,14 +884,14 @@ body.anon #searchBar .searchInputCancelable { float: left; margin-bottom: 8px; padding-top: 6px; - font-family: 'Yanone Kaffeesatz', sans-serif; + font-family: 'Yanone Kaffeesatz', Arial, sans-serif; } #listSearchTags { float: left; margin-top: 3px; color: #707070; font-size: 16px; - font-family: 'Yanone Kaffeesatz', sans-serif; + font-family: 'Yanone Kaffeesatz', Arial, sans-serif; } ul#searchTags { margin-left: 10px; @@ -797,7 +905,7 @@ ul#searchTags { margin: 5px 0 10px 0; padding: 0px; float: left; - font-family: 'Yanone Kaffeesatz', sans-serif; + font-family: 'Yanone Kaffeesatz', Arial, sans-serif; } .search-tips a { text-decoration: underline; @@ -811,6 +919,9 @@ ul#searchTags { padding: 0; width: 100%; } +.main-page #question-list { + margin-top: 10px; +} .short-summary { position: relative; filter: inherit; @@ -829,7 +940,7 @@ ul#searchTags { padding-left: 0; margin-bottom: 6px; display: block; - font-family: 'Yanone Kaffeesatz', sans-serif; + font-family: 'Yanone Kaffeesatz', Arial, sans-serif; } .short-summary a { color: #464646; @@ -840,7 +951,7 @@ ul#searchTags { font-family: Arial; padding-right: 4px; } -.short-summary .userinfo .relativetime, +.short-summary .userinfo .timeago, .short-summary span.anonymous { font-size: 11px; clear: both; @@ -854,12 +965,12 @@ ul#searchTags { .short-summary .counts { float: right; margin: 4px 0 0 5px; - font-family: 'Yanone Kaffeesatz', sans-serif; + font-family: 'Yanone Kaffeesatz', Arial, sans-serif; } .short-summary .counts .item-count { padding: 0px 5px 0px 5px; font-size: 25px; - font-family: 'Yanone Kaffeesatz', sans-serif; + font-family: 'Yanone Kaffeesatz', Arial, sans-serif; } .short-summary .counts .votes div, .short-summary .counts .views div, @@ -1049,7 +1160,7 @@ ul#related-tags { ul.tags li { float: left; display: block; - margin: 0 8px 0 0; + margin: 0 8px 8px 0; padding: 0; height: 20px; } @@ -1173,7 +1284,7 @@ ul#related-tags li { /* ----- Ask and Edit Question Form template----- */ .section-title { color: #7ea9b3; - font-family: 'Yanone Kaffeesatz', sans-serif; + font-family: 'Yanone Kaffeesatz', Arial, sans-serif; font-weight: bold; font-size: 24px; } @@ -1199,7 +1310,7 @@ ul#related-tags li { margin: 0px; padding: 0px 0 0 5px; border: #cce6ec 3px solid; - width: 725px; + width: 719px; } .ask-page div#question-list, .edit-question-page div#question-list { @@ -1261,14 +1372,28 @@ ul#related-tags li { .ask-page input.submit, .edit-question-page input.submit { float: left; - background: url(../images/medium-button.png) top repeat-x; - height: 34px; - border: 0; - font-family: 'Yanone Kaffeesatz', sans-serif; - color: #4a757f; font-weight: normal; - font-size: 21px; margin-top: 3px; + width: 160px; + height: 34px; + font-size: 21px; + text-align: center; + text-decoration: none; + cursor: pointer; + color: #4a757f; + font-family: 'Yanone Kaffeesatz', Arial, sans-serif; + text-shadow: 0px 1px 0px #c6d9dd; + -moz-text-shadow: 0px 1px 0px #c6d9dd; + -webkit-text-shadow: 0px 1px 0px #c6d9dd; + border-top: #eaf2f3 1px solid; + background-color: #d1e2e5; + background-repeat: no-repeat; + background-image: -webkit-gradient(linear, 0 0, 0 100%, from(#d1e2e5), color-stop(25%, #d1e2e5), to(#a9c2c7)); + background-image: -webkit-linear-gradient(#d1e2e5, #d1e2e5 25%, #a9c2c7); + background-image: -moz-linear-gradient(top, #d1e2e5, #d1e2e5 25%, #a9c2c7); + background-image: -ms-linear-gradient(#d1e2e5, #d1e2e5 25%, #a9c2c7); + background-image: -o-linear-gradient(#d1e2e5, #d1e2e5 25%, #a9c2c7); + background-image: linear-gradient(#d1e2e5, #d1e2e5 25%, #a9c2c7); border-radius: 4px; -ms-border-radius: 4px; -moz-border-radius: 4px; @@ -1282,33 +1407,60 @@ ul#related-tags li { #fmanswer input.submit:hover, .ask-page input.submit:hover, .edit-question-page input.submit:hover { + background-color: #cde5e9; + background-repeat: no-repeat; + background-image: -webkit-gradient(linear, 0 0, 0 100%, from(#cde5e9), color-stop(25%, #cde5e9), to(#94b3ba)); + background-image: -webkit-linear-gradient(#cde5e9, #cde5e9 25%, #94b3ba); + background-image: -moz-linear-gradient(top, #cde5e9, #cde5e9 25%, #94b3ba); + background-image: -ms-linear-gradient(#cde5e9, #cde5e9 25%, #94b3ba); + background-image: -o-linear-gradient(#cde5e9, #cde5e9 25%, #94b3ba); + background-image: linear-gradient(#cde5e9, #cde5e9 25%, #94b3ba); text-decoration: none; - background: url(../images/medium-button.png) bottom repeat-x; text-shadow: 0px 1px 0px #c6d9dd; -moz-text-shadow: 0px 1px 0px #c6d9dd; -webkit-text-shadow: 0px 1px 0px #c6d9dd; + text-shadow: 0px 1px 0px #c6d9dd; + -moz-text-shadow: 0px 1px 0px #c6d9dd; + -webkit-text-shadow: 0px 1px 0px #c6d9dd; +} +.wmd-container { + border: #cce6ec 3px solid; +} +.users-page .wmd-container { + width: 200px; +} +.ask-page .wmd-container, +.question-page .wmd-container, +.edit-question-page .wmd-container, +.edit-answer-page .wmd-container { + width: 723px; +} +.ask-page #editor, +.question-page #editor, +.edit-question-page #editor, +.edit-answer-page #editor { + width: 710px; + padding: 6px; } #editor { - /*adjustment for editor preview*/ + /* adjustment for editor preview */ + display: block; font-size: 100%; min-height: 200px; line-height: 18px; margin: 0; - border-left: #cce6ec 3px solid; - border-bottom: #cce6ec 3px solid; - border-right: #cce6ec 3px solid; - border-top: 0; - padding: 10px; - margin-bottom: 10px; - width: 717px; + border: 0; +} +.users-page #editor { + width: 192px; } #id_title { width: 100%; } .wmd-preview { - margin: 3px 0 5px 0; - padding: 6px; + margin: 0; + padding: 5px; background-color: #F5F5F5; min-height: 20px; overflow: auto; @@ -1320,6 +1472,9 @@ ul#related-tags li { line-height: 1.4; font-size: 14px; } +.wmd-preview p:last-child { + margin-bottom: 0; +} .wmd-preview pre { background-color: #E7F1F8; } @@ -1329,6 +1484,9 @@ ul#related-tags li { .wmd-preview IMG { max-width: 600px; } +.user-page .wmd-buttons { + width: 725px; +} .preview-toggle { width: 100%; color: #b6a475; @@ -1383,7 +1541,7 @@ ul#related-tags li { margin: 0px; padding: 0px 0 0 5px; border: #cce6ec 3px solid; - width: 725px; + width: 719px; margin-bottom: 10px; } .edit-question-page #id_summary, @@ -1403,7 +1561,7 @@ ul#related-tags li { /* ----- Question template ----- */ .question-page h1 { padding-top: 0px; - font-family: 'Yanone Kaffeesatz', sans-serif; + font-family: 'Yanone Kaffeesatz', Arial, sans-serif; } .question-page h1 a { color: #464646; @@ -1421,7 +1579,7 @@ ul#related-tags li { margin-left: 0px !important; } .question-page p.rss a { - font-family: 'Yanone Kaffeesatz', sans-serif; + font-family: 'Yanone Kaffeesatz', Arial, sans-serif; vertical-align: top; } .question-page .question-content { @@ -1586,7 +1744,7 @@ ul#related-tags li { } .question-page #questionCount { float: left; - font-family: 'Yanone Kaffeesatz', sans-serif; + font-family: 'Yanone Kaffeesatz', Arial, sans-serif; line-height: 15px; } .question-page .question-img-upvote, @@ -1632,13 +1790,11 @@ ul#related-tags li { color: #7ea9b3; width: 200px; float: left; - font-family: 'Yanone Kaffeesatz', sans-serif; + font-family: 'Yanone Kaffeesatz', Arial, sans-serif; } .question-page .comments { font-size: 12px; clear: both; - /* A small hack to solve 1px problem on webkit browsers */ - } .question-page .comments div.controls { clear: both; @@ -1688,11 +1844,6 @@ ul#related-tags li { padding-top: 3px; border: #cce6ec 3px solid; } -@media screen and (-webkit-min-device-pixel-ratio: 0) { - .question-page .comments textarea { - padding-left: 3px !important; - } -} .question-page .comments input { margin-left: 10px; margin-top: 1px; @@ -1700,31 +1851,49 @@ ul#related-tags li { width: 100px; } .question-page .comments button { - background: url(../images/small-button-blue.png) repeat-x top; - border: 0; - color: #4a757f; - font-family: Arial; - font-size: 13px; - width: 100px; - font-weight: bold; - height: 27px; line-height: 25px; margin-bottom: 5px; + width: 100px; + height: 27px; + font-size: 12px; + text-align: center; + text-decoration: none; cursor: pointer; + color: #4a757f; + font-family: 'Yanone Kaffeesatz', Arial, sans-serif; + text-shadow: 0px 1px 0px #c6d9dd; + -moz-text-shadow: 0px 1px 0px #c6d9dd; + -webkit-text-shadow: 0px 1px 0px #c6d9dd; + border-top: #eaf2f3 1px solid; + background-color: #d1e2e5; + background-repeat: no-repeat; + background-image: -webkit-gradient(linear, 0 0, 0 100%, from(#d1e2e5), color-stop(25%, #d1e2e5), to(#a9c2c7)); + background-image: -webkit-linear-gradient(#d1e2e5, #d1e2e5 25%, #a9c2c7); + background-image: -moz-linear-gradient(top, #d1e2e5, #d1e2e5 25%, #a9c2c7); + background-image: -ms-linear-gradient(#d1e2e5, #d1e2e5 25%, #a9c2c7); + background-image: -o-linear-gradient(#d1e2e5, #d1e2e5 25%, #a9c2c7); + background-image: linear-gradient(#d1e2e5, #d1e2e5 25%, #a9c2c7); border-radius: 4px; -ms-border-radius: 4px; -moz-border-radius: 4px; -webkit-border-radius: 4px; -khtml-border-radius: 4px; - text-shadow: 0px 1px 0px #e6f6fa; - -moz-text-shadow: 0px 1px 0px #e6f6fa; - -webkit-text-shadow: 0px 1px 0px #e6f6fa; - -webkit-box-shadow: 1px 1px 2px #808080; - -moz-box-shadow: 1px 1px 2px #808080; - box-shadow: 1px 1px 2px #808080; + -webkit-box-shadow: 1px 1px 2px #636363; + -moz-box-shadow: 1px 1px 2px #636363; + box-shadow: 1px 1px 2px #636363; + font-family: Arial; + font-weight: bold; } .question-page .comments button:hover { - background: url(../images/small-button-blue.png) bottom repeat-x; + background-color: #cde5e9; + background-repeat: no-repeat; + background-image: -webkit-gradient(linear, 0 0, 0 100%, from(#cde5e9), color-stop(25%, #cde5e9), to(#94b3ba)); + background-image: -webkit-linear-gradient(#cde5e9, #cde5e9 25%, #94b3ba); + background-image: -moz-linear-gradient(top, #cde5e9, #cde5e9 25%, #94b3ba); + background-image: -ms-linear-gradient(#cde5e9, #cde5e9 25%, #94b3ba); + background-image: -o-linear-gradient(#cde5e9, #cde5e9 25%, #94b3ba); + background-image: linear-gradient(#cde5e9, #cde5e9 25%, #94b3ba); + text-decoration: none; text-shadow: 0px 1px 0px #c6d9dd; -moz-text-shadow: 0px 1px 0px #c6d9dd; -webkit-text-shadow: 0px 1px 0px #c6d9dd; @@ -1865,12 +2034,17 @@ ul#related-tags li { text-align: center; padding-top: 2px; margin: 10px 10px 0px 3px; + /* smalls IE fixes */ + + *margin: 0; + *height: 210px; + *width: 30px; } .question-page .vote-buttons IMG { cursor: pointer; } .question-page .vote-number { - font-family: 'Yanone Kaffeesatz', sans-serif; + font-family: 'Yanone Kaffeesatz', Arial, sans-serif; padding: 0px 0 5px 0; font-size: 25px; font-weight: bold; @@ -1948,7 +2122,7 @@ ul#related-tags li { margin-top: 10px; } .question-page #fmanswer h2 { - font-family: 'Yanone Kaffeesatz', sans-serif; + font-family: 'Yanone Kaffeesatz', Arial, sans-serif; color: #7ea9b3; font-size: 24px; } @@ -1993,7 +2167,6 @@ ul#related-tags li { /* -----Content pages, Login, About, FAQ, Users----- */ .openid-signin, .meta, -.users-page, .user-profile-edit-page { font-size: 13px; line-height: 1.3; @@ -2001,7 +2174,6 @@ ul#related-tags li { } .openid-signin p, .meta p, -.users-page p, .user-profile-edit-page p { font-size: 13px; color: #707070; @@ -2012,7 +2184,6 @@ ul#related-tags li { } .openid-signin h2, .meta h2, -.users-page h2, .user-profile-edit-page h2 { color: #525252; padding-left: 0px; @@ -2070,35 +2241,55 @@ ul#related-tags li { .users-page input.submit, .user-profile-edit-page input.submit, .user-profile-page input.submit { - background: url(../images/small-button-blue.png) repeat-x top; - border: 0; - color: #4a757f; - font-weight: bold; - font-size: 13px; - font-family: Arial; - height: 26px; + font-weight: normal; margin: 5px 0px; width: 100px; + height: 26px; + font-size: 15px; + text-align: center; + text-decoration: none; cursor: pointer; + color: #4a757f; + font-family: 'Yanone Kaffeesatz', Arial, sans-serif; + text-shadow: 0px 1px 0px #c6d9dd; + -moz-text-shadow: 0px 1px 0px #c6d9dd; + -webkit-text-shadow: 0px 1px 0px #c6d9dd; + border-top: #eaf2f3 1px solid; + background-color: #d1e2e5; + background-repeat: no-repeat; + background-image: -webkit-gradient(linear, 0 0, 0 100%, from(#d1e2e5), color-stop(25%, #d1e2e5), to(#a9c2c7)); + background-image: -webkit-linear-gradient(#d1e2e5, #d1e2e5 25%, #a9c2c7); + background-image: -moz-linear-gradient(top, #d1e2e5, #d1e2e5 25%, #a9c2c7); + background-image: -ms-linear-gradient(#d1e2e5, #d1e2e5 25%, #a9c2c7); + background-image: -o-linear-gradient(#d1e2e5, #d1e2e5 25%, #a9c2c7); + background-image: linear-gradient(#d1e2e5, #d1e2e5 25%, #a9c2c7); border-radius: 4px; -ms-border-radius: 4px; -moz-border-radius: 4px; -webkit-border-radius: 4px; -khtml-border-radius: 4px; - text-shadow: 0px 1px 0px #e6f6fa; - -moz-text-shadow: 0px 1px 0px #e6f6fa; - -webkit-text-shadow: 0px 1px 0px #e6f6fa; - -webkit-box-shadow: 1px 1px 2px #808080; - -moz-box-shadow: 1px 1px 2px #808080; - box-shadow: 1px 1px 2px #808080; + -webkit-box-shadow: 1px 1px 2px #636363; + -moz-box-shadow: 1px 1px 2px #636363; + box-shadow: 1px 1px 2px #636363; + font-family: Arial; } .openid-signin input.submit:hover, .meta input.submit:hover, .users-page input.submit:hover, .user-profile-edit-page input.submit:hover, .user-profile-page input.submit:hover { - background: url(../images/small-button-blue.png) repeat-x bottom; + background-color: #cde5e9; + background-repeat: no-repeat; + background-image: -webkit-gradient(linear, 0 0, 0 100%, from(#cde5e9), color-stop(25%, #cde5e9), to(#94b3ba)); + background-image: -webkit-linear-gradient(#cde5e9, #cde5e9 25%, #94b3ba); + background-image: -moz-linear-gradient(top, #cde5e9, #cde5e9 25%, #94b3ba); + background-image: -ms-linear-gradient(#cde5e9, #cde5e9 25%, #94b3ba); + background-image: -o-linear-gradient(#cde5e9, #cde5e9 25%, #94b3ba); + background-image: linear-gradient(#cde5e9, #cde5e9 25%, #94b3ba); text-decoration: none; + text-shadow: 0px 1px 0px #c6d9dd; + -moz-text-shadow: 0px 1px 0px #c6d9dd; + -webkit-text-shadow: 0px 1px 0px #c6d9dd; } .openid-signin .cancel, .meta .cancel, @@ -2115,6 +2306,9 @@ ul#related-tags li { .user-profile-page .cancel:hover { background: url(../images/small-button-cancel.png) repeat-x bottom !important; } +.openid-signin form { + margin-bottom: 5px; +} #email-input-fs, #local_login_buttons, #password-fs, @@ -2145,34 +2339,55 @@ ul#related-tags li { #local_login_buttons .submit-b, #password-fs .submit-b, #openid-fs .submit-b { - background: url(../images/small-button-blue.png) repeat-x top; - border: 0; - color: #4a757f; - font-weight: bold; - font-size: 13px; - font-family: Arial; + width: 100px; height: 24px; - margin-top: -2px; - padding-left: 10px; - padding-right: 10px; + font-size: 15px; + text-align: center; + text-decoration: none; cursor: pointer; + color: #4a757f; + font-family: 'Yanone Kaffeesatz', Arial, sans-serif; + text-shadow: 0px 1px 0px #c6d9dd; + -moz-text-shadow: 0px 1px 0px #c6d9dd; + -webkit-text-shadow: 0px 1px 0px #c6d9dd; + border-top: #eaf2f3 1px solid; + background-color: #d1e2e5; + background-repeat: no-repeat; + background-image: -webkit-gradient(linear, 0 0, 0 100%, from(#d1e2e5), color-stop(25%, #d1e2e5), to(#a9c2c7)); + background-image: -webkit-linear-gradient(#d1e2e5, #d1e2e5 25%, #a9c2c7); + background-image: -moz-linear-gradient(top, #d1e2e5, #d1e2e5 25%, #a9c2c7); + background-image: -ms-linear-gradient(#d1e2e5, #d1e2e5 25%, #a9c2c7); + background-image: -o-linear-gradient(#d1e2e5, #d1e2e5 25%, #a9c2c7); + background-image: linear-gradient(#d1e2e5, #d1e2e5 25%, #a9c2c7); border-radius: 4px; -ms-border-radius: 4px; -moz-border-radius: 4px; -webkit-border-radius: 4px; -khtml-border-radius: 4px; - text-shadow: 0px 1px 0px #e6f6fa; - -moz-text-shadow: 0px 1px 0px #e6f6fa; - -webkit-text-shadow: 0px 1px 0px #e6f6fa; - -webkit-box-shadow: 1px 1px 2px #808080; - -moz-box-shadow: 1px 1px 2px #808080; - box-shadow: 1px 1px 2px #808080; + -webkit-box-shadow: 1px 1px 2px #636363; + -moz-box-shadow: 1px 1px 2px #636363; + box-shadow: 1px 1px 2px #636363; + font-family: Arial; + font-weight: bold; + padding-right: 10px; + border: 0; } #email-input-fs .submit-b:hover, #local_login_buttons .submit-b:hover, #password-fs .submit-b:hover, #openid-fs .submit-b:hover { - background: url(../images/small-button-blue.png) repeat-x bottom; + background-color: #cde5e9; + background-repeat: no-repeat; + background-image: -webkit-gradient(linear, 0 0, 0 100%, from(#cde5e9), color-stop(25%, #cde5e9), to(#94b3ba)); + background-image: -webkit-linear-gradient(#cde5e9, #cde5e9 25%, #94b3ba); + background-image: -moz-linear-gradient(top, #cde5e9, #cde5e9 25%, #94b3ba); + background-image: -ms-linear-gradient(#cde5e9, #cde5e9 25%, #94b3ba); + background-image: -o-linear-gradient(#cde5e9, #cde5e9 25%, #94b3ba); + background-image: linear-gradient(#cde5e9, #cde5e9 25%, #94b3ba); + text-decoration: none; + text-shadow: 0px 1px 0px #c6d9dd; + -moz-text-shadow: 0px 1px 0px #c6d9dd; + -webkit-text-shadow: 0px 1px 0px #c6d9dd; } .openid-input { background: url(../images/openid.gif) no-repeat; @@ -2199,20 +2414,15 @@ ul#related-tags li { font-size: 120%; } /* People page */ -.tabBar-user { - width: 375px; -} +/*.users-page .tabBar{ + width:375px; +}*/ .user { - padding: 5px; + padding: 5px 10px 5px 0; line-height: 140%; width: 166px; - border: #eee 1px solid; + height: 32px; margin-bottom: 5px; - border-radius: 3px; - -ms-border-radius: 3px; - -moz-border-radius: 3px; - -webkit-border-radius: 3px; - -khtml-border-radius: 3px; } .user .user-micro-info { color: #525252; @@ -2280,7 +2490,7 @@ a:hover.medal { } .user-profile-page h2 { padding: 10px 0px 10px 0px; - font-family: 'Yanone Kaffeesatz', sans-serif; + font-family: 'Yanone Kaffeesatz', Arial, sans-serif; } .user-details { font-size: 13px; @@ -2302,31 +2512,52 @@ a:hover.medal { .follow-toggle, .submit { border: 0 !important; - color: #4a757f; font-weight: bold; - font-size: 12px; - height: 26px; line-height: 26px; margin-top: -2px; - font-size: 15px; + width: 100px; + height: 26px; + font-size: 12px; + text-align: center; + text-decoration: none; cursor: pointer; - font-family: 'Yanone Kaffeesatz', sans-serif; - background: url(../images/small-button-blue.png) repeat-x top; + color: #4a757f; + font-family: 'Yanone Kaffeesatz', Arial, sans-serif; + text-shadow: 0px 1px 0px #c6d9dd; + -moz-text-shadow: 0px 1px 0px #c6d9dd; + -webkit-text-shadow: 0px 1px 0px #c6d9dd; + border-top: #eaf2f3 1px solid; + background-color: #d1e2e5; + background-repeat: no-repeat; + background-image: -webkit-gradient(linear, 0 0, 0 100%, from(#d1e2e5), color-stop(25%, #d1e2e5), to(#a9c2c7)); + background-image: -webkit-linear-gradient(#d1e2e5, #d1e2e5 25%, #a9c2c7); + background-image: -moz-linear-gradient(top, #d1e2e5, #d1e2e5 25%, #a9c2c7); + background-image: -ms-linear-gradient(#d1e2e5, #d1e2e5 25%, #a9c2c7); + background-image: -o-linear-gradient(#d1e2e5, #d1e2e5 25%, #a9c2c7); + background-image: linear-gradient(#d1e2e5, #d1e2e5 25%, #a9c2c7); border-radius: 4px; -ms-border-radius: 4px; -moz-border-radius: 4px; -webkit-border-radius: 4px; -khtml-border-radius: 4px; - text-shadow: 0px 1px 0px #e6f6fa; - -moz-text-shadow: 0px 1px 0px #e6f6fa; - -webkit-text-shadow: 0px 1px 0px #e6f6fa; - -webkit-box-shadow: 1px 1px 2px #808080; - -moz-box-shadow: 1px 1px 2px #808080; - box-shadow: 1px 1px 2px #808080; + -webkit-box-shadow: 1px 1px 2px #636363; + -moz-box-shadow: 1px 1px 2px #636363; + box-shadow: 1px 1px 2px #636363; } .follow-toggle:hover, .submit:hover { - background: url(../images/small-button-blue.png) repeat-x bottom; + background-color: #cde5e9; + background-repeat: no-repeat; + background-image: -webkit-gradient(linear, 0 0, 0 100%, from(#cde5e9), color-stop(25%, #cde5e9), to(#94b3ba)); + background-image: -webkit-linear-gradient(#cde5e9, #cde5e9 25%, #94b3ba); + background-image: -moz-linear-gradient(top, #cde5e9, #cde5e9 25%, #94b3ba); + background-image: -ms-linear-gradient(#cde5e9, #cde5e9 25%, #94b3ba); + background-image: -o-linear-gradient(#cde5e9, #cde5e9 25%, #94b3ba); + background-image: linear-gradient(#cde5e9, #cde5e9 25%, #94b3ba); + text-decoration: none; + text-shadow: 0px 1px 0px #c6d9dd; + -moz-text-shadow: 0px 1px 0px #c6d9dd; + -webkit-text-shadow: 0px 1px 0px #c6d9dd; text-decoration: none !important; } .follow-toggle .follow { @@ -2346,13 +2577,13 @@ a:hover.medal { display: none; } .count { - font-family: 'Yanone Kaffeesatz', sans-serif; + font-family: 'Yanone Kaffeesatz', Arial, sans-serif; font-size: 200%; font-weight: 700; color: #777777; } .scoreNumber { - font-family: 'Yanone Kaffeesatz', sans-serif; + font-family: 'Yanone Kaffeesatz', Arial, sans-serif; font-size: 35px; font-weight: 800; color: #777; @@ -2463,7 +2694,7 @@ a:hover.medal { color: #525252; } .revision h3 { - font-family: 'Yanone Kaffeesatz', sans-serif; + font-family: 'Yanone Kaffeesatz', Arial, sans-serif; font-size: 21px; padding-left: 0px; } @@ -2570,7 +2801,7 @@ ins { padding: 6px 0 0 0; background: #16160f; font-size: 16px; - font-family: 'Yanone Kaffeesatz', sans-serif; + font-family: 'Yanone Kaffeesatz', Arial, sans-serif; } #ground p { margin-bottom: 0; @@ -2714,7 +2945,7 @@ span.form-error { padding: 0px; margin: 0px; } -.relativetime { +.timeago { font-weight: bold; text-decoration: none; } @@ -2935,6 +3166,9 @@ button::-moz-focus-inner { -khtml-border-radius: 5px; -webkit-border-radius: 5px; } +.list-table { + border-spacing: 0; +} .list-table td { vertical-align: top; } @@ -3144,7 +3378,6 @@ img.flag { .main-page img.flag { vertical-align: text-bottom; } - /* Pretty printing styles. Used with prettify.js. */ a.edit { padding-left: 3px; @@ -3247,3 +3480,110 @@ body.anon.lang-es #searchBar .searchInput { body.anon.lang-es #searchBar .searchInputCancelable { width: 390px; } +/* user groups */ +#user-groups ul { + margin-bottom: 0px; +} +#user-groups .delete-icon { + float: none; + display: inline; + color: #525252; + padding: 0 3px 0 3px; + background: #ccc; + border-radius: 4px; + line-height: inherit; + -moz-border-radius: 4px; + -khtml-border-radius: 4px; + -webkit-border-radius: 4px; +} +#user-groups .delete-icon:hover { + color: white; + background: #b32f2f; +} +.users-page .wmd-prompt-dialog { + background: #ccc; +} +.group-wiki .content > p:last-child { + margin-bottom: 5px; +} +.group-wiki .group-logo { + float: left; + margin: 0 5px 3px 0; +} +.group-wiki .follow-toggle.group-join-btn { + width: 150px; + margin: 4px auto 10px auto; + display: block; +} +.group-wiki .controls { + margin: 0 0 10px 0; +} +img.group-logo { + height: 60px; + /* important to align with the line spacing */ + +} +#groups-list { + margin-left: 0px; +} +#groups-list li { + display: inline; + list-style-type: none; + list-style-position: inside; + float: left; + text-align: center; +} +#groups-list .group-logo, +#groups-list .group-name { + display: block; +} +#reject-edit-modal input, +#reject-edit-modal textarea { + width: 514px; +} +input.tipped-input, +textarea.tipped-input { + padding-left: 5px; +} +.tipped-input.blank { + color: #707070; +} +.select-box { + margin: 0; +} +.select-box li { + list-style-type: none; + list-style-position: inside; + padding-left: 7px; + font-size: 14px; + line-height: 25px; +} +.select-box li.selected, +.select-box li.selected:hover { + background-color: #fcf8e3; + color: #c09853; +} +.select-box li:hover { + background-color: #cecece; + color: white; +} +/* fixes for bootstrap */ +.caret { + margin-bottom: 7px; +} +.btn-group { + text-align: left; +} +.btn-toolbar { + margin: 0; +} +.modal-footer { + text-align: left; +} +.modal p { + font-size: 14px; +} +.modal-body > textarea { + width: 515px; + margin-bottom: 0px; +} diff --git a/askbot/skins/default/media/style/style.less b/askbot/skins/default/media/style/style.less index 01a0f5fb..36f3de9d 100644 --- a/askbot/skins/default/media/style/style.less +++ b/askbot/skins/default/media/style/style.less @@ -154,6 +154,7 @@ h1 { padding: 0px 0 5px 0px; } + /* ----- Extra space above for messages ----- */ body.user-messages { @@ -467,24 +468,15 @@ body.anon { #askButton{ /* check blocks/secondary_header.html and widgets/ask_button.html*/ - background: url(../images/bigbutton.png) repeat-x bottom; line-height:44px; - text-align:center; - width:200px; - height:42px; - font-size:23px; - color:@button-label; - margin-top:7px; + margin-top:6px; float:right; text-transform:uppercase; - .rounded-corners(5px); - .box-shadow(1px, 1px, 2px, #636363) + .button-style(200px, 42px, 23px); } #askButton:hover{ - text-decoration:none; - background: url(../images/bigbutton.png) repeat-x top; - .text-shadow(0px, 1px, 0px, #c6d9dd) + .button-style-hover; } /* ----- Content layout, check two_column_body.html or one_column_body.html ----- */ @@ -537,6 +529,7 @@ body.anon { padding-right:10px; margin-bottom:10px; font-family:@main-font; + width:190px; } h3{ color:#4a757f; @@ -606,26 +599,21 @@ body.anon { #ignoredTagAdd, #subscribedTagAdd, #ab-tag-search-add { - background:url(../images/small-button-blue.png) repeat-x top; border:0; - color:@button-label; font-weight:bold; - font-size:12px; - width:30px; - height:27px; margin-top:-2px; - cursor:pointer; + .button-style(30px, 27px, 14px); .rounded-corners(4px); - .text-shadow(0px,1px,0px,#E6F6FA); - .box-shadow(1px, 1px, 2px, #808080); + } + #interestingTagAdd:hover, + #ignoredTagAdd:hover, + #ab-tag-search-add:hover { + .button-style-hover; } #ab-tag-search-add { width: 47px; margin-left: 3px; } - #interestingTagAdd:hover, #ignoredTagAdd:hover, #subscribedTag:hover { - background:url(../images/small-button-blue.png) repeat-x bottom; - } } img.gravatar { @@ -635,28 +623,17 @@ body.anon { /* widgets for question template */ a.followed, a.follow{ - background: url(../images/medium-button.png) top repeat-x; - height:34px; line-height:34px; - text-align:center; border:0; - font-family:@main-font; - color:@button-label; font-weight:normal; - font-size:21px; margin-top:3px; - display:block; - width:120px; - text-decoration:none; - .rounded-corners(4px); - .box-shadow(1px, 1px, 2px, #636363); + .button-style(120px,34px,21px); .center; } a.followed:hover, a.follow:hover{ - text-decoration:none; - background: url(../images/medium-button.png) bottom repeat-x; + .button-style-hover; .text-shadow(0px, 1px, 0px, #c6d9dd); } @@ -1159,7 +1136,7 @@ ul#related-tags { ul.tags li { float:left; display: block; - margin: 0 8px 0 0; + margin: 0 8px 8px 0; padding: 0; height:20px; } @@ -1385,24 +1362,16 @@ ul#related-tags li { .ask-page input.submit, .edit-question-page input.submit { float: left; - background: url(../images/medium-button.png) top repeat-x; - height:34px; - border:0; - font-family:@main-font; - color:@button-label; font-weight:normal; - font-size:21px; margin-top:3px; - .rounded-corners(4px); - .box-shadow(1px, 1px, 2px, #636363); + .button-style(160px,34px,21px); margin-right:7px; } #fmanswer input.submit:hover, .ask-page input.submit:hover, .edit-question-page input.submit:hover{ - text-decoration:none; - background: url(../images/medium-button.png) bottom repeat-x; + .button-style-hover; .text-shadow(0px, 1px, 0px, #c6d9dd) } @@ -1855,24 +1824,14 @@ ul#related-tags li { width: 100px; } button{ - background:url(../images/small-button-blue.png) repeat-x top; - border:0; - color:@button-label; - font-family:@body-font; - font-size:13px; - width:100px; - font-weight:bold; - height:27px; line-height:25px; margin-bottom:5px; - cursor:pointer; - .rounded-corners(4px); - .text-shadow(0px,1px,0px,#E6F6FA); - .box-shadow(1px, 1px, 2px, #808080); + .button-style(100px, 27px, 12px); + font-family:@body-font; + font-weight:bold; } button:hover{ - background: url(../images/small-button-blue.png) bottom repeat-x; - .text-shadow(0px, 1px, 0px, #c6d9dd); + .button-style-hover; } .counter { display: inline-block; @@ -2017,6 +1976,10 @@ ul#related-tags li { text-align: center; padding-top: 2px; margin:10px 10px 0px 3px; + /* smalls IE fixes */ + *margin:0; + *height:210px; + *width:30px; } .vote-buttons IMG { @@ -2213,23 +2176,13 @@ ul#related-tags li { font-size:14px; } input.submit{ - background:url(../images/small-button-blue.png) repeat-x top; - border:0; - color:@button-label; - font-weight:bold; - font-size:13px; - font-family:@body-font; - height:26px; + font-weight:normal; margin:5px 0px; - width:100px; - cursor:pointer; - .rounded-corners(4px); - .text-shadow(0px,1px,0px,#E6F6FA); - .box-shadow(1px, 1px, 2px, #808080); + .button-style(100px,26px,15px); + font-family:@body-font; } input.submit:hover{ - background:url(../images/small-button-blue.png) repeat-x bottom; - text-decoration:none; + .button-style-hover; } .cancel{ background:url(../images/small-button-cancel.png) repeat-x top !important; @@ -2256,25 +2209,19 @@ ul#related-tags li { width:200px; } .submit-b{ - background:url(../images/small-button-blue.png) repeat-x top; - border:0; - color:@button-label; - font-weight:bold; - font-size:13px; + .button-style(100px,24px,15px); font-family:@body-font; - height:24px; - margin-top:-2px; - padding-left:10px; + font-weight:bold; padding-right:10px; - cursor:pointer; - .rounded-corners(4px); - .text-shadow(0px,1px,0px,#E6F6FA); - .box-shadow(1px, 1px, 2px, #808080) + border:0; } + .submit-b:hover{ - background:url(../images/small-button-blue.png) repeat-x bottom; + .button-style-hover; } } + + .openid-input { background: url(../images/openid.gif) no-repeat; padding-left: 15px; @@ -2418,23 +2365,14 @@ a:hover.medal { .follow-toggle,.submit { border:0 !important; - color:@button-label; font-weight:bold; - font-size:12px; - height:26px; line-height:26px; margin-top:-2px; - font-size:15px; - cursor:pointer; - font-family:@main-font; - background:url(../images/small-button-blue.png) repeat-x top; - .rounded-corners(4px); - .text-shadow(0px,1px,0px,#E6F6FA); - .box-shadow(1px, 1px, 2px, #808080) + .button-style(100px,26px,14px); } .follow-toggle:hover, .submit:hover { - background:url(../images/small-button-blue.png) repeat-x bottom; + .button-style-hover; text-decoration:none !important; } diff --git a/askbot/skins/default/templates/badges.html b/askbot/skins/default/templates/badges.html index 668de4f8..ce76e76b 100644 --- a/askbot/skins/default/templates/badges.html +++ b/askbot/skins/default/templates/badges.html @@ -38,7 +38,7 @@ badges? Please, give us your <a href='{{feedback_faq_url}}'>feedback</a> <a style="cursor:default;" title="{% trans %}gold badge: the highest honor and is very rare{% endtrans %}" class="medal"><span class="badge1">●</span> {% trans %}gold{% endtrans %}</a> </p> <p> - {% trans %}Gold badge is the highest award in this community. To obtain it have to show + {% trans %}Gold badge is the highest award in this community. To obtain it you have to show profound knowledge and ability in addition to your active participation.{% endtrans %} </p> <p> @@ -48,7 +48,7 @@ profound knowledge and ability in addition to your active participation.{% endtr class="medal"><span class="badge2">●</span> {% trans %}silver{% endtrans %}</a> </p> <p> - {% trans %}msgid "silver badge: occasionally awarded for the very high quality contributions{% endtrans %} + {% trans %}silver badge: occasionally awarded for the very high quality contributions{% endtrans %} </p> <p> <a style="cursor:default;" title="{% trans %}bronze badge: often given as a special honor{% endtrans %}" class="medal"> diff --git a/askbot/skins/default/templates/main_page/tab_bar.html b/askbot/skins/default/templates/main_page/tab_bar.html index 8b666155..17ab810e 100644 --- a/askbot/skins/default/templates/main_page/tab_bar.html +++ b/askbot/skins/default/templates/main_page/tab_bar.html @@ -3,9 +3,9 @@ {% cache 0 "scope_sort_tabs" search_tags request.user author_name scope sort query context.page language_code %} <a class="rss" {% if feed_url %} - href="{{settings.APP_URL}}{{feed_url}}" + href="{{feed_url}}" {% else %} - href="{{settings.APP_URL}}/feeds/rss/" + href="/feeds/rss/" {% endif %} title="{% trans %}subscribe to the questions feed{% endtrans %}" >{% trans %}RSS{% endtrans %} diff --git a/askbot/skins/default/templates/meta/fonts.html b/askbot/skins/default/templates/meta/fonts.html new file mode 100644 index 00000000..f55d567c --- /dev/null +++ b/askbot/skins/default/templates/meta/fonts.html @@ -0,0 +1,20 @@ +<style type="text/css"> +@font-face { + font-family: 'Yanone Kaffeesatz'; + font-style: normal; + font-weight: 400; + src: url('{{"/images/YanoneKaffeesatz-Regular.ttf"|media}}'); +} +@font-face { + font-family: 'Yanone Kaffeesatz'; + font-style: normal; + font-weight: 700; + src: url('{{"/images/YanoneKaffeesatz-Bold.ttf"|media}}'); +} +@font-face { + font-family: 'Yanone Kaffeesatz'; + font-style: normal; + font-weight: 300; + src: url('{{"/images/YanoneKaffeesatz-Light.ttf"|media}}'); +} +</style> diff --git a/askbot/skins/default/templates/meta/html_head_stylesheets.html b/askbot/skins/default/templates/meta/html_head_stylesheets.html index 14f3c106..0d2ba463 100644 --- a/askbot/skins/default/templates/meta/html_head_stylesheets.html +++ b/askbot/skins/default/templates/meta/html_head_stylesheets.html @@ -4,7 +4,11 @@ <link href="{{"/style/style.less"|media }}" rel="stylesheet/less" type="text/css" /> <script type="text/javascript" src="{{"/js/less.min.js"|media}}"></script> {% endif %} -<link href='http://fonts.googleapis.com/css?family=Yanone+Kaffeesatz:300,400,700' rel='stylesheet' type='text/css'> +{% if settings.USE_LOCAL_FONTS %} + {% include "meta/fonts.html" %} +{% else %} + <link href='http://fonts.googleapis.com/css?family=Yanone+Kaffeesatz:300,400,700' rel='stylesheet' type='text/css'> +{% endif %} {{ skin.get_extra_css_link() }} {% if settings.USE_CUSTOM_CSS %} <link diff --git a/askbot/skins/default/templates/question/question_card.html b/askbot/skins/default/templates/question/question_card.html index 08f7ccee..dd52ea0f 100644 --- a/askbot/skins/default/templates/question/question_card.html +++ b/askbot/skins/default/templates/question/question_card.html @@ -29,4 +29,4 @@ </div> </div> -<div class="clean"></div> + diff --git a/askbot/skins/default/templates/question/subscribe_by_email_prompt.html b/askbot/skins/default/templates/question/subscribe_by_email_prompt.html index a9158143..6a77601c 100644 --- a/askbot/skins/default/templates/question/subscribe_by_email_prompt.html +++ b/askbot/skins/default/templates/question/subscribe_by_email_prompt.html @@ -8,7 +8,6 @@ {% else %} <p> {{ answer.email_notify }} - <label>{% trans %}once you sign in you will be able to subscribe for any updates here{% endtrans %}</label> <label>{% trans %}<span class='strong'>Here</span> (once you log in) you will be able to sign up for the periodic email updates about this question.{% endtrans %}</label> </p> {% endif %} diff --git a/askbot/skins/utils.py b/askbot/skins/utils.py index 9f67d5c9..0c0dba9c 100644 --- a/askbot/skins/utils.py +++ b/askbot/skins/utils.py @@ -3,7 +3,7 @@ the lookup resolution process for templates and media works as follows: * look up item in selected skin * if not found look in 'default' -* raise an exception +* raise an exception """ import os import logging @@ -56,7 +56,7 @@ def get_available_skins(selected=None): #re-insert default as a last item skins['default'] = default_dir - skins['common'] = common_dir + skins['common'] = common_dir return skins @@ -71,7 +71,7 @@ def get_path_to_skin(skin): return skin_dirs.get(skin, None) def get_skin_choices(): - """returns a tuple for use as a set of + """returns a tuple for use as a set of choices in the form""" available_skins = get_available_skins().keys() available_skins.remove('common') @@ -88,7 +88,7 @@ def resolve_skin_for_media(media=None, preferred_skin = None): def get_media_url(url, ignore_missing = False): """returns url prefixed with the skin name - of the first skin that contains the file + of the first skin that contains the file directories are searched in this order: askbot_settings.ASKBOT_DEFAULT_SKIN, then 'default', then 'commmon' if file is not found - returns None @@ -158,7 +158,7 @@ def get_media_url(url, ignore_missing = False): url = django_settings.STATIC_URL + use_skin + '/media/' + url url = os.path.normpath(url).replace('\\', '/') - + if resource_revision: url += '?v=%d' % resource_revision @@ -176,7 +176,7 @@ def update_media_revision(skin = None): if skin in get_skin_choices(): skin_path = get_path_to_skin(skin) else: - raise MediaNotFound('Skin %s not found' % skin) + raise MediaNotFound('Skin %s not found' % skin) else: skin = 'default' skin_path = get_path_to_skin(askbot_settings.ASKBOT_DEFAULT_SKIN) @@ -195,6 +195,5 @@ def update_media_revision(skin = None): if current_hash != askbot_settings.MEDIA_RESOURCE_REVISION_HASH: askbot_settings.update('MEDIA_RESOURCE_REVISION', resource_revision + 1) - askbot_settings.update('MEDIA_RESOURCE_REVISION_HASH', current_hash) + askbot_settings.update('MEDIA_RESOURCE_REVISION_HASH', current_hash) logging.debug('MEDIA_RESOURCE_REVISION changed') - askbot_settings.MEDIA_RESOURCE_REVISION diff --git a/askbot/startup_procedures.py b/askbot/startup_procedures.py index 9678fdf1..a5b0c940 100644 --- a/askbot/startup_procedures.py +++ b/askbot/startup_procedures.py @@ -11,7 +11,8 @@ import sys import os import re import askbot -from django.db import transaction +import south +from django.db import transaction, connection from django.conf import settings as django_settings from django.core.exceptions import ImproperlyConfigured from askbot.utils.loading import load_module @@ -166,7 +167,7 @@ def try_import(module_name, pypi_package_name, short_message = False): try: load_module(module_name) except ImportError, error: - message = 'Error: ' + unicode(error) + message = 'Error: ' + unicode(error) message += '\n\nPlease run: >pip install %s' % pypi_package_name if short_message == False: message += '\n\nTo install all the dependencies at once, type:' @@ -306,10 +307,10 @@ class SettingsTester(object): ) if len(self.messages) != 0: raise AskbotConfigError( - '\n\nTime to do some maintenance of your settings.py:\n\n* ' + + '\n\nTime to do some maintenance of your settings.py:\n\n* ' + '\n\n* '.join(self.messages) ) - + def test_staticfiles(): """tests configuration of the staticfiles app""" errors = list() @@ -350,7 +351,7 @@ def test_staticfiles(): if static_url is None or str(static_url).strip() == '': errors.append( 'Add STATIC_URL setting to your settings.py file. ' - 'The setting must be a url at which static files ' + 'The setting must be a url at which static files ' 'are accessible.' ) url = urlparse(static_url).path @@ -407,7 +408,7 @@ def test_staticfiles(): ' python manage.py collectstatic\n' ) - + print_errors(errors) if django_settings.STATICFILES_STORAGE == \ 'django.contrib.staticfiles.storage.StaticFilesStorage': @@ -479,8 +480,6 @@ def test_avatar(): '-e git+git://github.com/ericflo/django-avatar.git#egg=avatar', short_message = True ) - - def run_startup_tests(): """function that runs |