您最多选择25个主题 主题必须以字母或数字开头,可以包含连字符 (-),并且长度不得超过35个字符

functions.web.js 1.2KB

12345678910111213141516171819202122232425262728293031323334353637383940414243444546
  1. // @flow
  2. import { TOOLBAR_BUTTONS } from './constants';
  3. export * from './functions.any';
  4. /**
  5. * Removes all analytics related options from the given configuration, in case of a libre build.
  6. *
  7. * @param {*} config - The configuration which needs to be cleaned up.
  8. * @returns {void}
  9. */
  10. export function _cleanupConfig(config: Object) { // eslint-disable-line no-unused-vars
  11. }
  12. /**
  13. * Returns the dial out url.
  14. *
  15. * @param {Object} state - The state of the app.
  16. * @returns {string}
  17. */
  18. export function getDialOutStatusUrl(state: Object): string {
  19. return state['features/base/config'].guestDialOutStatusUrl;
  20. }
  21. /**
  22. * Returns the dial out status url.
  23. *
  24. * @param {Object} state - The state of the app.
  25. * @returns {string}
  26. */
  27. export function getDialOutUrl(state: Object): string {
  28. return state['features/base/config'].guestDialOutUrl;
  29. }
  30. /**
  31. * Returns the list of enabled toolbar buttons.
  32. *
  33. * @param {Object} state - The redux state.
  34. * @returns {Array<string>} - The list of enabled toolbar buttons.
  35. */
  36. export function getToolbarButtons(state: Object): Array<string> {
  37. const { toolbarButtons } = state['features/base/config'];
  38. return Array.isArray(toolbarButtons) ? toolbarButtons : TOOLBAR_BUTTONS;
  39. }