Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Facebook share button #40

Merged
merged 11 commits into from
Mar 2, 2015
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
15 changes: 12 additions & 3 deletions CHANGES.rst
Original file line number Diff line number Diff line change
Expand Up @@ -3,12 +3,20 @@ Changelog

There's a frood who really knows where his towel is.

2.0.3 (unreleased)
^^^^^^^^^^^^^^^^^^
2.1 (unreleased)
^^^^^^^^^^^^^^^^

- Added missing migration step for refreshing CSS registry
- Removed deprecated portal_actionicons registration
[keul]

- Translation fixes: some label were not translated
[keul]

- Facebook "Share" button now provided. See `#15`_.
[keul]

- Added missing migration step for refreshing CSS registry
[keul]

2.0.2 (2015-02-23)
^^^^^^^^^^^^^^^^^^
Expand Down Expand Up @@ -214,3 +222,4 @@ There's a frood who really knows where his towel is.

.. _`#36`: https://github.com/collective/sc.social.like/issues/36
.. _`#38`: https://github.com/collective/sc.social.like/issues/38
.. _`#15`: https://github.com/collective/sc.social.like/pull/15
4 changes: 3 additions & 1 deletion README.rst
Original file line number Diff line number Diff line change
Expand Up @@ -23,7 +23,9 @@ This package ships with plugins for the following networks:
Screenshot
^^^^^^^^^^

.. image:: https://github.com/collective/sc.social.like/raw/master/docs/screenshot.png
.. image:: https://github.com/collective/sc.social.like/raw/master/docs/screenshot1.png

.. image:: https://github.com/collective/sc.social.like/raw/master/docs/screenshot2.png

Don't Panic
-----------
Expand Down
Binary file modified docs/control_panel.png
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Binary file removed docs/screenshot.png
Binary file not shown.
Binary file added docs/screenshot1.png
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Binary file added docs/screenshot2.png
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
2 changes: 1 addition & 1 deletion sc/social/like/controlpanel/configure.zcml
Original file line number Diff line number Diff line change
Expand Up @@ -3,7 +3,7 @@
xmlns:browser="http://namespaces.zope.org/browser">

<adapter factory=".likes.LikeControlPanelAdapter" />

<browser:page
name="likes-providers"
for="Products.CMFPlone.interfaces.IPloneSiteRoot"
Expand Down
15 changes: 12 additions & 3 deletions sc/social/like/controlpanel/likes.py
Original file line number Diff line number Diff line change
@@ -1,20 +1,23 @@
# -*- coding:utf-8 -*-

from Acquisition import aq_inner
from plone.app.controlpanel.form import ControlPanelForm
from Products.CMFDefault.formlib.schema import ProxyFieldProperty as PFP
from Products.CMFDefault.formlib.schema import SchemaAdapterBase
from Products.CMFPlone.interfaces import IPloneSiteRoot
from Products.CMFPlone.utils import getToolByName
from Products.Five.browser.pagetemplatefile import ViewPageTemplateFile
from plone.app.controlpanel.form import ControlPanelForm
from sc.social.like import LikeMessageFactory as _
from sc.social.like.plugins import IPlugin
from zope import schema
from zope.app.form.browser import itemswidgets
from zope.component import adapts
from zope.component import getUtilitiesFor
from zope.formlib.form import FormFields
from zope.interface import implements
from zope.interface import Interface
from zope.interface import implements
from zope.schema.vocabulary import SimpleTerm
from zope.schema.vocabulary import SimpleVocabulary

CONTENT_TYPES = 'plone.app.vocabularies.ReallyUserFriendlyTypes'

Expand All @@ -28,6 +31,12 @@ def __init__(self, field, request):
request)


styles = SimpleVocabulary([
SimpleTerm(value=u'horizontal', title=_(u'horizontal')),
SimpleTerm(value=u'vertical', title=_(u'vertical')),
])


class IProvidersSchema(Interface):
""" General Configurations """

Expand Down Expand Up @@ -60,7 +69,7 @@ class IProvidersSchema(Interface):
),
required=True,
default=_(u'horizontal'),
values=(_(u'horizontal'), _(u'vertical')),
vocabulary=styles,
)


Expand Down
54 changes: 33 additions & 21 deletions sc/social/like/locales/es/LC_MESSAGES/sc.social.like.po
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,7 @@
msgid ""
msgstr ""
"Project-Id-Version: sc.social.like\n"
"POT-Creation-Date: 2015-02-10 10:34+0000\n"
"POT-Creation-Date: 2015-02-27 23:52+0000\n"
"PO-Revision-Date: 2011-08-29 17:47+0000\n"
"Last-Translator: Héctor Velarde <hector.velarde@gmail.com>\n"
"Language-Team: LANGUAGE <LL@li.org>\n"
Expand All @@ -19,38 +19,42 @@ msgstr ""
msgid "A simple, yet useful, social networking integration for Plone"
msgstr ""

#: ../plugins/facebook/controlpanel.py:39
#: ../plugins/facebook/controlpanel.py:43
msgid "Admins"
msgstr "Administradores"

