mirror of
https://github.com/discourse/discourse.git
synced 2025-02-25 18:55:32 -06:00
UX: do not attempt to full width sk on mobile (#9520)
This commit is contained in:
@@ -813,20 +813,8 @@ export default Component.extend(
|
||||
`[data-select-kit-id=${this.selectKit.uniqueID}-body]`
|
||||
);
|
||||
|
||||
if (
|
||||
this.site &&
|
||||
!this.site.mobileView &&
|
||||
popper.offsetWidth < anchor.offsetWidth
|
||||
) {
|
||||
popper.style.minWidth = `${anchor.offsetWidth}px`;
|
||||
}
|
||||
|
||||
const inModal = $(this.element).parents("#discourse-modal").length;
|
||||
|
||||
if (this.site && !this.site.mobileView && inModal) {
|
||||
popper.style.width = `${anchor.offsetWidth}px`;
|
||||
}
|
||||
|
||||
let placementStrategy = this.selectKit.options.placementStrategy;
|
||||
if (!placementStrategy) {
|
||||
placementStrategy = inModal ? "fixed" : "absolute";
|
||||
|
||||
Reference in New Issue
Block a user