Welcome to mirror list, hosted at ThFree Co, Russian Federation.

github.com/twbs/bootstrap.git - Unnamed repository; edit this file 'description' to name the repository.
summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorGeoSot <geo.sotis@gmail.com>2021-12-01 15:53:56 +0300
committerGitHub <noreply@github.com>2021-12-01 15:53:56 +0300
commit44a6cd724c0a5c5247492fdb8db7d4df4705641e (patch)
tree0efd605f370c3e88dbd3e82a40ab2faca856566d
parent2fe90d8b1652df283c291f1ab71906e1d8bd105c (diff)
Tooltip: remove leftover method (#35440)
Remove a leftover after #32692 Co-authored-by: XhmikosR <xhmikosr@gmail.com>
-rw-r--r--js/src/tooltip.js12
-rw-r--r--js/tests/unit/tooltip.spec.js34
2 files changed, 0 insertions, 46 deletions
diff --git a/js/src/tooltip.js b/js/src/tooltip.js
index 29be4d8d26..d0b43dd046 100644
--- a/js/src/tooltip.js
+++ b/js/src/tooltip.js
@@ -398,18 +398,6 @@ class Tooltip extends BaseComponent {
return this._resolvePossibleFunction(this._config.title) || this._element.getAttribute('title')
}
- updateAttachment(attachment) {
- if (attachment === 'right') {
- return 'end'
- }
-
- if (attachment === 'left') {
- return 'start'
- }
-
- return attachment
- }
-
// Private
_initializeOnDelegatedTarget(event, context) {
return context || this.constructor.getOrCreateInstance(event.delegateTarget, this._getDelegateConfig())
diff --git a/js/tests/unit/tooltip.spec.js b/js/tests/unit/tooltip.spec.js
index 87f6c0a10a..19eeca2f52 100644
--- a/js/tests/unit/tooltip.spec.js
+++ b/js/tests/unit/tooltip.spec.js
@@ -1083,40 +1083,6 @@ describe('Tooltip', () => {
})
})
- describe('updateAttachment', () => {
- it('should use end class name when right placement specified', done => {
- fixtureEl.innerHTML = '<a href="#" rel="tooltip" title="Another tooltip">'
-
- const tooltipEl = fixtureEl.querySelector('a')
- const tooltip = new Tooltip(tooltipEl, {
- placement: 'right'
- })
-
- tooltipEl.addEventListener('inserted.bs.tooltip', () => {
- expect(tooltip.getTipElement()).toHaveClass('bs-tooltip-auto')
- done()
- })
-
- tooltip.show()
- })
-
- it('should use start class name when left placement specified', done => {
- fixtureEl.innerHTML = '<a href="#" rel="tooltip" title="Another tooltip">'
-
- const tooltipEl = fixtureEl.querySelector('a')
- const tooltip = new Tooltip(tooltipEl, {
- placement: 'left'
- })
-
- tooltipEl.addEventListener('inserted.bs.tooltip', () => {
- expect(tooltip.getTipElement()).toHaveClass('bs-tooltip-auto')
- done()
- })
-
- tooltip.show()
- })
- })
-
describe('setContent', () => {
it('should do nothing if the element is null', () => {
fixtureEl.innerHTML = '<a href="#" rel="tooltip" title="Another tooltip">'