Social Sharing JavaScript API: Instance Settings

These settings define the activity, description, and type of sharing to be enabled. They may be defined on any HTML element with the class janrainSocialPlaceholder as data-janrain-* attributes. These settings will override the corresponding settings defined globally in the JavaScript object janrain.settings.social.

Example:

<div
 class="janrainSocialPlaceholder"
 data-janrain-url="http://www.google.com/"
 data-janrain-title="Share this!"
 data-janrain-description="This is a cool thing"
 data-janrain-image="http://www.coolmath.com/fractals/images/fractal11.gif"
 data-janrain-message="Hey come look at this amazing thing!"
></div>

description

Datatype: string

The description that appears in the preview of the shared object. Not editable by the user.

form-factor

Default Value: bar

Overrides: formFactor

Datatype: string

See the Social Sharing JavaScript API: Global Settings section for details. This value will override anything set for janrain.settings.social.formFactor.

image

Datatype: string

The full URL path to an image associated with the content being shared.

message

Datatype: string

The preset text populated in the message that users may edit when sharing content.

mode

Default: broadcast

Datatype: string

Available values are broadcast or contact. Determines whether the share activity will be posted to the user’s own wall or stream or to specified contacts through the provider. Providers available in contact mode are:

  • LinkedIn
  • Mixi
  • Twitter
  • Xing
  • all email providers

orientation

Default: horizontal

Overrides: orientation

Datatype: string

See the Social Sharing JavaScript API: Global Settings section for details. This value will override anything set for janrain.settings.social.orientation.

providers

Overrides: providers

Datatype: array

See the Social Sharing JavaScript API: Instance Settings section for details. This value will override anything set for janrain.settings.social.providers.

share-count-min

Default: -1

Overrides: shareCountMin

Datatype: integer

See the Social Sharing JavaScript API: Instance Settings section for details. This value will override anything set for janrain.settings.social.shareCountMin.

share-count-mode

Default: none

Overrides: shareCountMode

Datatype: string

See the Social Sharing JavaScript API: Global Settings section for details. This value will override anything set for janrain.settings.social.shareCountMode.

shortenUrl

Default: true

Datatype: boolean

Available values are true or false. By default, shared URLs will be shortened with the rpx.me domain or a custom URL shortening service if configured in the Social Login dashboard. See Social Login Overview for more information.

subject

Datatype: string

The subject line to be used for an email share. If not specified, title will be used as the subject line.

title

Datatype: string

The title given to the shared content.

url

Datatype: string

The URL associated with the content being shared.