Client: Added public form room
This commit is contained in:
parent
5c416644db
commit
846f0c87f5
@ -312,6 +312,7 @@ export default function withFileActions(WrappedFileItem) {
|
||||
|
||||
const showPlanetIcon =
|
||||
(item.roomType === RoomsType.PublicRoom ||
|
||||
item.roomType === RoomsType.FormRoom ||
|
||||
item.roomType === RoomsType.CustomRoom) &&
|
||||
item.shared;
|
||||
|
||||
|
@ -203,6 +203,7 @@ const Badges = ({
|
||||
|
||||
const isPublicRoomType =
|
||||
item.roomType === RoomsType.PublicRoom ||
|
||||
item.roomType === RoomsType.FormRoom ||
|
||||
item.roomType === RoomsType.CustomRoom;
|
||||
|
||||
const haveLinksRight =
|
||||
|
@ -120,6 +120,7 @@ const QuickButtons = (props) => {
|
||||
|
||||
const isPublicRoomType =
|
||||
item.roomType === RoomsType.PublicRoom ||
|
||||
item.roomType === RoomsType.FormRoom ||
|
||||
item.roomType === RoomsType.CustomRoom;
|
||||
|
||||
const haveLinksRight =
|
||||
|
@ -68,6 +68,7 @@ const RoomsItemHeader = ({
|
||||
const canInviteUserInRoomAbility = security?.EditAccess;
|
||||
const showPlanetIcon =
|
||||
(selection.roomType === RoomsType.PublicRoom ||
|
||||
selection.roomType === RoomsType.FormRoom ||
|
||||
selection.roomType === RoomsType.CustomRoom) &&
|
||||
hasLinks;
|
||||
|
||||
|
@ -322,7 +322,9 @@ export default inject(
|
||||
selectedFolderStore.roomType ?? infoPanelSelection?.roomType;
|
||||
|
||||
const isPublicRoomType =
|
||||
roomType === RoomsType.PublicRoom || roomType === RoomsType.CustomRoom;
|
||||
roomType === RoomsType.PublicRoom ||
|
||||
roomType === RoomsType.CustomRoom ||
|
||||
roomType === RoomsType.FormRoom;
|
||||
|
||||
const isPublicRoom = roomType === RoomsType.PublicRoom;
|
||||
|
||||
|
@ -543,7 +543,7 @@ const SectionHeaderContent = (props) => {
|
||||
disabled:
|
||||
isRecycleBinFolder ||
|
||||
isPersonalRoom ||
|
||||
((isPublicRoomType || isCustomRoomType) &&
|
||||
((isPublicRoomType || isCustomRoomType || isFormRoomType) &&
|
||||
haveLinksRight &&
|
||||
!isArchive),
|
||||
icon: InvitationLinkReactSvgUrl,
|
||||
@ -607,7 +607,7 @@ const SectionHeaderContent = (props) => {
|
||||
}
|
||||
},
|
||||
disabled:
|
||||
(!isPublicRoomType && !isCustomRoomType) ||
|
||||
(!isPublicRoomType && !isCustomRoomType && !isFormRoomType) ||
|
||||
!haveLinksRight ||
|
||||
isArchive,
|
||||
},
|
||||
@ -1164,9 +1164,7 @@ export default inject(
|
||||
const isRoom = !!roomType;
|
||||
const isPublicRoomType = roomType === RoomsType.PublicRoom;
|
||||
const isCustomRoomType = roomType === RoomsType.CustomRoom;
|
||||
const isFormRoomType =
|
||||
roomType === RoomsType.FormRoom ||
|
||||
(parentRoomType === FolderType.FormRoom && isFolder);
|
||||
const isFormRoomType = roomType === RoomsType.FormRoom;
|
||||
|
||||
const {
|
||||
onClickEditRoom,
|
||||
@ -1229,7 +1227,7 @@ export default inject(
|
||||
: !isPublicRoom &&
|
||||
!isArchive &&
|
||||
canCopyPublicLink &&
|
||||
(isPublicRoomType || isCustomRoomType) &&
|
||||
(isPublicRoomType || isCustomRoomType || isFormRoomType) &&
|
||||
primaryLink;
|
||||
|
||||
return {
|
||||
|
@ -198,7 +198,8 @@ const Sdk = ({
|
||||
|
||||
if (
|
||||
data[0].roomType === RoomsType.PublicRoom ||
|
||||
(data[0].roomType === RoomsType.CustomRoom && data[0].shared)
|
||||
(data[0].roomType === RoomsType.CustomRoom && data[0].shared) ||
|
||||
(data[0].roomType === RoomsType.FormRoom && data[0].shared)
|
||||
) {
|
||||
const links = await fetchExternalLinks(data[0].id);
|
||||
|
||||
|
@ -1218,6 +1218,7 @@ class ContextOptionsStore {
|
||||
let withOpen = item.id !== this.selectedFolderStore.id;
|
||||
const isPublicRoomType =
|
||||
item.roomType === RoomsType.PublicRoom ||
|
||||
item.roomType === RoomsType.FormRoom ||
|
||||
item.roomType === RoomsType.CustomRoom;
|
||||
|
||||
if (item.isRoom && withOpen) {
|
||||
|
@ -1451,6 +1451,7 @@ class FilesStore {
|
||||
|
||||
if (
|
||||
(data.current.roomType === RoomsType.PublicRoom ||
|
||||
data.current.roomType === RoomsType.FormRoom ||
|
||||
data.current.roomType === RoomsType.CustomRoom) &&
|
||||
!this.publicRoomStore.isPublicRoom
|
||||
) {
|
||||
@ -2295,6 +2296,7 @@ class FilesStore {
|
||||
|
||||
const isPublicRoomType =
|
||||
item.roomType === RoomsType.PublicRoom ||
|
||||
item.roomType === RoomsType.FormRoom ||
|
||||
item.roomType === RoomsType.CustomRoom;
|
||||
const isCustomRoomType = item.roomType === RoomsType.CustomRoom;
|
||||
|
||||
|
@ -94,6 +94,7 @@ const Item = React.memo(({ index, style, data }: ItemProps) => {
|
||||
|
||||
const showPlanetIcon =
|
||||
(item.roomType === RoomsType.PublicRoom ||
|
||||
item.roomType === RoomsType.FormRoom ||
|
||||
item.roomType === RoomsType.CustomRoom) &&
|
||||
item.shared;
|
||||
|
||||
|
Loading…
Reference in New Issue
Block a user