- fix(core): fix Closed and Opened Outputs, closes #367 in fb9bbbb.
- fix(core): fix WhatsApp not opening in Chrome on IOS 12, closes #366 7c77f0a.
- feat(core): Add
debug
option to ShareButtonsConfig to log sharer URL, in 7e47bef. - fix(core): undefined URL in
Email
,SMS
,WhatsApp
buttons, closes #361 in debed2b. - fix(core): Rename
_metaTags
to_supportedMetaTags
inWhatsApp
button, in 52dc70d. - fix(core):
Copy
button, closes #360 in 4010a82. - enhance(core): Warn when
Pinterest
image parameter is undefined, in 8116614. - enhance(core): Update
WhatsApp
sharer URL, in 6dc7414. - regression: Remove URL from
Telegram
message since its already supported, in f10189a.
- Refactor share function to run sync to fix the issue on IOS 12, closes #351 in 05abd1c.
- Remove
StumbUpOn
button and replace it withMix
button. - Remove
forRoot
usage, usewithConfig()
for custom config.
- The function
forRoot()
has been removed from all share modules. ShareButtonConfig
has been flattened.StumbUpOn
share button has been removed.
- regret(PrintOperator): use map instead of tap operator in the print operator, this fix opening share pop up when the print button is clicked, in 74c2396.
- enhance(ShareDirective): Use rxjs interval to poll for window closed event, in 46f897c.
- enhance(ShareDirective): Use
Meta
service instead ofdocument
to get the meta tags content, in 9342b63. - enhance(ShareDirective): Use the CDK
Platform
service to get the platform type, in 55b9495. - enhance(ShareDirective): Query meta tags using property or name, in 55b9495.
- enhance(ShareDirective): Add kebab-case selector, in 55b9495.
- enhance(ShareButton, ShareButtons): Load base styles internally.
- refactor(ShareDirective): Do not auto-set
[via]
input fromtwitter-site
meta tag, in 4bcd5e0. - fix(ShareProps): Fix iOS SMS Share Link, closes #283 in 143aaa7.
- refactor(ShareModule): Provide
ShareButtons
service usingprovidedIn: 'root'
, in b2c698f. - refactor(ShareProps): Remove Reddit share count, in dcef59b.
- Fix and update peerDependencies for Angular >= 6, in 8fd68e1.
-
If you use any of the following classes, they have been renamed:
ShareButtons
service =>ShareService
ShareDirective
directive =>ShareDirective
ShareButtonComponent
component =>ShareButton
ShareButtonsComponent
component =>ShareButtons
-
Reddit share count API seems to be deprecated from their side, therefore share count has been removed from Reddit share button.
-
For
<share-buttons>
and<share-button>
components, no need to import the default styles anymore. -
Also note that the path to themes directory has been flattened (
/styles/
directory has been removed)
@import '~@ngx-share/button/styles/share-buttons'; /** this line is no longer needed */
@import '~@ngx-share/button/styles/themes/modern/modern-dark-theme';
@import '~@ngx-share/button/themes/modern/modern-dark-theme';
- Angular 6 support, closes #274.
- fix(core): Use icon alias name in the share props instead of the icon object itself, closes #280.
- feat(ShareDirective): Add
aria-label
attribute to share buttons, closes #277. - feat(ShareButtons): Enable custom icons for the expand button, remove the hard-coded icons, closes #289.
- refactor(ShareButtons): Call
stateWorker$.complete()
on component destroy. - refactor(ShareButtons): Use
private
on variables and functions when they should be. - Add
CONTRIBUTION.md
for plugin development. - refactor(core): Remove all FontAwesome peer packages dependencies from
"@ngx-share/core
. - refactor(button): Use only
@fortawesome/angular-fontawesome
as a peer dependency for"@ngx-share/button
. - refactor(buttons): Use only
@fortawesome/angular-fontawesome
as a peer dependency for"@ngx-share/buttons
. - refactor(util): Use Observable instead of Promise for
copyToClipboard()
.
- The plugin now uses Angular-FontAwesome library method instead of the "Explicit reference" method to import the icons.
Before:
The plugin used to load the default icons from FontAwesome.
After:
The plugin does not load FontAwesome icons out of the box. The user will have to import them manually
Example:
import { ShareButtonsModule } from '@ngx-share/buttons';
import { library } from '@fortawesome/fontawesome-svg-core';
import { faFacebook } from '@fortawesome/free-brand-svg-icons/faFacebook';
import { faTwitter } from '@fortawesome/free-brand-svg-icons/faTwitter';
import { faLinkedinIn } from '@fortawesome/free-brand-svg-icons/faLinkedinIn';
const icons = [faFacebook, faTwitter, faLinkedinIn];
// Add the icons you want to use
library.add(...icons);
@NgModule({
imports: [
HttpClientModule,
ShareButtonsModule.forRoot()
]
})
NOTE: Use the deep link to import the icon to keep the package size to the minimum, see @robbaman comment in @angular-fontawesome/34.
- fix(ShareButtons): Hide expand button, closes #255 in #256.
- fix(Build Error in 5.3.0): Set css variable on expand button through the component instead of the style, closes #254 in #527.
- clean up styles
- refactor css variable: change $sb-more variable name to $sb-expand
- update FontAwesome peerDependencies
- refactor(ShareButtons): Wrap expand button in its own component.
- fix(ShareDirective): Set custom button color with css variable.
- fix(Universal:ShareDirective): Check for browser platform before creating a share button, closes #251.
- fix(Universal:ShareButton): Check if button.ref is defined in component template, closes #251.
- fix(ShareButton): Share counts are requested even when showCount is false, fixes #253.
- enhancement(Themes): Improve styles.
- enhancement(Share Icons): Icons are now rendered as SVG elements.
- feat(Prop): Add SMS button.
- feat(ShareButton): Add
[icon]
input. - feat(Share Icons): Add only the share buttons icons from FontAwesome instead of all icons, closes #252.
- feat(ShareDirective): Add
[autoSetMeta]
input to all components and global config.
When autoSetMeta
is true, the meta tags inputs url
, title
, description
and image
will be initialized from the SEO meta tags.
set
autoSetMeta
to false, if the share buttons url does not point to the current url, e.g. displaying a list of articles each one with share buttons.
- refactor(ShareButtonsModule): angular-fontawesome has become a peer dependency.
- refactor(Props): Button icon is type of
IconProp
which is imported from the @fortawesome icons package.
Before:
style.scss
@import "~@fortawesome/fontawesome-free-webfonts/css/fa-brands.css";
@import "~@fortawesome/fontawesome-free-webfonts/css/fa-solid.css";
@import "~@fortawesome/fontawesome-free-webfonts/css/fontawesome.css";
@import '~@ngx-share/button/styles/share-buttons';
@import '~@ngx-share/button/styles/themes/default/default-theme';
Override share button icon
ShareButtonsModule.forRoot({
prop: {
facebook: {
icon: 'fa fab-facebook-f'
}
}
}
After:
style.scss
@import '~@ngx-share/button/styles/share-buttons';
@import '~@ngx-share/button/styles/themes/default/default-theme';
Override share button icon
import { faFacebookF } from '@fortawesome/free-brands-svg-icons';
ShareButtonsModule.forRoot({
prop: {
facebook: {
icon: faFacebookF
}
}
}
- refactor(ShareDirective): Remove the prefix
sb
from the share directive inputs, closes #250.
[sbUrl] => [url]
[sbTitle] => [title]
[sbDescription] => [description]
[sbImage] => [image]
[sbTags] => [tags]
(sbCount) => (count)
(sbOpened) => (opened)
(sbClosed) => (closed)
- refactor(ShareButtonsService): Initialize meta tags from document head 'og' meta tags.
- refactor(ShareButtonsService): Add
url
as a meta tag property to the global config. - refactor(ShareDirective): Initialize meta tags inputs from the global config.
- refactor(Props): Add url as meta tag property.
- refactor(Operators): Removes Pinterest operator since description and image meta tags are being set from the service.
- refactor(Operators): Removes None operator since url became part of the meta tags.
- refactor(Operators): Changes
EmailOperator
tourlInMessageOperator
- refactor(Utils): Move
getOS()
andgetValidUrl
to utils file and remove encodeUriComponent. - refactor(Utils): Do not encode the url in
getValidUrl
function since the url becomes a meta tag. - fix(WhatsApp): Adds share URL to message body, closes #239
Now the meta tags are initialized from document head meta tags (og:title, og:description, og:image, og:url) if they exist, This means that if you use SSR you don't need to set them manually.
- feat(ShareButtons): Adds Messenger button (Mobile only), closes #233.
- feat(ShareButtons): Adds Xing button, closes #232.
- feat(ShareButtons): Use FontAwesome 5 icons by default, closes#219.
- fix(operators): Copy button is not working in ios devices, closes #223.
- fix(operators): Copy button tap is causing keypad to open on ios devices.
- fix(ShareButtonsService): Allow adding custom share buttons, closes#222.
- refactor(ShareDirective): Make sure buttons has the sharer link before opening share dialog.
- enhancements(ShareButton, ShareButtons): Remove white spaces from components templates.
- enhancements(ShareButton, ShareButtons): Button color can be customized from prop, no need to override css variables manually.
- enhancements(ShareButton, ShareButtons): Improve themes styles.
- refactor(ShareButtonService): rename the function
registerButton()
toaddButton()
. - Flat and Classic themes are removed.
- Fb Messenger is only made for Mobile web and will not work on Desktop.
- LinkedIn has deprecated the share counts from their API.
- fix: whatsapp sharing fails on mobile, closes #208.
- fix: Encode special characters in meta tags, closes #213.
- refactor: import rxjs operators separately.
- chore: Exports share buttons prop and operators.
- Refactor and clean up ShareButton and ShareButtons components.
- Fix count output in ShareButtons Component.
- Ability to include only the module you use.
- Ability to create a new share button on the fly, closes #187.
- Improve themes styles.
- Decrease bundle size.
- Remove buttons classes and uses dynamic data to create button properties.
- Disable text selection on share buttons.
- Fix double click issue on the copy button.
-
The package is now divided into 3 new subpackages from the scope
@ngx-share
- Share directive
@ngx-share/core
- Single share button
@ngx-share/button
, depends on the@ngx-share/core
- Share buttons
@ngx-share/buttons
, depends on the@ngx-share/core
and@ngx-share/button
- Share directive
-
Global options and button properties are now passed as one object
- Before
ShareButtonsModule.forRoot(options, prop)
- After:
ShareButtonsModule.forRoot({ options, prop })
- Before
[showName]
input is renamed to[showText]
in<share-button>
and<share-buttons>
- Custom template is deprecated in
<share-button>
, you can now set custom text using the input[text]
- Styles and themes are now imported from
@ngx-share/button/styles/
package. - Remove
outline
andspecial
themes.
- refactor(buttons style): improve icon styles
- refactor(themes): fix themes issues and styles warnings, closes #182.
- recompile package with ng 5, closes , closes #181.
- refactor(GoogleButton) remove count code for Google+ after the their removal of the counts
- fix(Themes) fix themes tasks, Include compiled css files in the package
- feat(New themes) Include more themes with the package.
- refactor(ShareButtons) remove text from more & less buttons.
Breaking Change:
- fix(prevent overwritting interceptors) closes #174.
Now HttpClientModule
and HttpClientModule
should imported manually
import { ShareButtonsModule } from 'ngx-sharebuttons';
@NgModule({
imports: [
HttpClientModule,
HttpClientJsonpModule,
ShareButtonsModule.forRoot()
]
})
- fix(using global options in AOT)
- Add scss and css styles into dist package
- fix(switching button type) remove old button class
- fix wrong rollup config for HttpClientModule
- add default styles in the dist package
- fix(Universal support) Add UniversalSupportService to be used internally
- refactor(ShareDirective)
- add
gaTracking
option to global options - update online docs
Version 4 has been rewritten from scratch
- Major improvements: The list is long, just check the demo
- Provide 3 different modules, import only what you use
- Use
HttpClient
for fetching share counts instead ofHttp
, (requires Angular +4.3) - Add new buttons for Telegram, Email, Print, Copy link
- Improve documentations
- License is now GPL-3.0
Version 3 is no longer supported
- Rename npm package to
ngx-sharebuttons
. - Update peerDependencies.
- fix(popup window) removes the error for users who have block popup extension, closes #116.
- (fix) sharing on mobile browser [#97]
- (enhacement) refactor default style
- (feat) Sharebutton will open the corresponding app on mobile #79
- (fix) Whatsapp button will open web.whatsapp on Desktop closes #67
- (fix) replaces
:root
with:host
in style fixes #81
- (feat) Whatsapp button
- (feat) Sharebutton Directive
- (refactor) New button style for Sharebuttons Component
- (fix) update count when URL changes
- (fix) update all inputs on changes
- (feat) support systemJS
- Breaking Changes :
- Sharebutton component is for internal use only, use Sharebutton directive instead.
[shareTitle]
,[totalCount]
, deprecated.
- merge [#26](https://github.com/MurhafSousli/ngx-sharebuttons/pull/26)
- Fixes Bug:
- Publish
./dist
instead of root dir, closes #22
- Publish
-
New Feature:
-
Fixes Bug:
- Update dependencies and remove hard version in package.json
-
New Feature:
- Add
popUpClosed
function<share-buttons (popUpClosed)="someCallbackFunction">
, closes #12
- Add
-
Improvements:
- Import
Observable
,empty
,catch
,map
operators individually instead of importing the whole library - Wrap window object in
WindowService
- Import
-
Fixes Bug:
-
Breaking Changes:
- twitter tags are now seperated by comma as a string instead of string[]:
- before:
<share-buttons [tags]="['hello','world']">
- after:
<share-buttons [tags]="'hello, world'">
- twitter tags are now seperated by comma as a string instead of string[]:
-
New Feature:
- Now you can set
[title]
,[description]
and[image]
if you don't want to use the meta tags, check full list of inputs in the docs, closes #7.
- Now you can set
-
Fixes Bug:
- Count: handle facebook share count error, closes #8.
- Share: Check if the input
[url]
is valid.
-
Breaking Changes:
- The following inputs has new names now:
- before:
[text]
, After:[description]
. - before:
[hashtags]
, After:[tags]
.
- before:
- The following inputs has new names now:
- Improve Performance : Now ShareButton uses
ChangeDetectionStrategy.OnPush
.
-
New Feature: Set global twitter account to add "Via @twitterAccount" to user tweet.
-
New Feature: New optional inputs
[text]
,[image]
and[hastags]
for twitter and pinterest. -
Fixes Bug: Pinterest share link.
Stable release
- refactor(GoogleButton) the share count for Google+ is no longer available
- fix(Themes) fix themes tasks, Include compiled css files in the package
- feat(New themes) Include more themes with the package.
- refactor(ShareButtons) remove text from more & less buttons.
Breaking Change:
- fix(prevent overwritting interceptors) closes #174.
Now HttpClientModule
and HttpClientModule
should imported manually
import { ShareButtonsModule } from 'ngx-sharebuttons';
@NgModule({
imports: [
HttpClientModule,
HttpClientJsonpModule,
ShareButtonsModule.forRoot()
]
})
- fix(using global options in AOT)
- Add scss and css styles into dist package
- fix(switching button type) remove old button class
- fix wrong rollup config for HttpClientModule
- add default styles in the dist package
- fix(Universal support) Add UniversalSupportService to be used internally
- refactor(ShareDirective)
- add
gaTracking
option to global options - update online docs
Version 4 has been rewritten from scratch
- Major improvements: The list is long, just check the demo
- Provide 3 different modules, import only what you use
- Use
HttpClient
for fetching share counts instead ofHttp
, (requires Angular +4.3) - Add new buttons for Telegram, Email, Print, Copy link
- Improve documentations
- License is now GPL-3.0
Version 3 is no longer supported
- Rename npm package to
ngx-sharebuttons
. - Update peerDependencies.
- fix(popup window) removes the error for users who have block popup extension, closes #116.
- (fix) sharing on mobile browser [#97]
- (enhacement) refactor default style
- (feat) Sharebutton will open the corresponding app on mobile #79
- (fix) Whatsapp button will open web.whatsapp on Desktop closes #67
- (fix) replaces
:root
with:host
in style fixes #81
- (feat) Whatsapp button
- (feat) Sharebutton Directive
- (refactor) New button style for Sharebuttons Component
- (fix) update count when URL changes
- (fix) update all inputs on changes
- (feat) support systemJS
- Breaking Changes :
- Sharebutton component is for internal use only, use Sharebutton directive instead.
[shareTitle]
,[totalCount]
, deprecated.
- merge [#26](https://github.com/MurhafSousli/ngx-sharebuttons/pull/26)
- Fixes Bug:
- Publish
./dist
instead of root dir, closes #22
- Publish
-
New Feature:
-
Fixes Bug:
- Update dependencies and remove hard version in package.json
-
New Feature:
- Add
popUpClosed
function<share-buttons (popUpClosed)="someCallbackFunction">
, closes #12
- Add
-
Improvements:
- Import
Observable
,empty
,catch
,map
operators individually instead of importing the whole library - Wrap window object in
WindowService
- Import
-
Fixes Bug:
-
Breaking Changes:
- twitter tags are now seperated by comma as a string instead of string[]:
- before:
<share-buttons [tags]="['hello','world']">
- after:
<share-buttons [tags]="'hello, world'">
- twitter tags are now seperated by comma as a string instead of string[]:
-
New Feature:
- Now you can set
[title]
,[description]
and[image]
if you don't want to use the meta tags, check full list of inputs in the docs, closes #7.
- Now you can set
-
Fixes Bug:
- Count: handle facebook share count error, closes #8.
- Share: Check if the input
[url]
is valid.
-
Breaking Changes:
- The following inputs has new names now:
- before:
[text]
, After:[description]
. - before:
[hashtags]
, After:[tags]
.
- before:
- The following inputs has new names now:
- Improve Performance : Now ShareButton uses
ChangeDetectionStrategy.OnPush
.
-
New Feature: Set global twitter account to add "Via @twitterAccount" to user tweet.
-
New Feature: New optional inputs
[text]
,[image]
and[hastags]
for twitter and pinterest. -
Fixes Bug: Pinterest share link.
Stable release