0
Fork 0
mirror of https://github.com/TryGhost/Ghost.git synced 2025-02-24 23:48:13 -05:00

🔥 remove unused popover components (#620)

no issue

- `gh-popover` and `gh-popover-button` are no longer used in the codebase
- removing them seems prudent as we are moving towards a different approach for dropdowns/popovers/tethers etc
This commit is contained in:
Kevin Ansfield 2017-04-05 14:08:29 +01:00 committed by Hannah Wolfe
parent c48f06702c
commit 400150e67b
6 changed files with 1 additions and 91 deletions

View file

@ -1,22 +0,0 @@
import injectService from 'ember-service/inject';
import DropdownButton from 'ghost-admin/components/gh-dropdown-button';
function K() {
return this;
}
export default DropdownButton.extend({
dropdown: injectService(),
click: K,
mouseEnter() {
this._super(...arguments);
this.get('dropdown').toggleDropdown(this.get('popoverName'), this);
},
mouseLeave() {
this._super(...arguments);
this.get('dropdown').toggleDropdown(this.get('popoverName'), this);
}
});

View file

@ -1,7 +0,0 @@
import injectService from 'ember-service/inject';
import GhostDropdown from 'ghost-admin/components/gh-dropdown';
export default GhostDropdown.extend({
classNames: 'ghost-popover',
dropdown: injectService()
});

View file

@ -1,6 +1,6 @@
import Service from 'ember-service';
import Evented from 'ember-evented';
// This is used by the dropdown initializer (and subsequently popovers) to manage closing & toggling
// This is used by the dropdown initializer to manage closing & toggling
import BodyEventListener from 'ghost-admin/mixins/body-event-listener';
export default Service.extend(Evented, BodyEventListener, {

View file

@ -26,7 +26,6 @@
@import "components/dropdowns.css";
@import "components/pagination.css";
@import "components/badges.css";
@import "components/popovers.css";
@import "components/settings-menu.css";
@import "components/selectize.css";
@import "components/power-select.css";

View file

@ -26,7 +26,6 @@
@import "components/dropdowns.css";
@import "components/pagination.css";
@import "components/badges.css";
@import "components/popovers.css";
@import "components/settings-menu.css";
@import "components/selectize.css";
@import "components/power-select.css";

View file

@ -1,59 +0,0 @@
/* Popovers
/* ---------------------------------------------------------- */
.popover-item {
position: relative;
display: inline-block;
padding: 11px 26px 13px 16px;
min-width: 300px;
max-width: 400px;
background: var(--darkgrey);
border-radius: 6px;
color: var(--midgrey);
font-size: 1.2rem;
}
.popover-title {
color: #fff;
font-size: 1.4rem;
font-weight: 300;
}
.popover-desc {
margin-top: -4px;
}
.popover-body {
margin-top: 11px;
line-height: 1.7;
}
.popover-body b {
color: #fff;
}
.popover-body > *:last-child {
margin: 0;
}
/* Open / Close
/* ---------------------------------------------------------- */
.popover {
position: relative;
display: inline-block;
}
.popover .popover-item {
position: absolute;
z-index: 20;
}
.popover .popover-item.open {
display: block;
}
.popover .popover-item.closed {
display: none;
}