src/pyams_content/features/share/interfaces.py
changeset 1239 b6d9396beffd
parent 1138 6de2ab88b4fe
child 1247 2b1abe98ff47
equal deleted inserted replaced
1238:6c23614804f2 1239:b6d9396beffd
    12 
    12 
    13 __docformat__ = 'restructuredtext'
    13 __docformat__ = 'restructuredtext'
    14 
    14 
    15 from zope.container.constraints import containers, contains
    15 from zope.container.constraints import containers, contains
    16 from zope.interface import Attribute, Interface
    16 from zope.interface import Attribute, Interface
    17 from zope.schema import Bool, Choice
    17 from zope.schema import Bool, Choice, TextLine
    18 
    18 
       
    19 from pyams_content import _
    19 from pyams_content.interfaces.container import IOrderedContainer
    20 from pyams_content.interfaces.container import IOrderedContainer
    20 from pyams_content.reference.pictograms.interfaces import SELECTED_PICTOGRAM_VOCABULARY
    21 from pyams_content.reference.pictograms.interfaces import SELECTED_PICTOGRAM_VOCABULARY
    21 from pyams_i18n.schema import I18nTextLineField
    22 from pyams_i18n.schema import I18nTextLineField
    22 
    23 
    23 from pyams_content import _
    24 
       
    25 SOCIAL_SHARE_INFO_KEY = 'pyams_content.social_share.info'
       
    26 SOCIAL_SHARE_MANAGER_KEY = 'pyams_content.social_share'
    24 
    27 
    25 
    28 
    26 SOCIAL_SHARE_MANAGER_KEY = 'pyams_content.social_share'
    29 class ISocialShareInfo(Interface):
       
    30     """General social share information interface"""
       
    31 
       
    32     twitter_account = TextLine(title=_("Twitter account"),
       
    33                                description=_("Name of Twitter account (including leading '@') to use for website "
       
    34                                              "attribution"),
       
    35                                required=False)
       
    36 
       
    37     twitter_creator_account = TextLine(title=_("Contents creator account"),
       
    38                                        description=_("You can use another Twitter account (including leading '@') "
       
    39                                                      "for contents attribution; if empty, general Twitter account "
       
    40                                                      "will be used"),
       
    41                                        required=False)
    27 
    42 
    28 
    43 
    29 class ISocialShareItem(Interface):
    44 class ISocialShareItem(Interface):
    30     """Social network share item interface"""
    45     """Social network share item interface"""
    31 
    46