/** @jsx React.DOM */ /* This Source Code Form is subject to the terms of the Mozilla Public * License, v. 2.0. If a copy of the MPL was not distributed with this * file, You can obtain one at http://mozilla.org/MPL/2.0/. */ /* jshint newcap:false */ /* global loop:true, React */ (function() { "use strict"; // Stop the default init functions running to avoid conflicts. document.removeEventListener('DOMContentLoaded', loop.panel.init); document.removeEventListener('DOMContentLoaded', loop.conversation.init); // 1. Desktop components // 1.1 Panel var PanelView = loop.panel.PanelView; // 1.2. Conversation Window var IncomingCallView = loop.conversation.IncomingCallView; var DesktopPendingConversationView = loop.conversationViews.PendingConversationView; var CallFailedView = loop.conversationViews.CallFailedView; var DesktopRoomConversationView = loop.roomViews.DesktopRoomConversationView; // 2. Standalone webapp var HomeView = loop.webapp.HomeView; var UnsupportedBrowserView = loop.webapp.UnsupportedBrowserView; var UnsupportedDeviceView = loop.webapp.UnsupportedDeviceView; var CallUrlExpiredView = loop.webapp.CallUrlExpiredView; var GumPromptConversationView = loop.webapp.GumPromptConversationView; var WaitingConversationView = loop.webapp.WaitingConversationView; var StartConversationView = loop.webapp.StartConversationView; var FailedConversationView = loop.webapp.FailedConversationView; var EndedConversationView = loop.webapp.EndedConversationView; var StandaloneRoomView = loop.standaloneRoomViews.StandaloneRoomView; // 3. Shared components var ConversationToolbar = loop.shared.views.ConversationToolbar; var ConversationView = loop.shared.views.ConversationView; var FeedbackView = loop.shared.views.FeedbackView; // Store constants var ROOM_STATES = loop.store.ROOM_STATES; var FEEDBACK_STATES = loop.store.FEEDBACK_STATES; // Local helpers function returnTrue() { return true; } function returnFalse() { return false; } function noop(){} // Feedback API client configured to send data to the stage input server, // which is available at https://input.allizom.org var stageFeedbackApiClient = new loop.FeedbackAPIClient( "https://input.allizom.org/api/v1/feedback", { product: "Loop" } ); var dispatcher = new loop.Dispatcher(); var activeRoomStore = new loop.store.ActiveRoomStore(dispatcher, { mozLoop: navigator.mozLoop, sdkDriver: {} }); var roomStore = new loop.store.RoomStore(dispatcher, { mozLoop: navigator.mozLoop }); var feedbackStore = new loop.store.FeedbackStore(dispatcher, { feedbackClient: stageFeedbackApiClient }); // Local mocks var mockContact = { name: ["Mr Smith"], email: [{ value: "smith@invalid.com" }] }; var mockClient = { requestCallUrl: noop, requestCallUrlInfo: noop }; var mockSDK = {}; var mockConversationModel = new loop.shared.models.ConversationModel({ callerId: "Mrs Jones", urlCreationDate: (new Date() / 1000).toString() }, { sdk: mockSDK }); mockConversationModel.startSession = noop; var mockWebSocket = new loop.CallConnectionWebSocket({ url: "fake", callId: "fakeId", websocketToken: "fakeToken" }); var notifications = new loop.shared.models.NotificationCollection(); var errNotifications = new loop.shared.models.NotificationCollection(); errNotifications.add({ level: "error", message: "Could Not Authenticate", details: "Did you change your password?", detailsButtonLabel: "Retry", }); var SVGIcon = React.createClass({ render: function() { return ( ); } }); var SVGIcons = React.createClass({ shapes: [ "audio", "audio-hover", "audio-active", "block", "block-red", "block-hover", "block-active", "contacts", "contacts-hover", "contacts-active", "copy", "checkmark", "google", "google-hover", "google-active", "history", "history-hover", "history-active", "leave", "precall", "precall-hover", "precall-active", "settings", "settings-hover", "settings-active", "tag", "tag-hover", "tag-active", "trash", "unblock", "unblock-hover", "unblock-active", "video", "video-hover", "video-active" ], render: function() { return (
{shapeId}
Note: 332px wide.
Note: For the useable demo, you can access submitted data at input.allizom.org.
The person you were calling has ended the conversation.
The person you were calling has ended the conversation.