#: ../plugins/facebook/controlpanel.py:49
#: ../plugins/facebook/controlpanel.py:53
msgid "Application ID"
msgstr ""

#: ../controlpanel/likes.py:56
#: ../controlpanel/likes.py:62
msgid "Button style"
msgstr "Estilo de los botones"

#: ../controlpanel/likes.pt:123
msgid "Configure each plugin."
msgstr ""

#: ../plugins/facebook/controlpanel.py:73
#: ../plugins/facebook/controlpanel.py:89
msgid "Configure settings for Facebook integration."
msgstr ""

#: ../plugins/twitter/controlpanel.py:41
msgid "Configure settings for Twitter integration."
msgstr ""

#: ../controlpanel/likes.py:95
#: ../controlpanel/likes.py:101
msgid "Configure settings for social like actions."
msgstr "Configuración de las acciones sociales."

#: ../controlpanel/likes.py:35
#: ../controlpanel/likes.py:41
msgid "Content types"
msgstr "Tipos de contenido"

#: ../plugins/facebook/controlpanel.py:62
msgid "Facebook buttons"
msgstr ""

#: ../plugins/facebook/controlpanel.py:17
msgid "Like"
msgstr "Me gusta"
Expand All @@ -59,28 +63,31 @@ msgstr "Me gusta"
msgid "Plugin-Specific Configuration"
msgstr ""

#: ../controlpanel/likes.py:46
#: ../controlpanel/likes.py:52
msgid "Plugins"
msgstr ""

#: ../plugins/facebook/controlpanel.py:18
msgid "Recommend"
msgstr "Recomendar"

#: ../profiles/default/actionicons.xml
#: ../plugins/facebook/controlpanel.py:23
msgid "Share"
msgstr ""

#: ../profiles/default/controlpanel.xml
msgid "Social Like"
msgstr "Social Like"

#: ../plugins/facebook/controlpanel.py:72
#: ../plugins/facebook/controlpanel.py:88
msgid "Social: Facebook settings"
msgstr ""

#: ../controlpanel/likes.py:96
#: ../controlpanel/likes.py:102
msgid "Social: Like Actions"
msgstr "Social Like"

#: ../controlpanel/likes.py:94
#: ../controlpanel/likes.py:100
msgid "Social: Like Actions settings"
msgstr "Configuración de Social Like"

Expand All @@ -92,38 +99,43 @@ msgstr ""
msgid "Twitter nick"
msgstr "Nombre de usuario en Twitter"

#: ../plugins/facebook/controlpanel.py:26
#: ../plugins/facebook/controlpanel.py:30
msgid "Verb to display"
msgstr "Texto a mostrar"

#. Default: "A comma-separated list of either the Facebook IDs of page administrators."
#: ../plugins/facebook/controlpanel.py:40
#: ../plugins/facebook/controlpanel.py:44
#, fuzzy
msgid "help_admins"
msgstr "Una lista de los ID de los administradores de esta página, separados por comas, o el ID de una aplicación de Facebook."

#. Default: "A Facebook Platform application ID."
#: ../plugins/facebook/controlpanel.py:50
#: ../plugins/facebook/controlpanel.py:54
msgid "help_appid"
msgstr ""

#. Default: "Please select which plugins will be used"
#: ../controlpanel/likes.py:47
#: ../controlpanel/likes.py:53
msgid "help_enabled_plugins"
msgstr ""

#. Default: "Select buttons to be shown"
#: ../plugins/facebook/controlpanel.py:63
msgid "help_fbbuttons"
msgstr ""

#. Default: "Please select content types in which the viewlet will be applied."
#: ../controlpanel/likes.py:36
#: ../controlpanel/likes.py:42
msgid "help_portal_types"
msgstr "Seleccione en cuáles tipos de contenido se mostrará el viewlet social."

#. Default: "Choose your button style."
#: ../controlpanel/likes.py:57
#: ../controlpanel/likes.py:63
msgid "help_selected_buttons"
msgstr "Seleccione de la lista."

#. Default: "The verb to display in the facebook button. Currently only 'like' and 'recommend' are supported."
#: ../plugins/facebook/controlpanel.py:27
#: ../plugins/facebook/controlpanel.py:31
msgid "help_verb_display"
msgstr "Texto que se mostrará en el botón de Facebook. De momento sólo 'Me gusta y 'Recomendar' están soportados."

Expand All @@ -132,11 +144,11 @@ msgstr "Texto que se mostrará en el botón de Facebook. De momento sólo 'Me gu
msgid "help_your_twitter_nick"
msgstr "Introduzca su nombre de usuario de Twitter. Ejemplo: simplesconsultoria"

#: ../controlpanel/likes.py:62
#: ../controlpanel/likes.py:32
msgid "horizontal"
msgstr "Horizontal"

#: ../controlpanel/likes.py:63
#: ../controlpanel/likes.py:33
msgid "vertical"
msgstr "Vertical"

Loading