mirror of
https://github.com/shlinkio/shlink-web-client.git
synced 2024-12-23 09:30:31 +03:00
Merge pull request #260 from acelaya-forks/feature/responsive-visits-table
Feature/responsive visits table
This commit is contained in:
commit
85dc1d0825
3 changed files with 11 additions and 5 deletions
|
@ -31,8 +31,12 @@ const MenuLayout = (TagsList, ShortUrls, AsideMenu, CreateShortUrl, ShortUrlVisi
|
|||
const burgerClasses = classNames('menu-layout__burger-icon', {
|
||||
'menu-layout__burger-icon--active': sidebarVisible,
|
||||
});
|
||||
const swipeMenuIfNoModalExists = (callback) => () => {
|
||||
if (document.querySelector('.modal')) {
|
||||
const swipeMenuIfNoModalExists = (callback) => (e) => {
|
||||
const swippedOnVisitsTable = e.event.path.some(
|
||||
({ classList }) => classList && classList.contains('visits-table')
|
||||
);
|
||||
|
||||
if (swippedOnVisitsTable || document.querySelector('.modal')) {
|
||||
return;
|
||||
}
|
||||
|
||||
|
|
|
@ -88,7 +88,7 @@ const VisitsTable = ({
|
|||
}, [ searchTerm ]);
|
||||
|
||||
return (
|
||||
<table className="table table-striped table-bordered table-hover table-sm visits-table">
|
||||
<table className="table table-striped table-bordered table-hover table-sm table-responsive-sm visits-table">
|
||||
<thead className="visits-table__header">
|
||||
<tr>
|
||||
<th
|
||||
|
|
|
@ -12,8 +12,10 @@
|
|||
|
||||
@include sticky-cell();
|
||||
|
||||
&.visits-table__sticky {
|
||||
top: $headerHeight - 2px;
|
||||
@media (min-width: $mdMin) {
|
||||
&.visits-table__sticky {
|
||||
top: $headerHeight - 2px;
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
|
|
Loading…
Reference in a new issue