D3, Change the style of collapsible tree attribute - css

Im trying to do an OrgChart using d3 , i decided to use this tree Collapsible tree, so i want to remove the circles and apply my own style on the tree like adding borders to each title, change background color and so on...
Is there is any way i can do it ? if not do you suggest any other approach to create interactive organizational chart?

You cannot add borders and backgrounds to text, at least directly.
You can add some rectangles behind the text elements and style them as you want.
The issue with this approach is that you need to compute the text size for each element, so you size the rectangles properly.
You can make it a try and post your specific questions here.

Related

How to make this type of shape in react

I want to create this shape in react. I am able to code some of the parts but the border is creating issues.
Image Link here
What I am able to produce
Yo can use z-index property to achieve it.Set the z-index of vertical line to higher number than horizontal line and make sure both overlap each other at there intersection point.

r googleVis: How to control html tooltips (positioning, border and background)

I have figured out how to create custom html tooltips by using roles via googleVis. I can easily modify the content using html but I cannot understand how I can control the tooltip box itself.
My problem was generated because some of the custom tooltips I created are falling outside my chart area and I tried (unsuccessfully) to find a way to control the tooltip position. Idealy I would like to make them behave in the exact same way default tooltips behave in googleVis (always stay withinin the chart area).
When I later implemented the same concept into a line chart I found that I have another problem as well. The tooltip is falling on the line so I cannot see what is the exact point that refers to the tooltip.
Would it be possible for example to keep the callout style of default googleVis tooltip and change the content with HTML?
Additionally, do you know if there is any way to control more tooltip properties like border and background color?
i was also looking for the same
1) when laying out your data, make sure it has columns alternating between, say, data and tooltips, data and tooltips,... that way it is possible to customize tooltips for multiple columns (it does not work if you just append - à la cbind - a set of tooltips columns to your data frame).
Additionally try this http://rcharts.io/viewer/?6644957#.VHcpEkvrdbg

Unable to style a cell tooltip of ngGrid

I am trying to add a tooltip to my cells. Using the title attribute works, but the style is different from the rest of the page (bootstrap styling) http://i.stack.imgur.com/PQMmj.png
Changing the title attribute to tooltip doesn't work - it looks like it hides the tooltip under the next cell (changing the coordination of the tooltip to something within the range of the cell, made it partially visible).
(I am new so I cant post images, https://github.com/angular-ui/ng-grid/issues/800 )
Any idea whats wrong?
Thank you.

smartgwt highlighting Tree node text

I want to highlight/ change color of the text of a tree node in smartgwt. I tried TreeGrid.selectRecord(node) which works, but this creates a background for the width of the tree.
I just want to highlight the text(title of the node) or change the text color of the title of the node.
Can this be done?
You can use the following:
treeNode.setCustomStyle(stylename);
You may also take a look at this link.

Place grid over map using CSS?

I have a world map image. I would like to place a SQUARE GRID over the entire map. I would like each square (cell grid) to change via mouseover with a border color change and background color change.
The grid needs to be layered over the map, transparent except the borders (which is the grid).
Can I achieve this using CSS or there a better way to do this?
Many thanks.
Erik
I'd suggest using a CSS grid framework as an easy way to produce the grid layout. I'd go for this one as you can easily use create a grid with 0px gutters.
You will need to modify the CSS to make the grid absolute positioned so it sits over the top of your map.
Each element in the grid is a DIV so you can easily attach Javascript events to each one to allow users to control the map. If it's a simple colour change on hover then just use css.
You can make the grid transparent using css too: http://css-tricks.com/css-transparency-settings-for-all-broswers/

Resources