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

Adding support for images as markers #694

Closed
PwnPeter opened this issue Feb 4, 2021 · 9 comments
Closed

Adding support for images as markers #694

PwnPeter opened this issue Feb 4, 2021 · 9 comments
Labels
enhancement Feature requests, and general improvements. need more feedback Requires more feedback. plugin This feature request should/could be implemented as a Plugin.

Comments

@PwnPeter
Copy link

PwnPeter commented Feb 4, 2021

Hi !
Just a small idea that could be very useful to customize your own markers would be to be able to define an image in addition to the available shapes.

@timocov timocov added enhancement Feature requests, and general improvements. need more feedback Requires more feedback. labels Feb 5, 2021
@thanhlmm
Copy link

For more customization, I think it should work something like we're doing with tooltip.
Subscribe to the event if the marker is available for showing -> give dev with position, status,... then they're free to display what ever he want

@lauris
Copy link

lauris commented Aug 17, 2021

This and more flexibility for custom styling of lines/markers/labels would be highly appreciated.

@timocov
Copy link
Contributor

timocov commented Aug 18, 2021

Don't forget to put your 👍 to the first message 😉

@thanhlmm
Copy link

I intend to do this by subscribing to time range change and draw it by html/CSS. Currently, I don't see any more benefit if the chart support it natively like what we're doing with tooltip

@zouxuoz
Copy link

zouxuoz commented Oct 4, 2021

It would be great addition

@zouxuoz
Copy link

zouxuoz commented Oct 11, 2021

@timocov can I help with implementation?

@SlicedSilver
Copy link
Contributor

Thank you for your feature request for Lightweight Charts. In order to keep the library lightweight and maintain a narrow focus, we strive to include only strictly required features in the core library. As a result, we have decided that this requested feature should be implemented as a plugin instead, and will be closing this issue as a result.

We recently introduced the ability to write plugins for Lightweight Charts, allowing users like you to extend the functionality of the library without adding it to the core. We highly recommend implementing your feature request as a plugin to achieve the desired functionality while keeping the core bundle size smaller for all users.

To get started with plugins, please refer to our Plugins Documentation for a better understanding of what is possible and how plugins work. You can also explore our collection of plugin examples (with a preview hosted here) for inspiration and guidance on implementing specific functionality.

For your particular feature request, we suggest taking a look at the following examples (see above links):

  • Image Watermark (how to render an image)
  • Expiring Price Alerts (how to draw a shape on a specific price and time coordinate).

To help you get started quickly, we have created an NPM package called create-lwc-plugin, which sets up a plugin project for you. This way, you can hit the ground running with your plugin development.

If you do create a plugin based on your feature request, we would appreciate it if you could publish it on GitHub or NPM and let us know. This way, we can share it with the rest of the community. It would be helpful if you could prefix your NPM package name with lwc-plugin- for easier discoverability by others.

Thank you for your understanding and support. We believe implementing your feature request as a plugin will greatly benefit both you and the Lightweight Charts community.

@SlicedSilver SlicedSilver added the plugin This feature request should/could be implemented as a Plugin. label Oct 4, 2023
@m0rtyn
Copy link

m0rtyn commented Oct 26, 2023

You guys are having a name collision for the lwc-plugin prefix. There is the Lightning Web Components from Saleforce. This makes it difficult to find other ready-made plugins for your chart.

image

@SlicedSilver
Copy link
Contributor

Most of those search results are plugin-lwc or lwc-*-plugin which aren't an exact match for the prefix of lwc-plugin-*.

Checking the keyword on NPM, shows only lightweight chart plugins (they are new so there is only 1 so far...): https://www.npmjs.com/search?q=keywords:lwc-plugin

We could think about using lwchart-plugin- or lw-chart-plugin- instead as that appears to be more unique.

So in summary, lwc-plugin- prefix does appear to be unique, but fuzzy searching will include results for packages with similar names.

@tradingview tradingview deleted a comment from avinmaster Sep 19, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
enhancement Feature requests, and general improvements. need more feedback Requires more feedback. plugin This feature request should/could be implemented as a Plugin.
Projects
None yet
Development

No branches or pull requests

7 participants