You can not select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.

app.js 2.4KB

1234567891011121314151617181920212223242526272829303132333435363738394041424344454647484950515253545556575859606162636465666768
  1. /* application specific logic */
  2. import 'jquery';
  3. import '@matrix-org/olm';
  4. import 'focus-visible';
  5. console.log("APP onl_")
  6. // We need to setup the jitsi-local-storage as early as possible so that we can start using it.
  7. // NOTE: If jitsi-local-storage is used before the initial setup is performed this will break the use case when we use
  8. // the local storage from the parent page when the localStorage is disabled. Also the setup is relying that
  9. // window.location is not changed and still has all URL parameters.
  10. import './react/features/base/jitsi-local-storage/setup';
  11. import conference from './conference';
  12. import API from './modules/API';
  13. import UI from './modules/UI/UI';
  14. import keyboardshortcut from './modules/keyboardshortcut/keyboardshortcut';
  15. import translation from './modules/translation/translation';
  16. // Initialize Olm as early as possible.
  17. if (window.Olm) {
  18. window.Olm.init().catch(e => {
  19. console.error('Failed to initialize Olm, E2EE will be disabled', e);
  20. delete window.Olm;
  21. });
  22. }
  23. import * as jc1 from './rdev/imp_rdev';
  24. import * as jc2 from './rdev/hooks/hookImports1';
  25. import * as jc3 from './rdev/hooks/hooks';
  26. import * as jc4 from './rdev/hooks/rz_dbg_hooks';
  27. window.APP = {
  28. API,
  29. conference,
  30. // Used by do_external_connect.js if we receive the attach data after
  31. // connect was already executed. status property can be 'initialized',
  32. // 'ready', or 'connecting'. We are interested in 'ready' status only which
  33. // means that connect was executed but we have to wait for the attach data.
  34. // In status 'ready' handler property will be set to a function that will
  35. // finish the connect process when the attach data or error is received.
  36. connect: {
  37. handler: null,
  38. status: 'initialized'
  39. },
  40. // Used for automated performance tests.
  41. connectionTimes: {
  42. 'index.loaded': window.indexLoadedTime
  43. },
  44. keyboardshortcut,
  45. translation,
  46. UI
  47. };
  48. // TODO The execution of the mobile app starts from react/index.native.js.
  49. // Similarly, the execution of the Web app should start from react/index.web.js
  50. // for the sake of consistency and ease of understanding. Temporarily though
  51. // because we are at the beginning of introducing React into the Web app, allow
  52. // the execution of the Web app to start from app.js in order to reduce the
  53. // complexity of the beginning step.
  54. import './react';