mirror of
https://github.com/RetroShare/RSNewWebUI.git
synced 2026-09-14 11:05:47 +05:00
Improved the ShareManager mobile layout:
Uses nearly the full phone viewport with safe spacing. Keeps the folder list independently scrollable. Keeps Add New and Edit buttons visible at the bottom. Converts folder rows into labeled mobile cards. Replaces the stray 0 with “No shared folders yet.” Ensures nested dialogs appear above ShareManager.
This commit is contained in:
parent
3190b4cb58
commit
62079e1fd7
@ -154,8 +154,8 @@ const ShareDirTable = () => {
|
||||
),
|
||||
m(
|
||||
'tbody.share-manager__table_body',
|
||||
sharedDirArr.length &&
|
||||
sharedDirArr.map((sharedDirItem, index) => {
|
||||
sharedDirArr.length
|
||||
? sharedDirArr.map((sharedDirItem, index) => {
|
||||
const {
|
||||
filename,
|
||||
virtualname,
|
||||
@ -233,7 +233,8 @@ const ShareDirTable = () => {
|
||||
: parentGroups.map((groupFlag) => futil.RsNodeGroupId[groupFlag]).join(', ')
|
||||
),
|
||||
]);
|
||||
})
|
||||
})
|
||||
: m('tr.share-manager__empty', m('td[colspan=4]', 'No shared folders yet.'))
|
||||
),
|
||||
]);
|
||||
},
|
||||
|
||||
@ -3,7 +3,7 @@
|
||||
#modal-container {
|
||||
display: none;
|
||||
position: fixed;
|
||||
z-index: 1;
|
||||
z-index: 1300;
|
||||
height: 100%;
|
||||
top: 0;
|
||||
left: 0;
|
||||
|
||||
@ -326,12 +326,17 @@ table.friendsfiles td:nth-child(1) {
|
||||
|
||||
.shareManagerPopupOverlay {
|
||||
@include popupOverlay;
|
||||
z-index: 1200;
|
||||
|
||||
.shareManagerPopup {
|
||||
position: absolute;
|
||||
inset: 0;
|
||||
margin: auto;
|
||||
width: 80%;
|
||||
height: 90%;
|
||||
max-width: 72rem;
|
||||
box-sizing: border-box;
|
||||
|
||||
& > .widget {
|
||||
padding: 1.5rem;
|
||||
}
|
||||
@ -345,6 +350,8 @@ table.friendsfiles td:nth-child(1) {
|
||||
|
||||
.share-manager {
|
||||
@include flex(column, $justify: space-between);
|
||||
min-height: 0;
|
||||
|
||||
&__table {
|
||||
margin: 1rem 0 auto;
|
||||
thead {
|
||||
@ -392,6 +399,12 @@ table.friendsfiles td:nth-child(1) {
|
||||
&__actions {
|
||||
@include flex($justify: space-between);
|
||||
}
|
||||
|
||||
&__empty td {
|
||||
padding: 2rem 1rem;
|
||||
color: #64748b;
|
||||
text-align: center;
|
||||
}
|
||||
&__form {
|
||||
@include flex(column, $gap: 0.5rem);
|
||||
&_input {
|
||||
@ -435,6 +448,83 @@ table.friendsfiles td:nth-child(1) {
|
||||
/* FILES MODULE RESPONSIVENESS */
|
||||
@media (max-width: 700px) {
|
||||
|
||||
/* Share Manager is a viewport-sized sheet on phones. */
|
||||
.shareManagerPopupOverlay {
|
||||
height: 100dvh;
|
||||
padding: 0.5rem;
|
||||
box-sizing: border-box;
|
||||
background-color: rgba(15, 23, 42, 0.55);
|
||||
|
||||
.shareManagerPopup {
|
||||
position: relative;
|
||||
width: 100%;
|
||||
height: 100%;
|
||||
min-width: 0;
|
||||
overflow: hidden;
|
||||
border-radius: 0.75rem;
|
||||
background: white;
|
||||
|
||||
& > .widget {
|
||||
min-width: 0;
|
||||
padding: 1rem;
|
||||
overflow: hidden;
|
||||
}
|
||||
|
||||
& .close-btn {
|
||||
top: 0.85rem;
|
||||
right: 0.85rem;
|
||||
padding: 0.55rem 0.75rem;
|
||||
}
|
||||
|
||||
.widget__heading {
|
||||
min-height: 2.5rem;
|
||||
padding-right: 3rem;
|
||||
}
|
||||
|
||||
.widget__heading h3 {
|
||||
overflow: hidden;
|
||||
font-size: 1.45rem;
|
||||
text-overflow: ellipsis;
|
||||
white-space: nowrap;
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
.share-manager {
|
||||
flex: 1 1 auto;
|
||||
height: auto;
|
||||
overflow: hidden;
|
||||
|
||||
> blockquote.info {
|
||||
flex: 0 0 auto;
|
||||
margin: 0.75rem 0 0;
|
||||
padding: 0.75rem 0.75rem 0.75rem 2rem;
|
||||
font-size: 0.9rem;
|
||||
line-height: 1.35;
|
||||
}
|
||||
|
||||
&__table {
|
||||
flex: 1 1 auto;
|
||||
min-height: 0;
|
||||
margin: 0.75rem 0;
|
||||
padding: 0;
|
||||
overflow-y: auto;
|
||||
}
|
||||
|
||||
&__actions {
|
||||
flex: 0 0 auto;
|
||||
gap: 0.75rem;
|
||||
padding-top: 0.75rem;
|
||||
border-top: 1px solid #e2e8f0;
|
||||
|
||||
button {
|
||||
flex: 1 1 0 !important;
|
||||
width: auto;
|
||||
min-height: 2.75rem;
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
/* General Files Layout */
|
||||
.file-view__body-details {
|
||||
flex-direction: column;
|
||||
@ -482,6 +572,44 @@ table.friendsfiles td:nth-child(1) {
|
||||
padding-left: 0 !important;
|
||||
}
|
||||
|
||||
.share-manager__table tr:not(.share-manager__empty) td::before {
|
||||
display: block;
|
||||
margin-bottom: 0.2rem;
|
||||
color: #64748b;
|
||||
font-size: 0.72rem;
|
||||
font-weight: 700;
|
||||
letter-spacing: 0.04em;
|
||||
text-transform: uppercase;
|
||||
}
|
||||
|
||||
.share-manager__table tr:not(.share-manager__empty) td:nth-child(1)::before {
|
||||
content: 'Shared directory';
|
||||
}
|
||||
|
||||
.share-manager__table tr:not(.share-manager__empty) td:nth-child(2)::before {
|
||||
content: 'Visible name';
|
||||
}
|
||||
|
||||
.share-manager__table tr:not(.share-manager__empty) td:nth-child(3)::before {
|
||||
content: 'Access';
|
||||
}
|
||||
|
||||
.share-manager__table tr:not(.share-manager__empty) td:nth-child(4)::before {
|
||||
content: 'Visibility';
|
||||
}
|
||||
|
||||
.share-manager__table .share-manager__empty {
|
||||
display: table-row;
|
||||
margin: 0;
|
||||
padding: 0;
|
||||
border: 0;
|
||||
}
|
||||
|
||||
.share-manager__table .share-manager__empty td {
|
||||
display: table-cell;
|
||||
padding: 2rem 1rem !important;
|
||||
}
|
||||
|
||||
/* My Files / Friends Files Tables -> Cards */
|
||||
table.myfiles,
|
||||
table.myfiles tr,
|
||||
|
||||
File diff suppressed because one or more lines are too long
Loading…
Reference in New Issue
Block a user