Efficient way to query partial superscript

With recent update, we can access superscript property of text layers via getRangeOpenTypeFeatures. However, in most situations I encountered, superscript content is only very small portion of a paragraph. getRangeOpenTypeFeatures will give figma.mixed for text block which contains text with and without superscript at the same time. To accurately get which portion of text is superscript, we need to iterate characters one by one and check for SUPS: true.

However, there is getStyledTextSegments which enables batch query of styled text (e.g. font name, font size) and returns an array of properties.

It would be great we can access some API which is similar to this?

getStyledTextSegments works with openTypeFeatures.

Good to know. Didn’t see the doc being updated.