[plugin-sdk-option-dropdown] - merge upstream

This commit is contained in:
GuiLeme 2023-09-25 20:31:38 -03:00
commit ad79b64f28
102 changed files with 564 additions and 294 deletions

View File

@ -252,7 +252,7 @@ jobs:
apt --purge -y remove apache2-bin
'
- name: Install BBB
timeout-minutes: 15
timeout-minutes: 25
run: |
sudo -i <<EOF
set -e

View File

@ -13,8 +13,8 @@ object Dependencies {
val scalactic = "3.0.8"
// Libraries
val akkaVersion = "2.6.17"
val akkaHttpVersion = "10.2.7"
val pekkoVersion = "1.0.1"
val pekkoHttpVersion = "1.0.0"
val gson = "2.8.9"
val jackson = "2.13.5"
val logback = "1.2.11"
@ -43,8 +43,8 @@ object Dependencies {
val scalaLibrary = "org.scala-lang" % "scala-library" % Versions.scala
val scalaCompiler = "org.scala-lang" % "scala-compiler" % Versions.scala
val akkaActor = "com.typesafe.akka" % "akka-actor_2.13" % Versions.akkaVersion
val akkaSl4fj = "com.typesafe.akka" % "akka-slf4j_2.13" % Versions.akkaVersion
val pekkoActor = "org.apache.pekko" %% "pekko-actor" % Versions.pekkoVersion
val pekkoSlf4j = "org.apache.pekko" %% "pekko-slf4j" % Versions.pekkoVersion
val googleGson = "com.google.code.gson" % "gson" % Versions.gson
val jacksonModule = "com.fasterxml.jackson.module" %% "jackson-module-scala" % Versions.jackson
@ -53,9 +53,9 @@ object Dependencies {
val commonsCodec = "commons-codec" % "commons-codec" % Versions.codec
val sprayJson = "io.spray" % "spray-json_2.13" % Versions.spray
val akkaStream = "com.typesafe.akka" %% "akka-stream" % Versions.akkaVersion
val akkaHttp = "com.typesafe.akka" %% "akka-http" % Versions.akkaHttpVersion
val akkaHttpSprayJson = "com.typesafe.akka" %% "akka-http-spray-json" % Versions.akkaHttpVersion
val pekkoStream = "org.apache.pekko" %% "pekko-stream" % Versions.pekkoVersion
val pekkoHttp = "org.apache.pekko" %% "pekko-http" % Versions.pekkoHttpVersion
val pekkoHttpSprayJson = "org.apache.pekko" %% "pekko-http-spray-json" % Versions.pekkoHttpVersion
val apacheLang = "org.apache.commons" % "commons-lang3" % Versions.lang
@ -85,9 +85,9 @@ object Dependencies {
val runtime = Seq(
Compile.scalaLibrary,
Compile.scalaCompiler,
Compile.akkaActor,
Compile.akkaSl4fj,
Compile.akkaStream,
Compile.pekkoActor,
Compile.pekkoSlf4j,
Compile.pekkoStream,
Compile.googleGson,
Compile.jacksonModule,
Compile.quicklens,
@ -95,8 +95,8 @@ object Dependencies {
Compile.commonsCodec,
Compile.sprayJson,
Compile.apacheLang,
Compile.akkaHttp,
Compile.akkaHttpSprayJson,
Compile.pekkoHttp,
Compile.pekkoHttpSprayJson,
Compile.bbbCommons,
Compile.slick,
Compile.slickHikaricp,

View File

@ -1,8 +1,8 @@
package org.bigbluebutton
import akka.http.scaladsl.model._
import akka.http.scaladsl.marshallers.sprayjson.SprayJsonSupport
import akka.http.scaladsl.server.Directives._
import org.apache.pekko.http.scaladsl.model._
import org.apache.pekko.http.scaladsl.marshallers.sprayjson.SprayJsonSupport
import org.apache.pekko.http.scaladsl.server.Directives._
import org.bigbluebutton.common2.msgs._
import org.bigbluebutton.service.{ HealthzService, MeetingInfoService, PubSubReceiveStatus, PubSubSendStatus, RecordingDBSendStatus }
import spray.json._

View File

@ -1,9 +1,9 @@
package org.bigbluebutton
import akka.actor.ActorSystem
import akka.event.Logging
import akka.http.scaladsl.Http
import akka.stream.ActorMaterializer
import org.apache.pekko.actor.ActorSystem
import org.apache.pekko.event.Logging
import org.apache.pekko.http.scaladsl.Http
import org.apache.pekko.stream.ActorMaterializer
import org.bigbluebutton.common2.redis.{ MessageSender, RedisConfig, RedisPublisher }
import org.bigbluebutton.core._
import org.bigbluebutton.core.bus._

View File

@ -1,10 +1,10 @@
package org.bigbluebutton.core
import java.io.{ PrintWriter, StringWriter }
import akka.actor._
import akka.actor.ActorLogging
import akka.actor.SupervisorStrategy.Resume
import akka.util.Timeout
import org.apache.pekko.actor._
import org.apache.pekko.actor.ActorLogging
import org.apache.pekko.actor.SupervisorStrategy.Resume
import org.apache.pekko.util.Timeout
import scala.concurrent.duration._
import org.bigbluebutton.core.bus._

View File

@ -1,6 +1,6 @@
package org.bigbluebutton.core.apps.audiocaptions
import akka.actor.ActorContext
import org.apache.pekko.actor.ActorContext
class AudioCaptionsApp2x(implicit val context: ActorContext)
extends UpdateTranscriptPubMsgHdlr

View File

@ -1,6 +1,6 @@
package org.bigbluebutton.core.apps.breakout
import org.bigbluebutton.common2.msgs.{ GroupChatAccess, GroupChatMsgFromUser }
import org.bigbluebutton.common2.msgs.{ GroupChatAccess, GroupChatMessageType, GroupChatMsgFromUser }
import org.bigbluebutton.core.api.SendMessageToBreakoutRoomInternalMsg
import org.bigbluebutton.core.apps.groupchats.GroupChatApp
import org.bigbluebutton.core.bus.MessageBus
@ -20,7 +20,7 @@ trait SendMessageToBreakoutRoomInternalMsgHdlr {
} yield {
val groupChatMsgFromUser = GroupChatMsgFromUser(sender.id, sender.copy(name = msg.senderName), true, msg.msg)
val gcm = GroupChatApp.toGroupChatMessage(sender.copy(name = msg.senderName), groupChatMsgFromUser)
val gcs = GroupChatApp.addGroupChatMessage(liveMeeting.props.meetingProp.intId, chat, state.groupChats, gcm)
val gcs = GroupChatApp.addGroupChatMessage(liveMeeting.props.meetingProp.intId, chat, state.groupChats, gcm, GroupChatMessageType.BREAKOUTROOM_MOD_MSG)
val event = buildGroupChatMessageBroadcastEvtMsg(
liveMeeting.props.meetingProp.intId,

View File

@ -1,7 +1,7 @@
package org.bigbluebutton.core.apps.caption
import akka.actor.ActorContext
import akka.event.Logging
import org.apache.pekko.actor.ActorContext
import org.apache.pekko.event.Logging
import org.bigbluebutton.common2.msgs._
import org.bigbluebutton.core.bus.MessageBus
import org.bigbluebutton.core.running.{ LiveMeeting }

View File

@ -1,6 +1,6 @@
package org.bigbluebutton.core.apps.chat
import akka.actor.ActorContext
import org.apache.pekko.actor.ActorContext
class ChatApp2x(implicit val context: ActorContext)
extends GetChatHistoryReqMsgHdlr

View File

@ -33,7 +33,7 @@ trait ClearPublicChatHistoryPubMsgHdlr extends LogHelper with RightsManagementTr
gc <- state.groupChats.find(msg.body.chatId)
} yield {
ChatMessageDAO.deleteAllFromChat(liveMeeting.props.meetingProp.intId, msg.body.chatId)
ChatMessageDAO.insertSystemMsg(liveMeeting.props.meetingProp.intId, msg.body.chatId, "", "publicChatHistoryCleared", Map(), "")
ChatMessageDAO.insertSystemMsg(liveMeeting.props.meetingProp.intId, msg.body.chatId, "", GroupChatMessageType.PUBLIC_CHAT_HIST_CLEARED, Map(), "")
broadcastEvent(msg)
val newGc = gc.clearMessages()
val gcs = state.groupChats.update(newGc)

View File

@ -1,7 +1,7 @@
package org.bigbluebutton.core.apps.externalvideo
import akka.actor.ActorContext
import akka.event.Logging
import org.apache.pekko.actor.ActorContext
import org.apache.pekko.event.Logging
class ExternalVideoApp2x(implicit val context: ActorContext)
extends StartExternalVideoPubMsgHdlr

View File

@ -1,6 +1,6 @@
package org.bigbluebutton.core.apps.groupchats
import org.bigbluebutton.common2.msgs.{ GroupChatAccess, GroupChatMsgFromUser, GroupChatMsgToUser, GroupChatUser }
import org.bigbluebutton.common2.msgs.{ GroupChatAccess, GroupChatMessageType, GroupChatMsgFromUser, GroupChatMsgToUser, GroupChatUser }
import org.bigbluebutton.core.db.ChatMessageDAO
import org.bigbluebutton.core.domain.MeetingState2x
import org.bigbluebutton.core.models._
@ -32,9 +32,9 @@ object GroupChatApp {
}
def addGroupChatMessage(meetingId: String, chat: GroupChat, chats: GroupChats,
msg: GroupChatMessage): GroupChats = {
msg: GroupChatMessage, messageType: String = GroupChatMessageType.DEFAULT): GroupChats = {
if (msg.sender.id == SystemUser.ID) {
ChatMessageDAO.insertSystemMsg(meetingId, chat.id, msg.message, "default", Map(), msg.sender.name)
ChatMessageDAO.insertSystemMsg(meetingId, chat.id, msg.message, messageType, Map(), msg.sender.name)
} else {
ChatMessageDAO.insert(meetingId, chat.id, msg)
}

View File

@ -1,7 +1,7 @@
package org.bigbluebutton.core.apps.groupchats
import akka.actor.ActorContext
import akka.event.Logging
import org.apache.pekko.actor.ActorContext
import org.apache.pekko.event.Logging
class GroupChatHdlrs(implicit val context: ActorContext)
extends CreateGroupChatReqMsgHdlr

View File

@ -1,6 +1,6 @@
package org.bigbluebutton.core.apps.pads
import akka.actor.ActorContext
import org.apache.pekko.actor.ActorContext
class PadsApp2x(implicit val context: ActorContext)
extends PadCreateGroupReqMsgHdlr

View File

@ -1,7 +1,7 @@
package org.bigbluebutton.core.apps.polls
import akka.actor.ActorContext
import akka.event.Logging
import org.apache.pekko.actor.ActorContext
import org.apache.pekko.event.Logging
class PollApp2x(implicit val context: ActorContext)
extends GetCurrentPollReqMsgHdlr

View File

@ -77,7 +77,7 @@ trait ShowPollResultReqMsgHdlr extends RightsManagementTrait {
"numResponders" -> result.numResponders,
)
ChatMessageDAO.insertSystemMsg(liveMeeting.props.meetingProp.intId, GroupChatApp.MAIN_PUBLIC_CHAT, "", "poll", resultAsSimpleMap, "")
ChatMessageDAO.insertSystemMsg(liveMeeting.props.meetingProp.intId, GroupChatApp.MAIN_PUBLIC_CHAT, "", GroupChatMessageType.POLL, resultAsSimpleMap, "")
broadcastEvent(msg, result, annotationProp)
}
}

View File

@ -1,7 +1,7 @@
package org.bigbluebutton.core.apps.presentation
import akka.actor.ActorContext
import akka.event.Logging
import org.apache.pekko.actor.ActorContext
import org.apache.pekko.event.Logging
import org.bigbluebutton.core.apps.Presentation
import org.bigbluebutton.core.running.LiveMeeting

View File

@ -247,7 +247,7 @@ trait MakePresentationDownloadReqMsgHdlr extends RightsManagementTrait {
"fileURI" -> m.body.annotatedFileURI,
"filename" -> "annotated_slides.pdf"
)
ChatMessageDAO.insertSystemMsg(liveMeeting.props.meetingProp.intId, GroupChatApp.MAIN_PUBLIC_CHAT, "", "presentation", presentationDownloadInfo, "")
ChatMessageDAO.insertSystemMsg(liveMeeting.props.meetingProp.intId, GroupChatApp.MAIN_PUBLIC_CHAT, "", GroupChatMessageType.PRESENTATION, presentationDownloadInfo, "")
}
bus.outGW.send(buildBroadcastNewPresFileAvailable(m, liveMeeting))

View File

@ -1,7 +1,7 @@
package org.bigbluebutton.core.apps.presentationpod
import akka.actor.ActorContext
import akka.event.Logging
import org.apache.pekko.actor.ActorContext
import org.apache.pekko.event.Logging
class PresentationPodHdlrs(implicit val context: ActorContext)
extends CreateNewPresentationPodPubMsgHdlr

View File

@ -1,7 +1,7 @@
package org.bigbluebutton.core.apps.screenshare
import akka.actor.ActorContext
import akka.event.Logging
import org.apache.pekko.actor.ActorContext
import org.apache.pekko.event.Logging
import org.bigbluebutton.core.apps.ScreenshareModel
import org.bigbluebutton.core.running.{ LiveMeeting, OutMsgRouter }
import org.bigbluebutton.core2.message.senders.MsgBuilder

View File

@ -1,7 +1,7 @@
package org.bigbluebutton.core.apps.timer
import akka.actor.ActorContext
import akka.event.Logging
import org.apache.pekko.actor.ActorContext
import org.apache.pekko.event.Logging
class TimerApp2x(implicit val context: ActorContext)
extends CreateTimerPubMsgHdlr

View File

@ -1,7 +1,7 @@
package org.bigbluebutton.core.apps.users
import akka.actor.ActorContext
import akka.event.Logging
import org.apache.pekko.actor.ActorContext
import org.apache.pekko.event.Logging
import org.bigbluebutton.common2.msgs._
import org.bigbluebutton.core.apps.ExternalVideoModel
import org.bigbluebutton.core.bus.InternalEventBus

View File

@ -1,6 +1,6 @@
package org.bigbluebutton.core.apps.voice
import akka.actor.{ ActorContext, ActorSystem, Cancellable }
import org.apache.pekko.actor.{ ActorContext, ActorSystem, Cancellable }
import org.bigbluebutton.SystemConfiguration
import org.bigbluebutton.LockSettingsUtil
import org.bigbluebutton.core.apps.breakout.BreakoutHdlrHelpers

View File

@ -1,7 +1,7 @@
package org.bigbluebutton.core.apps.webcam
import akka.actor.ActorContext
import akka.event.Logging
import org.apache.pekko.actor.ActorContext
import org.apache.pekko.event.Logging
class WebcamApp2x(implicit val context: ActorContext)
extends CamBroadcastStoppedInSfuEvtMsgHdlr

View File

@ -1,7 +1,7 @@
package org.bigbluebutton.core.apps.whiteboard
import akka.actor.ActorContext
import akka.event.Logging
import org.apache.pekko.actor.ActorContext
import org.apache.pekko.event.Logging
import org.bigbluebutton.core.running.LiveMeeting
import org.bigbluebutton.common2.msgs.AnnotationVO
import scala.collection.immutable.{ Map }

View File

@ -1,7 +1,7 @@
package org.bigbluebutton.core.bus
import akka.actor.ActorRef
import akka.event.{ EventBus, LookupClassification }
import org.apache.pekko.actor.ActorRef
import org.apache.pekko.event.{ EventBus, LookupClassification }
import org.bigbluebutton.common2.msgs.BbbCommonEnvCoreMsg
case class BbbMsgEvent(val topic: String, val payload: BbbCommonEnvCoreMsg)

View File

@ -1,5 +1,6 @@
package org.bigbluebutton.core.bus
import akka.actor.ActorRef
import org.apache.pekko.actor.ActorRef
class InMsgBusGW(bus: IncomingEventBusImp) extends InternalEventBus {
override def publish(event: BigBlueButtonEvent): Unit = {

View File

@ -1,8 +1,8 @@
package org.bigbluebutton.core.bus
import akka.actor.ActorRef
import akka.event.EventBus
import akka.event.LookupClassification
import org.apache.pekko.actor.ActorRef
import org.apache.pekko.event.EventBus
import org.apache.pekko.event.LookupClassification
class IncomingEventBusImp extends EventBus with LookupClassification {
type Event = BigBlueButtonEvent

View File

@ -1,6 +1,6 @@
package org.bigbluebutton.core.bus
import akka.actor.ActorRef
import org.apache.pekko.actor.ActorRef
import org.bigbluebutton.core.api.InMessage
case class BigBlueButtonEvent(val topic: String, val payload: InMessage)

View File

@ -1,7 +1,7 @@
package org.bigbluebutton.core.bus
import akka.actor.ActorRef
import akka.event.{ EventBus, LookupClassification }
import org.apache.pekko.actor.ActorRef
import org.apache.pekko.event.{ EventBus, LookupClassification }
import org.bigbluebutton.common2.msgs.{ BbbCommonEnvCoreMsg }
case class BbbOutMessage(val topic: String, val payload: BbbCommonEnvCoreMsg)

View File

@ -1,7 +1,7 @@
package org.bigbluebutton.core.bus
import akka.actor.ActorRef
import akka.event.{ EventBus, LookupClassification }
import org.apache.pekko.actor.ActorRef
import org.apache.pekko.event.{ EventBus, LookupClassification }
import org.bigbluebutton.common2.msgs.{ BbbCoreMsg }
case class BbbRecordMessage(val topic: String, val payload: BbbCoreMsg)

View File

@ -1,6 +1,6 @@
package org.bigbluebutton.core.pubsub.senders
import akka.actor.{ Actor, ActorLogging, Props }
import org.apache.pekko.actor.{ Actor, ActorLogging, Props }
import org.bigbluebutton.SystemConfiguration
import com.fasterxml.jackson.databind.JsonNode
import org.bigbluebutton.common2.msgs._

View File

@ -1,6 +1,6 @@
package org.bigbluebutton.core.running
import akka.actor.{ Actor, ActorLogging }
import org.apache.pekko.actor.{ Actor, ActorLogging }
// A marker trait so we can create testable meeting actors
trait BaseMeetingActor extends Actor with ActorLogging {

View File

@ -1,7 +1,7 @@
package org.bigbluebutton.core.running
import akka.actor.ActorContext
import akka.event.{ LogSource, Logging }
import org.apache.pekko.actor.ActorContext
import org.apache.pekko.event.{ LogSource, Logging }
object MyType {
implicit val logSource: LogSource[AnyRef] = new LogSource[AnyRef] {

View File

@ -1,7 +1,7 @@
package org.bigbluebutton.core.running
import java.io.{ PrintWriter, StringWriter }
import akka.actor.SupervisorStrategy.Resume
import org.apache.pekko.actor.SupervisorStrategy.Resume
import org.bigbluebutton.SystemConfiguration
import org.bigbluebutton.core.apps.groupchats.GroupChatHdlrs
import org.bigbluebutton.core.apps.presentationpod._
@ -32,18 +32,18 @@ import org.bigbluebutton.common2.msgs._
import org.bigbluebutton.core.apps.breakout._
import org.bigbluebutton.core.apps.polls._
import org.bigbluebutton.core.apps.voice._
import akka.actor.Props
import akka.actor.OneForOneStrategy
import org.apache.pekko.actor.Props
import org.apache.pekko.actor.OneForOneStrategy
import org.bigbluebutton.common2.msgs
import scala.concurrent.duration._
import org.bigbluebutton.core.apps.layout.LayoutApp2x
import org.bigbluebutton.core.apps.meeting.{ SyncGetMeetingInfoRespMsgHdlr, ValidateConnAuthTokenSysMsgHdlr }
import org.bigbluebutton.core.apps.users.ChangeLockSettingsInMeetingCmdMsgHdlr
import org.bigbluebutton.core.db.{ UserStateDAO }
import org.bigbluebutton.core.db.UserStateDAO
import org.bigbluebutton.core.models.VoiceUsers.{ findAllFreeswitchCallers, findAllListenOnlyVoiceUsers }
import org.bigbluebutton.core.models.Webcams.findAll
import org.bigbluebutton.core2.MeetingStatus2x.{ hasAuthedUserJoined }
import org.bigbluebutton.core2.MeetingStatus2x.hasAuthedUserJoined
import org.bigbluebutton.core2.message.senders.{ MsgBuilder, Sender }
import java.util.concurrent.TimeUnit

View File

@ -2,11 +2,11 @@ package org.bigbluebutton.core.running
import java.io.{ PrintWriter, StringWriter }
import akka.actor.Actor
import akka.actor.ActorLogging
import akka.actor.Props
import akka.actor.OneForOneStrategy
import akka.actor.SupervisorStrategy.Resume
import org.apache.pekko.actor.Actor
import org.apache.pekko.actor.ActorLogging
import org.apache.pekko.actor.Props
import org.apache.pekko.actor.OneForOneStrategy
import org.apache.pekko.actor.SupervisorStrategy.Resume
import scala.concurrent.duration._
import org.bigbluebutton.SystemConfiguration

View File

@ -1,6 +1,6 @@
package org.bigbluebutton.core.running
import akka.actor.ActorContext
import org.apache.pekko.actor.ActorContext
import org.bigbluebutton.common2.domain.DefaultProps
import org.bigbluebutton.core.apps._
import org.bigbluebutton.core.bus._

View File

@ -1,6 +1,6 @@
package org.bigbluebutton.core2
import akka.actor.{ Actor, ActorLogging, Props }
import org.apache.pekko.actor.{ Actor, ActorLogging, Props }
import org.bigbluebutton.common2.msgs._
import org.bigbluebutton.common2.util.JsonUtil
object AnalyticsActor {

View File

@ -1,6 +1,6 @@
package org.bigbluebutton.core2
import akka.actor.{ Actor, ActorLogging, Props }
import org.apache.pekko.actor.{ Actor, ActorLogging, Props }
import org.bigbluebutton.SystemConfiguration
import org.bigbluebutton.common2.msgs._
import org.bigbluebutton.common2.util.JsonUtil

View File

@ -1,6 +1,6 @@
package org.bigbluebutton.core2.voiceconf
import akka.actor.{ Actor, ActorLogging, FSM }
import org.apache.pekko.actor.{ Actor, ActorLogging, FSM }
import org.bigbluebutton.SystemConfiguration
sealed trait VoiceConfState

View File

@ -2,8 +2,8 @@ package org.bigbluebutton.endpoint.redis
import org.bigbluebutton.common2.bus.IncomingJsonMessageBus
import org.bigbluebutton.common2.redis.{ RedisConfig, RedisSubscriberProvider }
import akka.actor.ActorSystem
import akka.actor.Props
import org.apache.pekko.actor.ActorSystem
import org.apache.pekko.actor.Props
object AppsRedisSubscriberActor {
def props(
@ -22,7 +22,7 @@ object AppsRedisSubscriberActor {
channelsToSubscribe,
patternsToSubscribe,
forwardMsgToChannel
).withDispatcher("akka.redis-subscriber-worker-dispatcher")
).withDispatcher("pekko.redis-subscriber-worker-dispatcher")
}
class AppsRedisSubscriberActor(

View File

@ -5,10 +5,10 @@ import scala.collection.JavaConverters._
import org.bigbluebutton.common2.msgs._
import org.bigbluebutton.common2.redis.{ RedisConfig, RedisStorageProvider }
import org.bigbluebutton.core.record.events.{ AbstractPresentationWithAnnotations, StoreAnnotationsInRedisPresAnnEvent, StoreExportJobInRedisPresAnnEvent }
import akka.actor.Actor
import akka.actor.ActorLogging
import akka.actor.ActorSystem
import akka.actor.Props
import org.apache.pekko.actor.Actor
import org.apache.pekko.actor.ActorLogging
import org.apache.pekko.actor.ActorSystem
import org.apache.pekko.actor.Props
import org.bigbluebutton.service.HealthzService
import scala.concurrent.duration._

View File

@ -1,6 +1,6 @@
package org.bigbluebutton.endpoint.redis
import akka.actor.{Actor, ActorLogging, ActorSystem, Props}
import org.apache.pekko.actor.{Actor, ActorLogging, ActorSystem, Props}
import org.bigbluebutton.common2.domain.PresentationVO
import org.bigbluebutton.common2.msgs._
import org.bigbluebutton.common2.util.JsonUtil

View File

@ -6,10 +6,10 @@ import org.bigbluebutton.common2.msgs._
import org.bigbluebutton.common2.redis.{ RedisConfig, RedisStorageProvider }
import org.bigbluebutton.core.apps.groupchats.GroupChatApp
import org.bigbluebutton.core.record.events._
import akka.actor.Actor
import akka.actor.ActorLogging
import akka.actor.ActorSystem
import akka.actor.Props
import org.apache.pekko.actor.Actor
import org.apache.pekko.actor.ActorLogging
import org.apache.pekko.actor.ActorSystem
import org.apache.pekko.actor.Props
import org.bigbluebutton.service.HealthzService
import scala.concurrent.duration._

View File

@ -1,11 +1,11 @@
package org.bigbluebutton.service
import akka.actor.{ Actor, ActorLogging, ActorSystem, Props }
import akka.util.Timeout
import org.apache.pekko.actor.{ Actor, ActorLogging, ActorSystem, Props }
import org.apache.pekko.util.Timeout
import scala.concurrent.Future
import scala.concurrent.duration._
import akka.pattern.{ AskTimeoutException, ask }
import org.apache.pekko.pattern.{ AskTimeoutException, ask }
import org.bigbluebutton.core.BigBlueButtonActor
import java.time.{ Instant, LocalDateTime }

View File

@ -1,9 +1,9 @@
package org.bigbluebutton.service
import akka.actor.{ Actor, ActorLogging, ActorRef, ActorSystem, Props }
import akka.pattern.ask
import akka.pattern.AskTimeoutException
import akka.util.Timeout
import org.apache.pekko.actor.{ Actor, ActorLogging, ActorRef, ActorSystem, Props }
import org.apache.pekko.pattern.ask
import org.apache.pekko.pattern.AskTimeoutException
import org.apache.pekko.util.Timeout
import org.bigbluebutton.MeetingInfoAnalytics
import org.bigbluebutton.common2.msgs.{ BbbCommonEnvCoreMsg, MeetingEndingEvtMsg, MeetingInfoAnalyticsServiceMsg }

View File

@ -1,4 +1,4 @@
akka {
pekko {
actor {
debug {
# enable DEBUG logging of all AutoReceiveMessages (Kill, PoisonPill et.c.)
@ -7,11 +7,11 @@ akka {
lifecycle = on
}
}
loggers = ["akka.event.slf4j.Slf4jLogger"]
loggers = ["org.apache.pekko.event.slf4j.Slf4jLogger"]
loglevel = "DEBUG"
redis-publish-worker-dispatcher {
mailbox-type = "akka.dispatch.SingleConsumerOnlyUnboundedMailbox"
mailbox-type = "org.apache.pekko.dispatch.SingleConsumerOnlyUnboundedMailbox"
# Throughput defines the maximum number of messages to be
# processed per actor before the thread jumps to the next actor.
# Set to 1 for as fair as possible.
@ -19,7 +19,7 @@ akka {
}
redis-subscriber-worker-dispatcher {
mailbox-type = "akka.dispatch.SingleConsumerOnlyUnboundedMailbox"
mailbox-type = "org.apache.pekko.dispatch.SingleConsumerOnlyUnboundedMailbox"
# Throughput defines the maximum number of messages to be
# processed per actor before the thread jumps to the next actor.
# Set to 1 for as fair as possible.

View File

@ -12,8 +12,8 @@ object Dependencies {
val scalactic = "3.0.8"
// Libraries
val akkaVersion = "2.6.17"
val akkaHttpVersion = "10.2.7"
val pekkoVersion = "1.0.1"
val pekkoHttpVersion = "1.0.0"
val logback = "1.2.10"
// Apache Commons
@ -26,7 +26,7 @@ object Dependencies {
// Test
val scalaTest = "3.2.11"
val akkaTestKit = "2.6.0"
val pekkoTestKit = "1.0.1"
val junit = "4.12"
}
@ -34,12 +34,12 @@ object Dependencies {
val scalaLibrary = "org.scala-lang" % "scala-library" % Versions.scala
val scalaCompiler = "org.scala-lang" % "scala-compiler" % Versions.scala
val akkaActor = "com.typesafe.akka" % "akka-actor_2.13" % Versions.akkaVersion
val akkaSl4fj = "com.typesafe.akka" % "akka-slf4j_2.13" % Versions.akkaVersion
val akkaStream = "com.typesafe.akka" %% "akka-stream" % Versions.akkaVersion
val pekkoActor = "org.apache.pekko" %% "pekko-actor" % Versions.pekkoVersion
val pekkoSlf4j = "org.apache.pekko" %% "pekko-slf4j" % Versions.pekkoVersion
val pekkoStream = "org.apache.pekko" %% "pekko-stream" % Versions.pekkoVersion
val akkaHttp = "com.typesafe.akka" %% "akka-http" % Versions.akkaHttpVersion
val akkaHttpSprayJson = "com.typesafe.akka" %% "akka-http-spray-json" % Versions.akkaHttpVersion
val pekkoHttp = "org.apache.pekko" %% "pekko-http" % Versions.pekkoHttpVersion
val pekkoHttpSprayJson = "org.apache.pekko" %% "pekko-http-spray-json" % Versions.pekkoHttpVersion
val logback = "ch.qos.logback" % "logback-classic" % Versions.logback
val commonsCodec = "commons-codec" % "commons-codec" % Versions.codec
@ -53,13 +53,11 @@ object Dependencies {
object Test {
val scalaTest = "org.scalatest" %% "scalatest" % Versions.scalaTest % "test"
// val junit = "junit" % "junit" % Versions.junit % "test"
val scalactic = "org.scalactic" % "scalactic_2.13" % Versions.scalactic % "test"
val akkaTestKit = "com.typesafe.akka" %% "akka-testkit" % Versions.akkaTestKit % "test"
val pekkoTestKit = "org.apache.pekko" %% "pekko-testkit" % Versions.pekkoTestKit % "test"
// https://mvnrepository.com/artifact/com.typesafe.akka/akka-http-testkit
val akkaHttpTestkit = "com.typesafe.akka" %% "akka-http-testkit" % "10.2.0" % "test"
val pekkoHttpTestKit = "org.apache.pekko" %% "pekko-http-testkit" % "1.0.0" % "test"
}
@ -67,22 +65,22 @@ object Dependencies {
Test.scalaTest,
// Test.junit,
Test.scalactic,
Test.akkaTestKit,
Test.akkaHttpTestkit
Test.pekkoTestKit,
Test.pekkoHttpTestKit
)
val runtime = Seq(
Compile.scalaLibrary,
Compile.scalaCompiler,
Compile.akkaActor,
Compile.akkaSl4fj,
Compile.akkaStream,
Compile.pekkoActor,
Compile.pekkoSlf4j,
Compile.pekkoStream,
Compile.logback,
Compile.commonsCodec,
Compile.apacheLang,
Compile.bbbCommons,
Compile.bbbFseslClient,
Compile.akkaHttp,
Compile.akkaHttpSprayJson) ++ testing
Compile.pekkoHttp,
Compile.pekkoHttpSprayJson) ++ testing
}

View File

@ -1,15 +1,15 @@
akka {
pekko {
actor {
debug {
receive = on
}
}
loggers = ["akka.event.slf4j.Slf4jLogger"]
loggers = ["org.apache.pekko.event.slf4j.Slf4jLogger"]
loglevel = "DEBUG"
stdout-loglevel = "DEBUG"
redis-subscriber-worker-dispatcher {
mailbox-type = "akka.dispatch.SingleConsumerOnlyUnboundedMailbox"
mailbox-type = "org.apache.pekko.dispatch.SingleConsumerOnlyUnboundedMailbox"
# Throughput defines the maximum number of messages to be
# processed per actor before the thread jumps to the next actor.
# Set to 1 for as fair as possible.
@ -37,3 +37,9 @@ redis {
keyExpiry=1209600
}
http {
interface = "127.0.0.1"
interface = ${?INTERFACE}
port = 8900
port = ${?PORT}
}

View File

@ -1,10 +1,10 @@
package org.bigbluebutton
import akka.http.scaladsl.model._
import akka.http.scaladsl.server.Directives._
import org.bigbluebutton.service.{ HealthzService }
import org.apache.pekko.http.scaladsl.model._
import org.apache.pekko.http.scaladsl.server.Directives._
import org.bigbluebutton.service.HealthzService
import spray.json.DefaultJsonProtocol
import akka.http.scaladsl.marshallers.sprayjson.SprayJsonSupport
import org.apache.pekko.http.scaladsl.marshallers.sprayjson.SprayJsonSupport
case class HealthResponse(isHealthy: Boolean)
case class StatusResponse(status: Array[String], heartbeat: Map[String, String])

View File

@ -7,9 +7,9 @@ import org.bigbluebutton.freeswitch.{ RxJsonMsgHdlrActor, VoiceConferenceService
import org.bigbluebutton.freeswitch.voice.FreeswitchConferenceEventListener
import org.bigbluebutton.freeswitch.voice.freeswitch.{ ConnectionManager, ESLEventListener, FreeswitchApplication }
import org.freeswitch.esl.client.manager.DefaultManagerConnection
import akka.actor.ActorSystem
import akka.stream.ActorMaterializer
import akka.http.scaladsl.Http
import org.apache.pekko.actor.ActorSystem
import org.apache.pekko.stream.ActorMaterializer
import org.apache.pekko.http.scaladsl.Http
import org.bigbluebutton.service.HealthzService
import scala.concurrent.ExecutionContext

View File

@ -1,7 +1,7 @@
package org.bigbluebutton
import akka.actor.ActorSystem
import akka.stream.ActorMaterializer
import org.apache.pekko.actor.ActorSystem
import org.apache.pekko.stream.ActorMaterializer
import scala.concurrent.ExecutionContext

View File

@ -4,8 +4,8 @@ import scala.concurrent.ExecutionContext.Implicits.global
import scala.concurrent.duration.DurationInt
import org.bigbluebutton.common2.bus.IncomingJsonMessageBus
import org.bigbluebutton.common2.redis.{ RedisConfig, RedisSubscriberProvider }
import akka.actor.ActorSystem
import akka.actor.Props
import org.apache.pekko.actor.ActorSystem
import org.apache.pekko.actor.Props
object FSESLRedisSubscriberActor {
@ -25,7 +25,7 @@ object FSESLRedisSubscriberActor {
channelsToSubscribe,
patternsToSubscribe,
forwardMsgToChannel
).withDispatcher("akka.redis-subscriber-worker-dispatcher")
).withDispatcher("pekko.redis-subscriber-worker-dispatcher")
}
class FSESLRedisSubscriberActor(

View File

@ -7,9 +7,9 @@ import org.bigbluebutton.freeswitch.voice.freeswitch.FreeswitchApplication
import com.fasterxml.jackson.databind.JsonNode
import akka.actor.Actor
import akka.actor.ActorLogging
import akka.actor.Props
import org.apache.pekko.actor.Actor
import org.apache.pekko.actor.ActorLogging
import org.apache.pekko.actor.Props
object RxJsonMsgHdlrActor {
def props(fsApp: FreeswitchApplication): Props =

View File

@ -2,10 +2,10 @@ package org.bigbluebutton.service
import java.text.SimpleDateFormat
import akka.actor.{ Actor, ActorLogging, Props }
import akka.actor.ActorSystem
import akka.pattern.{ AskTimeoutException, ask }
import akka.util.Timeout
import org.apache.pekko.actor.{ Actor, ActorLogging, Props }
import org.apache.pekko.actor.ActorSystem
import org.apache.pekko.pattern.{ AskTimeoutException, ask }
import org.apache.pekko.util.Timeout
import scala.concurrent.duration._
import scala.concurrent.Future

View File

@ -1,15 +1,15 @@
akka {
pekko {
actor {
debug {
receive = on
}
}
loggers = ["akka.event.slf4j.Slf4jLogger"]
loggers = ["org.apache.pekko.event.slf4j.Slf4jLogger"]
loglevel = "DEBUG"
stdout-loglevel = "DEBUG"
redis-subscriber-worker-dispatcher {
mailbox-type = "akka.dispatch.SingleConsumerOnlyUnboundedMailbox"
mailbox-type = "org.apache.pekko.dispatch.SingleConsumerOnlyUnboundedMailbox"
# Throughput defines the maximum number of messages to be
# processed per actor before the thread jumps to the next actor.
# Set to 1 for as fair as possible.
@ -42,4 +42,4 @@ http {
interface = ${?INTERFACE}
port = 8900
port = ${?PORT}
}
}

View File

@ -13,7 +13,7 @@ object Dependencies {
val scalactic = "3.0.8"
// Libraries
val akkaVersion = "2.6.17"
val pekkoVersion = "1.0.1"
val gson = "2.8.9"
val jackson = "2.13.5"
val sl4j = "1.7.32"
@ -31,7 +31,7 @@ object Dependencies {
val scalaLibrary = "org.scala-lang" % "scala-library" % Versions.scala
val scalaCompiler = "org.scala-lang" % "scala-compiler" % Versions.scala
val akkaActor = "com.typesafe.akka" % "akka-actor_2.13" % Versions.akkaVersion
val pekkoActor = "org.apache.pekko" %% "pekko-actor" % Versions.pekkoVersion
val googleGson = "com.google.code.gson" % "gson" % Versions.gson
val jacksonModule = "com.fasterxml.jackson.module" %% "jackson-module-scala" % Versions.jackson
@ -58,7 +58,7 @@ object Dependencies {
val runtime = Seq(
Compile.scalaLibrary,
Compile.scalaCompiler,
Compile.akkaActor,
Compile.pekkoActor,
Compile.googleGson,
Compile.jacksonModule,
Compile.sl4jApi,

View File

@ -1,7 +1,7 @@
package org.bigbluebutton.common2.bus
import akka.actor.ActorRef
import akka.event.{ EventBus, LookupClassification }
import org.apache.pekko.event.{ EventBus, LookupClassification }
import org.apache.pekko.actor.ActorRef
case class ReceivedJsonMessage(channel: String, data: String)
case class IncomingJsonMessage(val topic: String, val payload: ReceivedJsonMessage)

View File

@ -1,7 +1,7 @@
package org.bigbluebutton.common2.bus
import akka.actor.ActorRef
import akka.event.{ EventBus, LookupClassification }
import org.apache.pekko.actor.ActorRef
import org.apache.pekko.event.{ EventBus, LookupClassification }
case class JsonMsgFromAkkaApps(name: String, data: String)
case class JsonMsgFromAkkaAppsEvent(val topic: String, val payload: JsonMsgFromAkkaApps)

View File

@ -1,7 +1,7 @@
package org.bigbluebutton.api2.bus
import akka.actor.ActorRef
import akka.event.{ EventBus, LookupClassification }
import org.apache.pekko.actor.ActorRef
import org.apache.pekko.event.{ EventBus, LookupClassification }
import org.bigbluebutton.common2.msgs.BbbCommonMsg
case class MsgFromAkkaApps(val topic: String, val payload: BbbCommonMsg)

View File

@ -1,8 +1,7 @@
package org.bigbluebutton.common2.bus
import akka.actor.ActorRef
import akka.event.{ EventBus, LookupClassification }
import akka.actor.actorRef2Scala
import org.apache.pekko.actor.ActorRef
import org.apache.pekko.event.{ EventBus, LookupClassification }
case class OldReceivedJsonMessage(pattern: String, channel: String, msg: String)
case class OldIncomingJsonMessage(val topic: String, val payload: OldReceivedJsonMessage)

View File

@ -5,6 +5,14 @@ object GroupChatAccess {
val PRIVATE = "PRIVATE_ACCESS"
}
object GroupChatMessageType {
val DEFAULT = "default"
val PRESENTATION = "presentation"
val POLL = "poll"
val BREAKOUTROOM_MOD_MSG = "breakoutRoomModeratorMsg"
val PUBLIC_CHAT_HIST_CLEARED = "publicChatHistoryCleared"
}
case class GroupChatUser(id: String, name: String = "", role: String = "VIEWER")
case class GroupChatMsgFromUser(correlationId: String, sender: GroupChatUser, chatEmphasizedText: Boolean = false, message: String)
case class GroupChatMsgToUser(id: String, timestamp: Long, correlationId: String, sender: GroupChatUser, chatEmphasizedText: Boolean = false, message: String)

View File

@ -1,6 +1,6 @@
package org.bigbluebutton.common2.redis
import akka.actor.ActorSystem
import org.apache.pekko.actor.ActorSystem
import io.lettuce.core.ClientOptions
import io.lettuce.core.RedisClient
import io.lettuce.core.RedisURI

View File

@ -5,7 +5,7 @@ import io.lettuce.core.event.Event
import io.lettuce.core.event.EventBus
import io.lettuce.core.event.connection.{ ConnectionDeactivatedEvent, ConnectionActivatedEvent, ConnectedEvent, DisconnectedEvent }
import reactor.core.Disposable
import akka.event.LoggingAdapter
import org.apache.pekko.event.LoggingAdapter
case class RedisConfig(host: String, port: Int, password: Option[String], expireKey: Int)

View File

@ -1,7 +1,7 @@
package org.bigbluebutton.common2.redis
import akka.actor.ActorSystem
import akka.event.Logging
import org.apache.pekko.actor.ActorSystem
import org.apache.pekko.event.Logging
class RedisPublisher(
system: ActorSystem,

View File

@ -1,6 +1,6 @@
package org.bigbluebutton.common2.redis
import akka.actor.ActorSystem
import org.apache.pekko.actor.ActorSystem
abstract class RedisStorageProvider(system: ActorSystem, clientName: String, config: RedisConfig) {
val redisPass = config.password match {

View File

@ -1,16 +1,15 @@
package org.bigbluebutton.common2.redis
import akka.actor.ActorSystem
import org.apache.pekko.actor.ActorSystem
import org.bigbluebutton.common2.bus.ReceivedJsonMessage
import org.bigbluebutton.common2.bus.IncomingJsonMessage
import io.lettuce.core.pubsub.RedisPubSubListener
import org.bigbluebutton.common2.bus.IncomingJsonMessageBus
import akka.actor.ActorLogging
import akka.actor.Actor
import org.apache.pekko.actor.ActorLogging
import org.apache.pekko.actor.Actor
import akka.actor.ActorSystem
import akka.actor.OneForOneStrategy
import akka.actor.SupervisorStrategy.Resume
import org.apache.pekko.actor.OneForOneStrategy
import org.apache.pekko.actor.SupervisorStrategy.Resume
import java.io.StringWriter
import scala.concurrent.duration._
import java.io.PrintWriter

View File

@ -13,7 +13,7 @@ object Dependencies {
val scalactic = "3.0.8"
// Libraries
val akkaVersion = "2.6.17"
val pekkoVersion = "1.0.1"
val gson = "2.8.9"
val jackson = "2.13.5"
val freemarker = "2.3.31"
@ -45,8 +45,8 @@ object Dependencies {
val scalaLibrary = "org.scala-lang" % "scala-library" % Versions.scala
val scalaCompiler = "org.scala-lang" % "scala-compiler" % Versions.scala
val akkaActor = "com.typesafe.akka" % "akka-actor_2.13" % Versions.akkaVersion
val akkaSl4fj = "com.typesafe.akka" % "akka-slf4j_2.13" % Versions.akkaVersion
val pekkoActor = "org.apache.pekko" %% "pekko-actor" % Versions.pekkoVersion
val pekkoSlf4j = "org.apache.pekko" %% "pekko-slf4j" % Versions.pekkoVersion
val googleGson = "com.google.code.gson" % "gson" % Versions.gson
val jacksonModule = "com.fasterxml.jackson.module" %% "jackson-module-scala" % Versions.jackson
@ -85,8 +85,8 @@ object Dependencies {
val runtime = Seq(
Compile.scalaLibrary,
Compile.scalaCompiler,
Compile.akkaActor,
Compile.akkaSl4fj,
Compile.pekkoActor,
Compile.pekkoSlf4j,
Compile.googleGson,
Compile.jacksonModule,
Compile.jacksonXml,

View File

@ -1,8 +1,8 @@
package org.bigbluebutton.api2
import scala.collection.JavaConverters._
import akka.actor.ActorSystem
import akka.event.Logging
import org.apache.pekko.actor.ActorSystem
import org.apache.pekko.event.Logging
import org.bigbluebutton.api.domain.{BreakoutRoomsParams, Group, LockSettingsParams}
import org.bigbluebutton.api.messaging.converters.messages._
import org.bigbluebutton.api2.bus._
@ -27,7 +27,7 @@ class BbbWebApiGWApp(
implicit val system = ActorSystem("bbb-web-common")
implicit val timeout = akka.util.Timeout(3 seconds)
implicit val timeout = org.apache.pekko.util.Timeout(3 seconds)
val log = Logging(system, getClass)

View File

@ -1,7 +1,7 @@
package org.bigbluebutton.api2.bus
import akka.actor.ActorRef
import akka.event.{ EventBus, LookupClassification }
import org.apache.pekko.actor.ActorRef
import org.apache.pekko.event.{ EventBus, LookupClassification }
case class JsonMsgToSendToAkkaApps(channel: String, json: String)
case class JsonMsgToAkkaAppsBusMsg(val topic: String, payload: JsonMsgToSendToAkkaApps)

View File

@ -2,8 +2,8 @@ package org.bigbluebutton.api2.bus
import java.io.{ PrintWriter, StringWriter }
import akka.actor.SupervisorStrategy.Resume
import akka.actor.{ Actor, ActorLogging, OneForOneStrategy, Props }
import org.apache.pekko.actor.SupervisorStrategy.Resume
import org.apache.pekko.actor.{ Actor, ActorLogging, OneForOneStrategy, Props }
import org.bigbluebutton.common2.redis.MessageSender
import scala.concurrent.duration._

View File

@ -1,7 +1,7 @@
package org.bigbluebutton.api2.bus
import akka.actor.ActorRef
import akka.event.{ EventBus, LookupClassification }
import org.apache.pekko.actor.ActorRef
import org.apache.pekko.event.{ EventBus, LookupClassification }
import org.bigbluebutton.common2.msgs.BbbCommonEnvCoreMsg
case class MsgToAkkaApps(val topic: String, val payload: BbbCommonEnvCoreMsg)

View File

@ -1,6 +1,6 @@
package org.bigbluebutton.api2.bus
import akka.actor.{ Actor, ActorLogging, Props }
import org.apache.pekko.actor.{ Actor, ActorLogging, Props }
import org.bigbluebutton.api2.SystemConfiguration
import org.bigbluebutton.common2.msgs.BbbCommonEnvCoreMsg
import org.bigbluebutton.common2.util.JsonUtil

View File

@ -1,6 +1,6 @@
package org.bigbluebutton.api2.bus
import akka.actor.{ Actor, ActorLogging, Props }
import org.apache.pekko.actor.{ Actor, ActorLogging, Props }
import org.bigbluebutton.common2.bus.OldReceivedJsonMessage
object OldMessageJsonReceiverActor {

View File

@ -4,9 +4,9 @@ import org.bigbluebutton.api2.SystemConfiguration
import org.bigbluebutton.common2.bus._
import org.bigbluebutton.common2.msgs._
import com.fasterxml.jackson.databind.JsonNode
import akka.actor.Actor
import akka.actor.ActorLogging
import akka.actor.Props
import org.apache.pekko.actor.Actor
import org.apache.pekko.actor.ActorLogging
import org.apache.pekko.actor.Props
import scala.reflect.runtime.universe._

View File

@ -3,8 +3,8 @@ package org.bigbluebutton.api2.endpoint.redis
import org.bigbluebutton.api2.SystemConfiguration
import org.bigbluebutton.common2.bus._
import org.bigbluebutton.common2.redis.{ RedisConfig, RedisSubscriberProvider }
import akka.actor.ActorSystem
import akka.actor.Props
import org.apache.pekko.actor.ActorSystem
import org.apache.pekko.actor.Props
import io.lettuce.core.pubsub.RedisPubSubListener
@ -32,7 +32,7 @@ object WebRedisSubscriberActor {
patternsToSubscribe,
forwardMsgToChannel,
oldJsonChannel
).withDispatcher("akka.redis-subscriber-worker-dispatcher")
).withDispatcher("pekko.redis-subscriber-worker-dispatcher")
}
class WebRedisSubscriberActor(

View File

@ -1,7 +1,7 @@
package org.bigbluebutton.api2.meeting
import akka.actor.Actor
import akka.actor.ActorLogging
import org.apache.pekko.actor.Actor
import org.apache.pekko.actor.ActorLogging
object MeetingActor {

View File

@ -1,6 +1,6 @@
package org.bigbluebutton.api2.meeting
import akka.actor.{ Actor, ActorLogging, Props }
import org.apache.pekko.actor.{ Actor, ActorLogging, Props }
import org.bigbluebutton.api.domain.UserSession
import org.bigbluebutton.api2.bus.MsgToAkkaAppsEventBus
import org.bigbluebutton.common2.domain.DefaultProps

View File

@ -2,7 +2,7 @@ package org.bigbluebutton.api2.meeting
import java.util
import akka.actor.{ Actor, ActorLogging, Props }
import org.apache.pekko.actor.{ Actor, ActorLogging, Props }
import org.bigbluebutton.api.messaging.messages._
import org.bigbluebutton.api2.bus.OldMessageReceivedGW
import org.bigbluebutton.common2.msgs._

View File

@ -1,6 +1,7 @@
import React, { PureComponent } from 'react';
import CaptionsButtonContainer from '/imports/ui/components/captions/button/container';
import deviceInfo from '/imports/utils/deviceInfo';
import * as PluginSdk from 'bigbluebutton-html-plugin-sdk';
import Styled from './styles';
import ActionsDropdown from './actions-dropdown/container';
import AudioCaptionsButtonContainer from '/imports/ui/components/audio/captions/button/container';
@ -12,6 +13,7 @@ import JoinVideoOptionsContainer from '../video-provider/video-button/container'
import PresentationOptionsContainer from './presentation-options/component';
import RaiseHandDropdownContainer from './raise-hand/container';
import { isPresentationEnabled } from '/imports/ui/services/features';
import Button from '/imports/ui/components/common/button/component';
class ActionsBar extends PureComponent {
constructor(props) {
@ -24,12 +26,53 @@ class ActionsBar extends PureComponent {
this.setCaptionsReaderMenuModalIsOpen = this.setCaptionsReaderMenuModalIsOpen.bind(this);
this.setRenderRaiseHand = this.renderRaiseHand.bind(this);
this.actionsBarRef = React.createRef();
this.renderPluginsActionBarItems = this.renderPluginsActionBarItems.bind(this);
}
setCaptionsReaderMenuModalIsOpen(value) {
this.setState({ isCaptionsReaderMenuModalOpen: value })
}
renderPluginsActionBarItems(position) {
const { actionBarItems } = this.props;
return (
<>
{
actionBarItems.filter((plugin) => plugin.position === position).map((plugin, index) => {
let actionBarItemToReturn;
switch (plugin.type) {
case PluginSdk.ActionsBarItemType.BUTTON:
actionBarItemToReturn = (
<Button
key={`${plugin.type}-${plugin.id}`}
onClick={plugin.onClick}
hideLabel
color="primary"
icon={plugin.icon}
size="lg"
circle
label={plugin.tooltip}
/>
);
break;
case PluginSdk.ActionsBarItemType.SEPARATOR:
actionBarItemToReturn = (
<Styled.Separator
key={`${plugin.type}-${plugin.id}`}
/>
);
break;
default:
actionBarItemToReturn = null;
break;
}
return actionBarItemToReturn;
})
}
</>
);
}
renderRaiseHand() {
const {
isReactionsButtonEnabled, isRaiseHandButtonEnabled, setEmojiStatus, currentUser, intl,
@ -138,6 +181,7 @@ class ActionsBar extends PureComponent {
: null }
</Styled.Left>
<Styled.Center>
{this.renderPluginsActionBarItems(PluginSdk.ActionsBarPosition.LEFT)}
<AudioControlsContainer />
{enableVideo
? (
@ -149,7 +193,8 @@ class ActionsBar extends PureComponent {
isMeteorConnected,
}}
/>
{isRaiseHandButtonCentered && this.renderRaiseHand()}
{isRaiseHandButtonCentered && this.renderRaiseHand()}
{this.renderPluginsActionBarItems(PluginSdk.ActionsBarPosition.RIGHT)}
</Styled.Center>
<Styled.Right>
{ shouldShowOptionsButton ?

View File

@ -16,6 +16,7 @@ import TimerService from '/imports/ui/components/timer/service';
import { layoutSelectOutput, layoutDispatch } from '../layout/context';
import { isExternalVideoEnabled, isPollingEnabled, isPresentationEnabled } from '/imports/ui/services/features';
import { isScreenBroadcasting, isCameraAsContentBroadcasting } from '/imports/ui/components/screenshare/service';
import { PluginsContext } from '/imports/ui/components/components-data/plugin-context/context';
import MediaService from '../media/service';
@ -24,6 +25,16 @@ const ActionsBarContainer = (props) => {
const layoutContextDispatch = layoutDispatch();
const usingUsersContext = useContext(UsersContext);
const {
pluginsProvidedAggregatedState,
} = useContext(PluginsContext);
let actionBarItems = [];
if (pluginsProvidedAggregatedState.actionsBarItems) {
actionBarItems = [
...pluginsProvidedAggregatedState.actionsBarItems,
];
}
const { users } = usingUsersContext;
const currentUser = { userId: Auth.userID, emoji: users[Auth.meetingID][Auth.userID].emoji };
@ -40,6 +51,7 @@ const ActionsBarContainer = (props) => {
layoutContextDispatch,
actionsBarStyle,
amIPresenter,
actionBarItems,
}
}
/>

View File

@ -1,10 +1,11 @@
/* eslint-disable @typescript-eslint/ban-types */
import React, { useCallback } from 'react';
import React, { useCallback, useContext } from 'react';
import deviceInfo from '/imports/utils/deviceInfo';
import { defineMessages, useIntl } from 'react-intl';
import { useShortcut } from '/imports/ui/core/hooks/useShortcut';
import BBBMenu from '/imports/ui/components/common/menu/component';
import { MenuSeparatorItemType, MenuOptionItemType } from '/imports/ui/components/common/menu/menuTypes';
import * as PluginSdk from 'bigbluebutton-html-plugin-sdk';
import Styled from '../styles';
import {
handleLeaveAudio,
@ -15,6 +16,7 @@ import {
} from '../service';
import Mutetoggle from './muteToggle';
import ListenOnly from './listenOnly';
import { PluginsContext } from '/imports/ui/components/components-data/plugin-context/context';
const AUDIO_INPUT = 'audioinput';
const AUDIO_OUTPUT = 'audiooutput';
@ -89,6 +91,16 @@ export const LiveSelection: React.FC<LiveSelectionProps> = ({
const leaveAudioShourtcut = useShortcut('leaveAudio');
const {
pluginsProvidedAggregatedState,
} = useContext(PluginsContext);
let audioSettingsDropdownItems = [] as PluginSdk.AudioSettingsDropdownItem[];
if (pluginsProvidedAggregatedState.audioSettingsDropdownItems) {
audioSettingsDropdownItems = [
...pluginsProvidedAggregatedState.audioSettingsDropdownItems,
];
}
const renderDeviceList = useCallback((
deviceKind: string,
list: MediaDeviceInfo[],
@ -194,6 +206,33 @@ export const LiveSelection: React.FC<LiveSelectionProps> = ({
isSeparator: true,
})
.concat(leaveAudioOption);
audioSettingsDropdownItems.forEach((audioSettingsDropdownItem:
PluginSdk.AudioSettingsDropdownItem) => {
switch (audioSettingsDropdownItem.type) {
case PluginSdk.AudioSettingsDropdownItemType.OPTION: {
const audioSettingsDropdownOption = audioSettingsDropdownItem as PluginSdk.AudioSettingsDropdownOption;
dropdownListComplete.push({
label: audioSettingsDropdownOption.label,
iconRight: audioSettingsDropdownOption.icon,
onClick: audioSettingsDropdownOption.onClick,
key: audioSettingsDropdownOption.id,
});
break;
}
case PluginSdk.AudioSettingsDropdownItemType.SEPARATOR: {
const audioSettingsDropdownSeparator = audioSettingsDropdownItem as PluginSdk.AudioSettingsDropdownOption;
dropdownListComplete.push({
isSeparator: true,
key: audioSettingsDropdownSeparator.id,
});
break;
}
default:
break;
}
});
const customStyles = { top: '-1rem' };
const { isMobile } = deviceInfo;
return (

View File

@ -11,7 +11,7 @@ import {
GET_CHAT_MESSAGE_HISTORY, GET_PERMISSIONS, getChatMessageHistory, getPermissions,
} from './queries';
import { uid } from 'radash';
import Button from '/imports/ui/components/common/button/component';
import Trigger from '/imports/ui/components/common/control-header/right/component';
import { clearPublicChatHistory, generateExportedMessages } from './services';
import { getDateString } from '/imports/utils/string-utils';
@ -178,11 +178,10 @@ const ChatActions: React.FC = () => {
return (
<BBBMenu
trigger={(
<Button
<Trigger
label={intl.formatMessage(intlMessages.options)}
aria-label={intl.formatMessage(intlMessages.options)}
hideLabel
size="sm"
icon="more"
onClick={() => {
getPermissions();

View File

@ -8,7 +8,7 @@ import {
ChatMessagePublicSubscriptionResponse,
} from './queries';
import { Message } from '/imports/ui/Types/message';
import ChatMessage from './chat-message/componet';
import ChatMessage from './chat-message/component';
// @ts-ignore - temporary, while meteor exists in the project
const CHAT_CONFIG = Meteor.settings.public.chat;

View File

@ -37,6 +37,13 @@ export const PopupContentBody = styled.div`
// eslint-disable-next-line @typescript-eslint/ban-ts-comment
// @ts-ignore - as button comes from JS, we can't provide its props
export const CloseButton = styled(Button)`
border: none;
background-color: transparent;
padding: 0;
grid-area: 1 / 1 / 2 / 2;
justify-self: end;
border-radius: 50%;
padding: 0.5rem;
cursor: pointer;
transition: background-color 0.3s ease;
`;

View File

@ -27,7 +27,7 @@ const PluginLoaderContainer = (props: PluginLoaderContainerProps) => {
logger.info(`Loaded plugin ${plugin.name}`);
};
script.onerror = (err) => {
logger.info(`Error when loading plugin ${plugin.name}, error: ${err}`);
logger.error(`Error when loading plugin ${plugin.name}, error: `, err);
};
script.src = plugin.url;
script.setAttribute('uuid', div.id);

View File

@ -0,0 +1,54 @@
import { useEffect, useState, useContext } from 'react';
import * as PluginSdk from 'bigbluebutton-html-plugin-sdk';
import {
PluginProvidedStateContainerChildProps, PluginProvidedState,
PluginProvidedStateContainerChild,
} from '../../types';
import { PluginsContext } from '../../../components-data/plugin-context/context';
const ActionBarPluginStateContainer = ((
props: PluginProvidedStateContainerChildProps,
) => {
const {
uuid,
generateItemWithId,
pluginProvidedStateMap,
pluginApi,
} = props;
const [
actionBarItems,
setActionBarItems,
] = useState<PluginSdk.ActionsBarItem[]>([]);
const {
pluginsProvidedAggregatedState,
setPluginsProvidedAggregatedState,
} = useContext(PluginsContext);
useEffect(() => {
// Change this plugin provided toolbar items
pluginProvidedStateMap[uuid].actionsBarItems = actionBarItems;
// Update context with computed aggregated list of all plugin provided toolbar items
const aggregatedActionBarItems = (
[] as PluginSdk.ActionsBarItem[]).concat(
...Object.values(pluginProvidedStateMap)
.map((pps: PluginProvidedState) => pps.actionsBarItems),
);
setPluginsProvidedAggregatedState(
{
...pluginsProvidedAggregatedState,
actionsBarItems: aggregatedActionBarItems,
},
);
}, [actionBarItems]);
pluginApi.setActionsBarItems = (items: PluginSdk.ActionsBarItem[]) => {
const itemsWithId = items.map(generateItemWithId) as PluginSdk.ActionsBarItem[];
return setActionBarItems(itemsWithId);
};
return null;
}) as PluginProvidedStateContainerChild;
export default ActionBarPluginStateContainer;

View File

@ -0,0 +1,53 @@
import { useEffect, useState, useContext } from 'react';
import * as PluginSdk from 'bigbluebutton-html-plugin-sdk';
import {
PluginProvidedStateContainerChildProps, PluginProvidedState,
PluginProvidedStateContainerChild,
} from '../../types';
import { PluginsContext } from '../../../components-data/plugin-context/context';
const AudioSettingsDropdownPluginStateContainer = ((
props: PluginProvidedStateContainerChildProps,
) => {
const {
uuid,
generateItemWithId,
pluginProvidedStateMap,
pluginApi,
} = props;
const [
audioSettingsDropdownItems,
setAudioSettingsDropdownItems,
] = useState<PluginSdk.AudioSettingsDropdownItem[]>([]);
const {
pluginsProvidedAggregatedState,
setPluginsProvidedAggregatedState,
} = useContext(PluginsContext);
useEffect(() => {
// Change this plugin provided toolbar items
pluginProvidedStateMap[uuid].audioSettingsDropdownItems = audioSettingsDropdownItems;
// Update context with computed aggregated list of all plugin provided toolbar items
const aggregatedAudioSettingsDropdownItems = ([] as PluginSdk.AudioSettingsDropdownItem[]).concat(
...Object.values(pluginProvidedStateMap)
.map((pps: PluginProvidedState) => pps.audioSettingsDropdownItems),
);
setPluginsProvidedAggregatedState(
{
...pluginsProvidedAggregatedState,
audioSettingsDropdownItems: aggregatedAudioSettingsDropdownItems,
},
);
}, [audioSettingsDropdownItems]);
pluginApi.setAudioSettingsDropdownItems = (items: PluginSdk.AudioSettingsDropdownItem[]) => {
const itemsWithId = items.map(generateItemWithId) as PluginSdk.AudioSettingsDropdownItem[];
return setAudioSettingsDropdownItems(itemsWithId);
};
return null;
}) as PluginProvidedStateContainerChild;
export default AudioSettingsDropdownPluginStateContainer;

View File

@ -8,6 +8,9 @@ import {
import PresentationToolbarPluginStateContainer from './presentation-toolbar/container';
import UserListDropdownPluginStateContainer from './user-list-dropdown/container';
import ActionButtonDropdownPluginStateContainer from './action-button-dropdown/container';
import AudioSettingsDropdownPluginStateContainer from './audio-settings-dropdown/container';
import ActionBarPluginStateContainer from './action-bar/container';
import PresentationDropdownPluginStateContainer from './presentation-dropdown/container';
import OptionsDropdownPluginStateContainer from './options-dropdown/container';
const pluginProvidedStateMap: PluginsProvidedStateMap = {};
@ -16,6 +19,9 @@ const pluginProvidedStateContainers: PluginProvidedStateContainerChild[] = [
PresentationToolbarPluginStateContainer,
UserListDropdownPluginStateContainer,
ActionButtonDropdownPluginStateContainer,
AudioSettingsDropdownPluginStateContainer,
ActionBarPluginStateContainer,
PresentationDropdownPluginStateContainer,
OptionsDropdownPluginStateContainer,
];

View File

@ -0,0 +1,54 @@
import { useEffect, useState, useContext } from 'react';
import * as PluginSdk from 'bigbluebutton-html-plugin-sdk';
import {
PluginProvidedStateContainerChildProps, PluginProvidedState,
PluginProvidedStateContainerChild,
} from '../../types';
import { PluginsContext } from '../../../components-data/plugin-context/context';
const PresentationDropdownPluginStateContainer = ((
props: PluginProvidedStateContainerChildProps,
) => {
const {
uuid,
generateItemWithId,
pluginProvidedStateMap,
pluginApi,
} = props;
const [
presentationDropdownItems,
setPresentationDropdownItems,
] = useState<PluginSdk.PresentationDropdownItem[]>([]);
const {
pluginsProvidedAggregatedState,
setPluginsProvidedAggregatedState,
} = useContext(PluginsContext);
useEffect(() => {
// Change this plugin provided toolbar items
pluginProvidedStateMap[uuid].presentationDropdownItems = presentationDropdownItems;
// Update context with computed aggregated list of all plugin provided toolbar items
const aggregatedPresentationDropdownItems = (
[] as PluginSdk.PresentationDropdownItem[]).concat(
...Object.values(pluginProvidedStateMap)
.map((pps: PluginProvidedState) => pps.presentationDropdownItems),
);
setPluginsProvidedAggregatedState(
{
...pluginsProvidedAggregatedState,
presentationDropdownItems: aggregatedPresentationDropdownItems,
},
);
}, [presentationDropdownItems]);
pluginApi.setPresentationDropdownItems = (items: PluginSdk.PresentationDropdownItem[]) => {
const itemsWithId = items.map(generateItemWithId) as PluginSdk.PresentationDropdownItem[];
return setPresentationDropdownItems(itemsWithId);
};
return null;
}) as PluginProvidedStateContainerChild;
export default PresentationDropdownPluginStateContainer;

View File

@ -30,6 +30,9 @@ export interface PluginProvidedState {
presentationToolbarItems: PluginSdk.PresentationToolbarItem[];
userListDropdownItems: PluginSdk.UserListDropdownItem[];
actionButtonDropdownItems: PluginSdk.ActionButtonDropdownItem[];
audioSettingsDropdownItems: PluginSdk.AudioSettingsDropdownItem[];
actionsBarItems: PluginSdk.ActionsBarItem[];
presentationDropdownItems: PluginSdk.PresentationDropdownItem[];
optionsDropdownItems: PluginSdk.OptionsDropdownItem[];
}

View File

@ -10,6 +10,7 @@ import TooltipContainer from '/imports/ui/components/common/tooltip/container';
import { ACTIONS } from '/imports/ui/components/layout/enums';
import browserInfo from '/imports/utils/browserInfo';
import AppService from '/imports/ui/components/app/service';
import * as PluginSdk from 'bigbluebutton-html-plugin-sdk';
const intlMessages = defineMessages({
downloading: {
@ -88,6 +89,10 @@ const propTypes = {
getShapes: PropTypes.func.isRequired,
currentPageId: PropTypes.string.isRequired,
}),
presentationDropdownItems: PropTypes.arrayOf(PropTypes.shape({
id: PropTypes.string,
type: PropTypes.string,
})).isRequired,
};
const defaultProps = {
@ -124,6 +129,7 @@ const PresentationMenu = (props) => {
isToolbarVisible,
setIsToolbarVisible,
allowSnapshotOfCurrentSlide,
presentationDropdownItems,
} = props;
const [state, setState] = useState({
@ -298,6 +304,27 @@ const PresentationMenu = (props) => {
);
}
presentationDropdownItems.forEach((item, index) => {
switch (item.type) {
case PluginSdk.PresentationDropdownItemType.OPTION:
menuItems.push({
key: `${item.id}-${index}`,
label: item.label,
icon: item.icon,
onClick: item.onClick,
});
break;
case PluginSdk.PresentationDropdownItemType.SEPARATOR:
menuItems.push({
key: `${item.id}-${index}`,
isSeparator: true,
});
break;
default:
break;
}
});
return menuItems;
}

View File

@ -1,4 +1,5 @@
import React from 'react';
import { useContext } from 'react';
import PropTypes from 'prop-types';
import { withTracker } from 'meteor/react-meteor-data';
import PresentationMenu from './component';
@ -9,6 +10,7 @@ import { layoutSelect, layoutDispatch } from '/imports/ui/components/layout/cont
import WhiteboardService from '/imports/ui/components/whiteboard/service';
import UserService from '/imports/ui/components/user-list/service';
import { isSnapshotOfCurrentSlideEnabled } from '/imports/ui/services/features';
import { PluginsContext } from '/imports/ui/components/components-data/plugin-context/context';
const PresentationMenuContainer = (props) => {
const fullscreen = layoutSelect((i) => i.fullscreen);
@ -17,6 +19,13 @@ const PresentationMenuContainer = (props) => {
const { elementId } = props;
const isFullscreen = currentElement === elementId;
const isRTL = layoutSelect((i) => i.isRTL);
const { pluginsProvidedAggregatedState } = useContext(PluginsContext);
let presentationDropdownItems = [];
if (pluginsProvidedAggregatedState.presentationDropdownItems) {
presentationDropdownItems = [
...pluginsProvidedAggregatedState.presentationDropdownItems,
];
}
return (
<PresentationMenu
@ -27,6 +36,7 @@ const PresentationMenuContainer = (props) => {
isFullscreen,
layoutContextDispatch,
isRTL,
presentationDropdownItems,
}}
/>
);

View File

@ -3754,9 +3754,9 @@
"dev": true
},
"bigbluebutton-html-plugin-sdk": {
"version": "0.0.7",
"resolved": "https://registry.npmjs.org/bigbluebutton-html-plugin-sdk/-/bigbluebutton-html-plugin-sdk-0.0.7.tgz",
"integrity": "sha512-9bCJwVGJoEhhwCNP/N1d/loSLsK6DgWsc6zcwqPk6mOzSlNeiJ0+uzhg4sB44JYN2vr6S7+BrhPF5rBwrT3ExA=="
"version": "0.0.11",
"resolved": "https://registry.npmjs.org/bigbluebutton-html-plugin-sdk/-/bigbluebutton-html-plugin-sdk-0.0.11.tgz",
"integrity": "sha512-mpZ6a7f5mhCSzdJbWZYUgoF+dj6598BidshBOMBFhZEzZjLUEGHkIjoac6yUHnjYOOLXcIttwYC07PwQlK8qDQ=="
},
"bintrees": {
"version": "1.0.2",

View File

@ -45,7 +45,7 @@
"autoprefixer": "^10.4.4",
"axios": "^0.21.3",
"babel-runtime": "~6.26.0",
"bigbluebutton-html-plugin-sdk": "0.0.7",
"bigbluebutton-html-plugin-sdk": "0.0.11",
"bowser": "^2.11.0",
"browser-bunyan": "^1.8.0",
"classnames": "^2.2.6",

View File

@ -287,6 +287,15 @@ class Page {
async selectSlide(slideOption, timeout = ELEMENT_WAIT_TIME) {
await this.page.locator(e.skipSlide).selectOption({ label: slideOption }, { timeout });
}
async closeAllToastNotifications() {
await this.page.waitForSelector(e.whiteboard);
const closeToastBtnLocator = this.page.locator(e.closeToastBtn);
while (await closeToastBtnLocator.count() > 0) {
await this.page.click(e.closeToastBtn);
await helpers.sleep(1000); // expected time to toast notification disappear
}
}
}
module.exports = exports = Page;

View File

@ -64,59 +64,15 @@ class Options extends MultiUsers {
await this.modPage.waitAndClickElement(e.darkModeToggleBtn);
await this.modPage.waitAndClick(e.modalConfirmButton);
//Checking user list
await this.modPage.waitAndClick(e.sharedNotes, ELEMENT_WAIT_TIME);
await this.modPage.backgroundColorTest(e.sharedNotesBackground, 'rgb(34, 36, 37)');
await this.modPage.waitAndClick(e.manageUsers);
await this.modPage.waitAndClick(e.guestPolicyLabel);
await this.modPage.backgroundColorTest(e.simpleModal, 'rgb(34, 36, 37)');
await this.modPage.waitAndClick(e.closeModal);
await this.modPage.waitAndClick(e.chatButton);
await this.modPage.backgroundColorTest(e.chatButton, 'rgb(48, 51, 52)');
await this.modPage.textColorTest(e.chatButton, 'rgb(208, 205, 201)');
await this.modPage.textColorTest(e.hidePublicChat, 'rgb(170, 164, 155)');
await this.modPage.textColorTest(`${e.chatOptions} >> span`, 'rgb(170, 164, 155)');
const modPageLocator = this.modPage.getLocator('body');
const screenshotOptions = {
maxDiffPixels: 1000,
};
await this.modPage.textColorTest(`${e.manageUsers} >> span`, 'rgb(170, 164, 155)');
await this.modPage.waitAndClick(e.manageUsers);
await this.modPage.waitAndClick(e.lockViewersButton);
await this.modPage.backgroundColorTest(e.simpleModal, 'rgb(34, 36, 37)');
await this.modPage.waitAndClick(e.applyLockSettings);
await this.modPage.closeAllToastNotifications();
//Checking public chat
await this.modPage.backgroundColorTest(e.publicChat, 'rgb(34, 36, 37)');
await this.modPage.backgroundColorTest(e.chatWelcomeMessageText, 'rgb(37, 39, 40)');
await this.modPage.backgroundColorTest(`${e.sendButton} >> span`, 'rgb(24, 94, 168)');
await this.modPage.backgroundColorTest(e.chatBox, 'rgb(34, 36, 37)');
await this.modPage.textColorTest(e.chatBox, 'rgb(170, 164, 155)');
// Checking actions bar background and buttons color
await this.modPage.backgroundColorTest(e.actionsBarBackground, 'rgb(30, 32, 33)')
await this.modPage.textColorTest(`${e.joinAudio} >> span`, 'rgb(222, 220, 217)');
await this.modPage.backgroundColorTest(`${e.joinAudio} >> span`, 'rgba(0, 0, 0, 0)');
await this.modPage.textColorTest(`${e.joinVideo} >> span`, 'rgb(222, 220, 217)');
await this.modPage.backgroundColorTest(`${e.joinVideo} >> span`, 'rgba(0, 0, 0, 0)');
await this.modPage.textColorTest(`${e.startScreenSharing} >> span`, 'rgb(222, 220, 217)');
await this.modPage.backgroundColorTest(`${e.startScreenSharing} >> span`, 'rgba(0, 0, 0, 0)');
await this.modPage.textColorTest(`${e.reactionsButton} >> span`, 'rgb(222, 220, 217)');
await this.modPage.backgroundColorTest(`${e.reactionsButton} >> span`, 'rgba(0, 0, 0, 0)');
await this.modPage.backgroundColorTest(`${e.actions} >> span`, 'rgb(24, 94, 168)');
await this.modPage.backgroundColorTest(`${e.minimizePresentation} >> span`, 'rgb(24, 94, 168)');
await expect(modPageLocator).toHaveScreenshot('moderator-page-dark-mode.png', screenshotOptions);
// Checking buttons background and navbar background
await this.modPage.backgroundColorTest(e.navbarBackground, 'rgb(30, 32, 33)');
await this.modPage.textColorTest(`${e.userListToggleBtn} >> span`, 'rgb(222, 220, 217)');
await this.modPage.textColorTest(`${e.optionsButton} >> span`, 'rgb(222, 220, 217)');
// Checking presentation area
await this.modPage.backgroundColorTest(e.whiteboardOptionsButton, 'rgb(34, 36, 37)');
await this.modPage.textColorTest(e.whiteboardOptionsButton, 'rgb(208, 205, 201)');
await this.modPage.waitAndClick(e.optionsButton);
await this.modPage.waitAndClick(e.settings);
await this.modPage.backgroundColorTest(e.fullscreenModal, 'rgb(34, 36, 37)');
await this.modPage.waitAndClick(e.modalConfirmButton);
await this.modPage.backgroundColorTest(e.presentationToolbarWrapper, 'rgb(39, 42, 42)');
await openSettings(this.modPage);
await this.modPage.waitAndClickElement(e.darkModeToggleBtn);
await this.modPage.waitAndClick(e.modalConfirmButton);
@ -128,29 +84,14 @@ class Options extends MultiUsers {
await this.modPage.waitAndClick(e.increaseFontSize);
await this.modPage.waitAndClick(e.modalConfirmButton);
await this.modPage.fontSizeCheck(e.chatButton, '16px');//text + icon
await this.modPage.fontSizeCheck(e.chatWelcomeMessageText, '16px');
await this.modPage.fontSizeCheck(e.chatMessages, '16px');
await this.modPage.fontSizeCheck(e.sharedNotes, '14px');
await this.modPage.fontSizeCheck(e.usersList, '16px');
await this.modPage.fontSizeCheck(e.currentUser, '16px');
await this.modPage.fontSizeCheck(e.actionsBarBackground, '16px');
await this.modPage.fontSizeCheck(e.navbarBackground, '24px');
// Decreasing font size
await openSettings(this.modPage);
await this.modPage.waitAndClick(e.decreaseFontSize);
await this.modPage.waitAndClick(e.decreaseFontSize);
await this.modPage.waitAndClick(e.modalConfirmButton);
const modPageLocator = this.modPage.getLocator('body');
const screenshotOptions = {
maxDiffPixels: 1000,
};
await this.modPage.fontSizeCheck(e.chatButton, '12px');
await this.modPage.fontSizeCheck(e.chatWelcomeMessageText, '12px');
await this.modPage.fontSizeCheck(e.chatMessages, '12px')
await this.modPage.fontSizeCheck(e.sharedNotes, '10.5px');
await this.modPage.fontSizeCheck(e.usersList, '12px');
await this.modPage.fontSizeCheck(e.currentUser, '12px');
await this.modPage.fontSizeCheck(e.actionsBarBackground, '12px');
await this.modPage.fontSizeCheck(e.navbarBackground, '18px');
await this.modPage.closeAllToastNotifications();
await expect(modPageLocator).toHaveScreenshot('moderator-page-font-size.png', screenshotOptions);
}
}

View File

@ -22,11 +22,11 @@ test.describe.serial('Options', () => {
await options.localesTest();
});
test('Dark mode @ci @flaky', async () => {
test('Dark mode @ci', async () => {
await options.darkMode();
});
test('Font size @ci @flaky', async () => {
test('Font size @ci', async () => {
await options.fontSizeTest();
});
});

Binary file not shown.

After

Width:  |  Height:  |  Size: 114 KiB

Some files were not shown because too many files have changed in this diff Show More