Giter Site home page Giter Site logo

Comments (9)

MurhafSousli avatar MurhafSousli commented on May 30, 2024

Yupp, you get the clicked button, but only after the window gets closed

<share-buttons (popUpClosed)="yourFun($event)">
yourFun(clickedButton: ShareProvider){

}

I'm not sure what you are trying to accomplish! if this doesn't work for you, check the advanced usage section for adding single tweet button and configure the description input the way you want

from ngx-sharebuttons.

doorman02 avatar doorman02 commented on May 30, 2024

Hi @MurhafSousli thanks for your help. The popUpClosed event is triggered after sharing. I need an event before the popup opens, so I can change the description before it´s displayed in the sharing dialog that is an event when the share icon button is clicked. Is this possible?

Thanks!

from ngx-sharebuttons.

MurhafSousli avatar MurhafSousli commented on May 30, 2024

@doorman02 Currently this is not possible out of the box, but you can still do it the way I stated above ☝️

from ngx-sharebuttons.

doorman02 avatar doorman02 commented on May 30, 2024

Do you mean I can somehow change the description before the popup opens?
It would be nice if it would be possible out of the box because different sharing services have different text limits and such. Thanks again for this great plugin :)

from ngx-sharebuttons.

MurhafSousli avatar MurhafSousli commented on May 30, 2024

@doorman02 Now I got it, I think we can fix the tweet's text limit issue, but it's not possible to filter the description before window opens from the ShareButtons component, and it would be too specific if you made this possible for the inner component ShareButton

from ngx-sharebuttons.

doorman02 avatar doorman02 commented on May 30, 2024

Thanks @MurhafSousli for your help. To further explain my use case. I have some important information in the title field and then more information in the description field. This fits well for Facebook sharing dialog. But Twitter doesn´t use the title field, in that case I would like to move the important information from the title to the description field. I am sure there will be similar use cases for the other sharing services. That´s why I was wondering if it was possible to modify the title, description fields on the fly depending on the pressed ShareButton before the sharing dialog opens.

from ngx-sharebuttons.

MurhafSousli avatar MurhafSousli commented on May 30, 2024

@doorman02 Have you checked the advanced usage I told you about?
You will be able to that if you added the share button individually, don't use <share-buttons>, instead use <share-button [description]="customTweetText">
Please read the guide to learn how to initialize a single share button.

If you have got an out of the box solution, please submit your PR and we will review it

from ngx-sharebuttons.

doorman02 avatar doorman02 commented on May 30, 2024

I see, ok thanks I will have a better look :)

from ngx-sharebuttons.

MurhafSousli avatar MurhafSousli commented on May 30, 2024

:) I'm closing this one now, and opening the tweet text limit issue in separate thread

from ngx-sharebuttons.

Related Issues (20)

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.