Giter VIP home page Giter VIP logo

svooltip's People

Contributors

gibbu avatar nika-d avatar ollema avatar suyooo avatar ungvert avatar

Stargazers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

Watchers

 avatar  avatar

svooltip's Issues

Tootltips stay forever

Rapid pointer movement over a tooltipped element causes the tooltip to stay displayed forever.

The delay parameter only delays displaying the tooltip, but the event is always fired.

feature request: update content after delay

hi!

thanks for creating svooltip, I use it in nearly all of my svelte projects.


sometimes, I find that it would have been useful to different content in the tooltip depending on how long it has been hovered.

say that first you could display:

<username>

but after for example 1 seconds, the content would change to:

<username>
<status>
<bio>
<email>

I hope you get my idea, if not I would be happy to expand on this

[Improvement] Change the z-index value

Hello there!

I really enjoy this library, although I have one improvement that I'd suggest (if possible), I'm having problems in relation to the z-index value, looking at the scss files it looks to be set to 1, some of my other components have higher z-indexes, which cause them to overlap the tooltips and look clipped.

Is it possible for a simple adjustment of the value from 1 to another value?

Thanks.

Data-placement parameter doesn't seem to work.

I tested using the data-placement param in .scss file, but it seems like it is not working. I tried the following code:

.svooltip[data-placement='top'] {
  --svooltip-bg: white;
  border: 1px solid red;
}
.svooltip[data-placement='bottom'] {
  --svooltip-bg: black;
  border: 1px solid blue;
}

For me it seems like a bug, or do I do something wrong?

Unable to import default styling after updating to 0.4.2

Hi!

After updating from 0.3.0 to 0.4.2 I am unable to import the default styling.

Both import 'svooltip/styles.css'; and import 'svooltip/svooltip.css'; gives me:

1:35:06 PM [vite] Internal server error: Missing "./styles.css" export in "svooltip" package

I am using a pretty standard svelte kit setup with tailwindcss and postcss enabled.

Let me know if I can provide more details.

System:
    OS: Linux 5.4 Ubuntu 20.04.4 LTS (Focal Fossa)
    CPU: (8) x64 Intel(R) Xeon(R) Platinum 8268 CPU @ 2.90GHz
    Memory: 24.23 GB / 31.33 GB
    Container: Yes
    Shell: 5.0.17 - /bin/bash
  Binaries:
    Node: 18.11.0 - ~/.local/share/pnpm/node
    npm: 8.19.2 - ~/.local/share/pnpm/npm
  Browsers:
    Firefox: 107.0
  npmPackages:
    @sveltejs/adapter-node: 1.0.0-next.104 => 1.0.0-next.104 
    @sveltejs/kit: 1.0.0-next.583 => 1.0.0-next.583 
    @tailwindcss/forms: ^0.5.3 => 0.5.3 
    @types/sharp: ^0.31.0 => 0.31.0 
    @typescript-eslint/eslint-plugin: ^5.46.0 => 5.46.0 
    @typescript-eslint/parser: ^5.46.0 => 5.46.0 
    autoprefixer: ^10.4.13 => 10.4.13 
    eslint: ^8.29.0 => 8.29.0 
    eslint-config-prettier: ^8.5.0 => 8.5.0 
    eslint-plugin-svelte3: ^4.0.0 => 4.0.0 
    postcss: ^8.4.20 => 8.4.20 
    prettier: ^2.8.1 => 2.8.1 
    prettier-plugin-svelte: ^2.9.0 => 2.9.0 
    sharp: ^0.31.2 => 0.31.2 
    svelte: ^3.54.0 => 3.54.0 
    svelte-check: ^2.10.2 => 2.10.2 
    svooltip: ^0.4.2 => 0.4.2 
    tailwindcss: ^3.2.4 => 3.2.4 
    tslib: ^2.4.1 => 2.4.1 
    typescript: ^4.9.4 => 4.9.4 
    vite: ^4.0.0 => 4.0.0 

HTML in tooltip?

I would like to use HTML formatted strings in the tooltip content but not sure how to do so.

If that's not possible yet, I would like to request it as an optional param e.g. format: "raw" | "html" that will internally use Svelte's {@html ... }

Use Sass for basic styling

Dear @Gibbu , Thank you so much for this minimalistic tooltip, I love it! 😃

In our project, we use Sass and try to optimize the css output. Svooltip currently provides the basic styling only as css. Because of that, no matter how we @use oder @import the styles, we will always have some default values in our delivered css. For example the value var(--svooltip-bg, #444) will be delivered no matter what.

We would like to avoid that. That´s why I would be glad to get the styles in Sass already.

I think, it fits quite well to the minimalistic approach, because sass is already a dependency of the Svooltip project. So its just a little refactoring, not really adding anything new.

I will implement that myself and make a pull request.

Do not show tooltip when `content` is `null`

There is no way in Svelte to optionally use the use direction. I would like to conditionally show/hide my tooltip, but currently there is no way to do that. The package leaves behind "arrow" element when content is null.

Would it be possible to either add new option to enable/disable the tooltip or simply don't show the tooltip when content is null?

image

Tooltip "arrow" is left behind when content is null
image

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.