in the following code is there a way to stop the text from overflowing the Rect?
const rectNormal = clipRectByRect(params, { x: x, y: y, width: barLength, height: barHeight, z: type === 'ja-rollout' || type === 'marker-column' ? 99 : 1, }); const rectVIP = clipRectByRect(params, { x: x, y: y, width: barLength / 2, height: barHeight, }); const rectText = clipRectByRect(params, { x: x, y: y, width: barLength, height: barHeight, }); return { type: 'group', children: [ { type: 'rect', ignore: !rectNormal, shape: rectNormal, style: api.style({ fill: color ? color : '#008d6c', }), }, { type: 'rect', ignore: !rectVIP && !api.value(4), shape: rectVIP, style: api.style({ fill: color ? color : '#008d6c', }), }, { type: 'rect', name: 'mainBar', ignore: !rectText, shape: rectText, overflow: 'truncate', style: api.style({ fill: 'transparent', stroke: 'transparent', text: showText ? text : '', overflow: 'truncate', textFill: '#fff', }), }, ], };