@videosdk.live/react-sdk 0.3.5 → 0.3.7

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
package/dist/index.js CHANGED
@@ -77,7 +77,7 @@ var events = {
77
77
  'connection-open': eventPrifix + "-connection-open",
78
78
  'connection-close': eventPrifix + "-connection-close",
79
79
  'switch-meeting': eventPrifix + "-switch-meeting",
80
- 'error': eventPrifix + "-error",
80
+ error: eventPrifix + "-error",
81
81
  'hls-started': eventPrifix + "-hls-started",
82
82
  'hls-stopped': eventPrifix + "-hls-stopped",
83
83
  'hls-state-changed': eventPrifix + "-hls-state-changed",
@@ -446,7 +446,7 @@ var MeetingConsumer = function MeetingConsumer(_ref2) {
446
446
  return /*#__PURE__*/React__default.createElement(React__default.Fragment, null, /*#__PURE__*/React__default.createElement(MeetingProviderContex.Consumer, null, children));
447
447
  };
448
448
 
449
- var version = "0.3.5";
449
+ var version = "0.3.6";
450
450
 
451
451
  var MeetingProvider = function MeetingProvider(_ref) {
452
452
  var children = _ref.children,
@@ -2308,8 +2308,10 @@ var withAdaptiveObservers = function withAdaptiveObservers(VideoPlayerComponent)
2308
2308
  var resizeObserverRef = React.useRef(null);
2309
2309
  var _useParticipant = useParticipant(participantId),
2310
2310
  participant = _useParticipant.participant;
2311
+ var _useMeeting = useMeeting(),
2312
+ localParticipant = _useMeeting.localParticipant;
2311
2313
  React.useEffect(function () {
2312
- if (type === 'share' || !ref.current || !participant) return;
2314
+ if (type === 'share' || !ref.current || !participant || participantId === localParticipant.id) return;
2313
2315
  var element = ref.current;
2314
2316
  if (!element || !participant) return;
2315
2317
  if (observerRef.current) observerRef.current.disconnect();