Premium support for our pure JavaScript UI components


Post by luisbulaong »

Hi,

I'm trying to set the position of the tooltip on a certain X and Y but it is not doing anything.

Selection_790.png
Selection_790.png (52.15 KiB) Viewed 801 times

Thanks,


Post by alex.l »

Hi luisbulaong,

Basically it doesn't work for anchored tooltips that created for a special widget.
You have to create your own Tooltip to position it independently.

new Tooltip({
    floating : true,
    html     : 'Hello',
    x        : 100,
    y        : 100
}).show();

Thanks for your question, we will update our docs with this information.

All the best,
Alex

All the best,
Alex


Post by luisbulaong »

Hi Alex,

I also tried creating new tooltip, though I think it still does not work. The goal by the way is to always show the tooltip at the bottom of the screen. Is it doable using x and y?

Thanks,
luisbulaong


Post by alex.l »

What exactly doesn't work for you? Did you try my example? It works to me.
You can show tooltips at the bottom of the screen but better to use https://bryntum.com/docs/scheduler/#Core/widget/Tooltip#function-showBy and specify offset, align and target properties as you need. Maybe target it to your main container or like that.

All the best,
Alex


Post by luisbulaong »

Your example worked for me too. Now, I'm trying to use the showBy property but nothing is happening. Not sure if I'm doing it right

new Tooltip({
    html     : 'Hello',
    showBy: {
      spec: {
        target: ".div",
        anchor: true 
      }
    }
}).show();

Post by mats »

showBy is a method - not a config. Please refer to docs: https://bryntum.com/docs/scheduler/#Core/widget/Tooltip#function-showBy


Post Reply