Secure your code as it's written. Use Snyk Code to scan source code in minutes - no build needed - and fix issues immediately.
get tabIds () {
// cache tab ids for better performance and to prevent errors with animations
const ids = this._tabIds || []
let diff = ids.length - this.tabs.length
while (diff++ < 0) {
ids.push(uid('Tab'))
}
this._tabIds = ids
return ids
}
createScreenreaderAlert () {
const liveRegion = this.getLiveRegion()
if (liveRegion) {
this.srid = uid('Alert')
const div = document.createElement('div')
div.setAttribute('id', this.srid)
const content = this.createScreenreaderContentNode()
ReactDOM.render(content, div)
liveRegion.appendChild(div)
}
}
constructor (props) {
super()
this._id = uid('CodeEditor')
if (typeof props.value === 'undefined') {
this.state = {
value: props.defaultValue
}
}
}
constructor () {
super()
this.titleId = uid('InlineSVG-title')
this.descId = uid('InlineSVG-desc')
}
constructor (props) {
super(props)
this.defaultId = uid('FileDrop')
this.messagesId = uid('FileDrop-messages')
}
constructor (props) {
super(props)
this.state = {
focus: false,
highlightedIndex: this.getSelectedIndex(props),
expanded: false,
positioned: false
}
this._defaultId = uid('Select')
this._optionsId = uid('Select-Options')
this._assistId = uid('Select-assistiveText')
}
constructor () {
super()
this.titleId = uid('InlineSVG-title')
this.descId = uid('InlineSVG-desc')
}
constructor (props) {
super(props)
this.defaultId = uid('FileDrop')
this.messagesId = uid('FileDrop-messages')
}
constructor (element, options) {
this._options = options || {
shouldCloseOnDocumentClick: true,
shouldCloseOnEscape: true,
onDismiss: (event) => {}
}
this._contextElement = element
this._screenReaderFocusRegion = new ScreenReaderFocusRegion(element, options)
this._keyboardFocusRegion = new KeyboardFocusRegion(element, options)
this._id = uid()
}
constructor (props) {
super(props)
this._id = this.props.id || uid('Menu')
}