MCPcopy
hub / github.com/kenberkeley/react-demo / Collapse

Function Collapse

static/bootstrap/js/bootstrap.js:548–562  ·  view source on GitHub ↗
(element, options)

Source from the content-addressed store, hash-verified

546 // ================================
547
548 var Collapse = function (element, options) {
549 this.$element = $(element)
550 this.options = $.extend({}, Collapse.DEFAULTS, options)
551 this.$trigger = $('[data-toggle="collapse"][href="#' + element.id + '"],' +
552 '[data-toggle="collapse"][data-target="#' + element.id + '"]')
553 this.transitioning = null
554
555 if (this.options.parent) {
556 this.$parent = this.getParent()
557 } else {
558 this.addAriaAndCollapsedClass(this.$element, this.$trigger)
559 }
560
561 if (this.options.toggle) this.toggle()
562 }
563
564 Collapse.VERSION = '3.3.5'
565

Callers

nothing calls this directly

Calls 1

$Function · 0.85

Tested by

no test coverage detected