MCPcopy Index your code
hub / github.com/bqplot/bqplot / update_default_size

Method update_default_size

js/src/Scatter.ts:190–210  ·  view source on GitHub ↗
(animate)

Source from the content-addressed store, hash-verified

188 }
189
190 update_default_size(animate) {
191 this.compute_view_padding();
192 // update size scale range?
193 if (!this.model.dirty) {
194 const animation_duration =
195 animate === true ? this.parent.model.get('animation_duration') : 0;
196 const that = this;
197 this.d3el
198 .selectAll('.dot')
199 .transition('update_default_size')
200 .duration(animation_duration)
201 .attr(
202 'd',
203 this.dot.size((d) => {
204 return that.get_element_size(d);
205 })
206 );
207 // Label positions also need to change
208 this.update_names(animate);
209 }
210 }
211
212 update_names(animate) {
213 const that = this;

Callers

nothing calls this directly

Calls 3

update_namesMethod · 0.95
get_element_sizeMethod · 0.80
compute_view_paddingMethod · 0.45

Tested by

no test coverage detected