@pega/cosmos-react-core 3.0.0-dev.3.0 → 3.0.0-dev.4.2

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.
Files changed (130) hide show
  1. package/lib/components/AppShell/AppShell.d.ts.map +1 -1
  2. package/lib/components/AppShell/AppShell.js +58 -40
  3. package/lib/components/AppShell/AppShell.js.map +1 -1
  4. package/lib/components/AppShell/AppShell.styles.d.ts +1 -3
  5. package/lib/components/AppShell/AppShell.styles.d.ts.map +1 -1
  6. package/lib/components/AppShell/AppShell.styles.js +11 -4
  7. package/lib/components/AppShell/AppShell.styles.js.map +1 -1
  8. package/lib/components/AppShell/AppShell.types.d.ts +5 -1
  9. package/lib/components/AppShell/AppShell.types.d.ts.map +1 -1
  10. package/lib/components/AppShell/AppShell.types.js.map +1 -1
  11. package/lib/components/Badges/Selection.d.ts.map +1 -1
  12. package/lib/components/Badges/Selection.js +3 -2
  13. package/lib/components/Badges/Selection.js.map +1 -1
  14. package/lib/components/ComboBox/ComboBox.d.ts.map +1 -1
  15. package/lib/components/ComboBox/ComboBox.js +10 -3
  16. package/lib/components/ComboBox/ComboBox.js.map +1 -1
  17. package/lib/components/ComboBox/MultiSelectInput/MultiSelectInput.d.ts.map +1 -1
  18. package/lib/components/ComboBox/MultiSelectInput/MultiSelectInput.js +8 -6
  19. package/lib/components/ComboBox/MultiSelectInput/MultiSelectInput.js.map +1 -1
  20. package/lib/components/Configuration/Configuration.d.ts.map +1 -1
  21. package/lib/components/Configuration/Configuration.js +2 -1
  22. package/lib/components/Configuration/Configuration.js.map +1 -1
  23. package/lib/components/Drawer/Drawer.d.ts.map +1 -1
  24. package/lib/components/Drawer/Drawer.js +1 -1
  25. package/lib/components/Drawer/Drawer.js.map +1 -1
  26. package/lib/components/FieldGroup/FieldGroup.d.ts +2 -0
  27. package/lib/components/FieldGroup/FieldGroup.d.ts.map +1 -1
  28. package/lib/components/FieldGroup/FieldGroup.js +18 -7
  29. package/lib/components/FieldGroup/FieldGroup.js.map +1 -1
  30. package/lib/components/FieldGroup/FieldGroupList.d.ts.map +1 -1
  31. package/lib/components/FieldGroup/FieldGroupList.js +16 -13
  32. package/lib/components/FieldGroup/FieldGroupList.js.map +1 -1
  33. package/lib/components/File/FileUploadItem.js +1 -1
  34. package/lib/components/File/FileUploadItem.js.map +1 -1
  35. package/lib/components/Form/Form.d.ts.map +1 -1
  36. package/lib/components/Form/Form.js +2 -1
  37. package/lib/components/Form/Form.js.map +1 -1
  38. package/lib/components/HTML/HTML.d.ts +13 -0
  39. package/lib/components/HTML/HTML.d.ts.map +1 -0
  40. package/lib/components/HTML/HTML.js +148 -0
  41. package/lib/components/HTML/HTML.js.map +1 -0
  42. package/lib/components/HTML/index.d.ts +2 -0
  43. package/lib/components/HTML/index.d.ts.map +1 -0
  44. package/lib/components/HTML/index.js +2 -0
  45. package/lib/components/HTML/index.js.map +1 -0
  46. package/lib/components/Icon/iconNames.d.ts +1 -1
  47. package/lib/components/Icon/iconNames.d.ts.map +1 -1
  48. package/lib/components/Icon/iconNames.js +1 -0
  49. package/lib/components/Icon/iconNames.js.map +1 -1
  50. package/lib/components/Icon/icons/ai-assist.icon.d.ts +4 -0
  51. package/lib/components/Icon/icons/ai-assist.icon.d.ts.map +1 -0
  52. package/lib/components/Icon/icons/ai-assist.icon.js +6 -0
  53. package/lib/components/Icon/icons/ai-assist.icon.js.map +1 -0
  54. package/lib/components/Icon/icons/help-solid.icon.js +1 -1
  55. package/lib/components/Icon/icons/help-solid.icon.js.map +1 -1
  56. package/lib/components/Icon/icons/help.icon.js +1 -1
  57. package/lib/components/Icon/icons/help.icon.js.map +1 -1
  58. package/lib/components/Icon/icons/information-solid.icon.d.ts.map +1 -1
  59. package/lib/components/Icon/icons/information-solid.icon.js +1 -1
  60. package/lib/components/Icon/icons/information-solid.icon.js.map +1 -1
  61. package/lib/components/Icon/icons/information.icon.js +1 -1
  62. package/lib/components/Icon/icons/information.icon.js.map +1 -1
  63. package/lib/components/Icon/icons/open.icon.js +1 -1
  64. package/lib/components/Icon/icons/open.icon.js.map +1 -1
  65. package/lib/components/ListToolbar/ListToolbar.d.ts +6 -0
  66. package/lib/components/ListToolbar/ListToolbar.d.ts.map +1 -0
  67. package/lib/components/ListToolbar/ListToolbar.js +110 -0
  68. package/lib/components/ListToolbar/ListToolbar.js.map +1 -0
  69. package/lib/components/ListToolbar/ListToolbar.styles.d.ts +4 -0
  70. package/lib/components/ListToolbar/ListToolbar.styles.d.ts.map +1 -0
  71. package/lib/components/ListToolbar/ListToolbar.styles.js +29 -0
  72. package/lib/components/ListToolbar/ListToolbar.styles.js.map +1 -0
  73. package/lib/components/ListToolbar/ListToolbar.types.d.ts +73 -0
  74. package/lib/components/ListToolbar/ListToolbar.types.d.ts.map +1 -0
  75. package/lib/components/ListToolbar/ListToolbar.types.js +2 -0
  76. package/lib/components/ListToolbar/ListToolbar.types.js.map +1 -0
  77. package/lib/components/ListToolbar/QueryOptionPopover.d.ts +12 -0
  78. package/lib/components/ListToolbar/QueryOptionPopover.d.ts.map +1 -0
  79. package/lib/components/ListToolbar/QueryOptionPopover.js +66 -0
  80. package/lib/components/ListToolbar/QueryOptionPopover.js.map +1 -0
  81. package/lib/components/ListToolbar/index.d.ts +3 -0
  82. package/lib/components/ListToolbar/index.d.ts.map +1 -0
  83. package/lib/components/ListToolbar/index.js +2 -0
  84. package/lib/components/ListToolbar/index.js.map +1 -0
  85. package/lib/components/Menu/Menu.d.ts.map +1 -1
  86. package/lib/components/Menu/Menu.js +10 -39
  87. package/lib/components/Menu/Menu.js.map +1 -1
  88. package/lib/components/MenuButton/MenuButton.d.ts.map +1 -1
  89. package/lib/components/MenuButton/MenuButton.js +1 -0
  90. package/lib/components/MenuButton/MenuButton.js.map +1 -1
  91. package/lib/components/Popover/Popover.styles.d.ts.map +1 -1
  92. package/lib/components/Popover/Popover.styles.js +45 -20
  93. package/lib/components/Popover/Popover.styles.js.map +1 -1
  94. package/lib/hooks/index.d.ts +1 -1
  95. package/lib/hooks/index.d.ts.map +1 -1
  96. package/lib/hooks/index.js +1 -1
  97. package/lib/hooks/index.js.map +1 -1
  98. package/lib/hooks/useActiveDescendant.d.ts +9 -0
  99. package/lib/hooks/useActiveDescendant.d.ts.map +1 -1
  100. package/lib/hooks/useActiveDescendant.js +29 -0
  101. package/lib/hooks/useActiveDescendant.js.map +1 -1
  102. package/lib/hooks/useArrows.d.ts +2 -1
  103. package/lib/hooks/useArrows.d.ts.map +1 -1
  104. package/lib/hooks/useArrows.js +3 -2
  105. package/lib/hooks/useArrows.js.map +1 -1
  106. package/lib/hooks/useI18n.d.ts +62 -0
  107. package/lib/hooks/useI18n.d.ts.map +1 -1
  108. package/lib/hooks/useItemIntersection.d.ts.map +1 -1
  109. package/lib/hooks/useItemIntersection.js +18 -20
  110. package/lib/hooks/useItemIntersection.js.map +1 -1
  111. package/lib/i18n/default.d.ts +62 -0
  112. package/lib/i18n/default.d.ts.map +1 -1
  113. package/lib/i18n/default.js +70 -5
  114. package/lib/i18n/default.js.map +1 -1
  115. package/lib/i18n/i18n.d.ts +124 -0
  116. package/lib/i18n/i18n.d.ts.map +1 -1
  117. package/lib/index.d.ts +4 -0
  118. package/lib/index.d.ts.map +1 -1
  119. package/lib/index.js +4 -0
  120. package/lib/index.js.map +1 -1
  121. package/lib/styles/gradients.d.ts +102 -0
  122. package/lib/styles/gradients.d.ts.map +1 -0
  123. package/lib/styles/gradients.js +232 -0
  124. package/lib/styles/gradients.js.map +1 -0
  125. package/lib/styles/index.d.ts +1 -0
  126. package/lib/styles/index.d.ts.map +1 -1
  127. package/lib/styles/index.js +1 -0
  128. package/lib/styles/index.js.map +1 -1
  129. package/lib/theme/themes/buildTheme.json +1 -2
  130. package/package.json +10 -9
@@ -16,7 +16,7 @@ cycle = true,
16
16
  /** A query selector that will determine which elements to cycle through with the arrow keys. The selector will be used in conjunction with [querySelectorAll](https://developer.mozilla.org/en-US/docs/Web/API/Document/querySelectorAll#selectors). */
17
17
  selector = focusable,
18
18
  /** Which keys are used to navigate through the list */
19
- dir = 'up-down' } = {},
19
+ dir = 'up-down', allowTabFocus = true } = {},
20
20
  /** Pass this prop in the internal dependencies when list is dynamic */
21
21
  dependencies = []) => {
22
22
  const [NextKey, PrevKey] = dir === 'up-down' ? ['ArrowDown', 'ArrowUp'] : ['ArrowRight', 'ArrowLeft'];
@@ -26,7 +26,8 @@ dependencies = []) => {
26
26
  setTimeout(() => {
27
27
  const focusableElements = Array.from(el.querySelectorAll(selector));
28
28
  if (focusableElements.length > 0) {
29
- focusableElements[0].tabIndex = 0;
29
+ if (allowTabFocus)
30
+ focusableElements[0].tabIndex = 0;
30
31
  focusableElements.slice(1).forEach(item => {
31
32
  if (item instanceof HTMLElement) {
32
33
  const checked = item.checked;
@@ -1 +1 @@
1
- {"version":3,"file":"useArrows.js","sourceRoot":"","sources":["../../src/hooks/useArrows.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,SAAS,EAAE,WAAW,EAA6B,MAAM,OAAO,CAAC;AAE1E,OAAO,EAAE,mBAAmB,EAAE,MAAM,UAAU,CAAC;AAE/C,MAAM,SAAS,GAAG;;;;;CAKjB,CAAC;AAEF;;;GAGG;AACH,MAAM,SAAS,GAAG,CAChB,GAA2B,EAC3B;AACE,yKAAyK;AACzK,KAAK,GAAG,IAAI;AACZ,wPAAwP;AACxP,QAAQ,GAAG,SAAS;AACpB,uDAAuD;AACvD,GAAG,GAAG,SAAS,KAC2D,EAAE;AAC9E,wEAAwE;AACxE,eAA+B,EAAE,EACjC,EAAE;IACF,MAAM,CAAC,OAAO,EAAE,OAAO,CAAC,GACtB,GAAG,KAAK,SAAS,CAAC,CAAC,CAAC,CAAC,WAAW,EAAE,SAAS,CAAC,CAAC,CAAC,CAAC,CAAC,YAAY,EAAE,WAAW,CAAC,CAAC;IAE7E,MAAM,aAAa,GAAG,WAAW,CAC/B,CAAC,EAAe,EAAE,EAAE;QAClB,kHAAkH;QAElH,uGAAuG;QACvG,UAAU,CAA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;IAC7B,CAAC,EACD,CAAC,GAAG,CAAC,OAAO,EAAE,KAAK,EAAE,QAAQ,EAAE,GAAG,YAAY,CAAC,CAChD,CAAC;IAEF,SAAS,CAAC,GAAG,EAAE;QACb,MAAM,EAAE,GAAG,GAAG,CAAC,OAAO,CAAC;QACvB,IAAI,CAAC,EAAE;YAAE,OAAO;QAEhB,aAAa,CAAC,EAAE,CAAC,CAAC;QAClB,EAAE,CAAC,gBAAgB,CAAC,SAAS,EAAE,QAAQ,CAAC,CAAC;QAEzC,OAAO,GAAG,EAAE;YACV,EAAE,CAAC,mBAAmB,CAAC,SAAS,EAAE,QAAQ,CAAC,CAAC;QAC9C,CAAC,CAAC;IACJ,CAAC,EAAE,CAAC,GAAG,CAAC,OAAO,EAAE,QAAQ,EAAE,QAAQ,EAAE,GAAG,YAAY,CAAC,CAAC,CAAC;AACzD,CAAC,CAAC;AAEF,eAAe,SAAS,CAAC","sourcesContent":["import { useEffect, useCallback, RefObject, DependencyList } from 'react';\n\nimport { documentIsAvailable } from '../utils';\n\nconst focusable = `\n a[href],\n button:enabled,\n input[type='checkbox']:enabled,\n input[type='radio']:enabled\n`;\n\n/**\n * @example useArrows(ref, { cycle, selector });\n * @param ref - A reference to the element that will be navigated through. [React RefObject](https://reactjs.org/docs/refs-and-the-dom.html)\n */\nconst useArrows = (\n ref: RefObject<HTMLElement>,\n {\n /** If true, the down or up arrow key will navigate to the first or last element if the element currently focused is the last or first index of the selected elements. */\n cycle = true,\n /** A query selector that will determine which elements to cycle through with the arrow keys. The selector will be used in conjunction with [querySelectorAll](https://developer.mozilla.org/en-US/docs/Web/API/Document/querySelectorAll#selectors). */\n selector = focusable,\n /** Which keys are used to navigate through the list */\n dir = 'up-down'\n }: { cycle?: boolean; selector?: string; dir?: 'up-down' | 'left-right' } = {},\n /** Pass this prop in the internal dependencies when list is dynamic */\n dependencies: DependencyList = []\n) => {\n const [NextKey, PrevKey] =\n dir === 'up-down' ? ['ArrowDown', 'ArrowUp'] : ['ArrowRight', 'ArrowLeft'];\n\n const setTabIndexes = useCallback(\n (el: HTMLElement) => {\n // don't set tabindex -1 for first element, or an element with a checked input inside of it to be able to focus it\n\n // 0 second timeout added because DOM needs to be up to date after list is updated before running query\n setTimeout(() => {\n const focusableElements = Array.from(el.querySelectorAll(selector));\n\n if (focusableElements.length > 0) {\n (focusableElements[0] as HTMLElement).tabIndex = 0;\n focusableElements.slice(1).forEach(item => {\n if (item instanceof HTMLElement) {\n const checked = (item as HTMLInputElement).checked;\n if (!checked) item.tabIndex = -1;\n }\n });\n }\n }, 0);\n },\n [selector, ...dependencies]\n );\n\n const listener = useCallback(\n (e: KeyboardEvent) => {\n if (['Home', 'End', NextKey, PrevKey].includes(e.key)) e.preventDefault();\n\n if (!documentIsAvailable) return;\n\n const el = ref.current;\n if (!el) return;\n\n const items = Array.from(el.querySelectorAll(selector)).filter(\n (item): item is HTMLElement => item instanceof HTMLElement\n );\n\n if (!items.length) return;\n\n const rootNode = el.getRootNode();\n\n if (!(rootNode instanceof Document) && !(rootNode instanceof ShadowRoot)) return;\n\n const focusIdx = items.indexOf(rootNode.activeElement as HTMLElement);\n const lastIdx = items.length - 1;\n let newFocusIdx;\n\n if (e.key === 'Home' || (e.key === NextKey && focusIdx === -1)) {\n newFocusIdx = 0;\n } else if (e.key === 'End' || (e.key === PrevKey && focusIdx === -1)) {\n newFocusIdx = lastIdx;\n } else if (e.key === 'Enter') {\n setTabIndexes(el);\n return;\n } else if (e.key === NextKey) {\n if (focusIdx === lastIdx) {\n if (!cycle) return;\n newFocusIdx = 0;\n } else {\n newFocusIdx = focusIdx + 1;\n }\n } else if (e.key === PrevKey) {\n if (focusIdx === 0) {\n if (!cycle) return;\n newFocusIdx = lastIdx;\n } else {\n newFocusIdx = focusIdx - 1;\n }\n } else {\n return;\n }\n\n items[newFocusIdx].focus();\n },\n [ref.current, cycle, selector, ...dependencies]\n );\n\n useEffect(() => {\n const el = ref.current;\n if (!el) return;\n\n setTabIndexes(el);\n el.addEventListener('keydown', listener);\n\n return () => {\n el.removeEventListener('keydown', listener);\n };\n }, [ref.current, selector, listener, ...dependencies]);\n};\n\nexport default useArrows;\n"]}
1
+ {"version":3,"file":"useArrows.js","sourceRoot":"","sources":["../../src/hooks/useArrows.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,SAAS,EAAE,WAAW,EAA6B,MAAM,OAAO,CAAC;AAE1E,OAAO,EAAE,mBAAmB,EAAE,MAAM,UAAU,CAAC;AAE/C,MAAM,SAAS,GAAG;;;;;CAKjB,CAAC;AAEF;;;GAGG;AACH,MAAM,SAAS,GAAG,CAChB,GAA2B,EAC3B;AACE,yKAAyK;AACzK,KAAK,GAAG,IAAI;AACZ,wPAAwP;AACxP,QAAQ,GAAG,SAAS;AACpB,uDAAuD;AACvD,GAAG,GAAG,SAAS,EACf,aAAa,GAAG,IAAI,KAMlB,EAAE;AACN,wEAAwE;AACxE,eAA+B,EAAE,EACjC,EAAE;IACF,MAAM,CAAC,OAAO,EAAE,OAAO,CAAC,GACtB,GAAG,KAAK,SAAS,CAAC,CAAC,CAAC,CAAC,WAAW,EAAE,SAAS,CAAC,CAAC,CAAC,CAAC,CAAC,YAAY,EAAE,WAAW,CAAC,CAAC;IAE7E,MAAM,aAAa,GAAG,WAAW,CAC/B,CAAC,EAAe,EAAE,EAAE;QAClB,kHAAkH;QAElH,uGAAuG;QACvG,UAAU,CAAC,GAAG,EAAE;YACd,MAAM,iBAAiB,GAAG,KAAK,CAAC,IAAI,CAAC,EAAE,CAAC,gBAAgB,CAAC,QAAQ,CAAC,CAAC,CAAC;YAEpE,IAAI,iBAAiB,CAAC,MAAM,GAAG,CAAC,EAAE;gBAChC,IAAI,aAAa;oBAAG,iBAAiB,CAAC,CAAC,CAAiB,CAAC,QAAQ,GAAG,CAAC,CAAC;gBACtE,iBAAiB,CAAC,KAAK,CAAC,CAAC,CAAC,CAAC,OAAO,CAAC,IAAI,CAAC,EAAE;oBACxC,IAAI,IAAI,YAAY,WAAW,EAA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AE,CAAC,mBAAmB,CAAC,SAAS,EAAE,QAAQ,CAAC,CAAC;QAC9C,CAAC,CAAC;IACJ,CAAC,EAAE,CAAC,GAAG,CAAC,OAAO,EAAE,QAAQ,EAAE,QAAQ,EAAE,GAAG,YAAY,CAAC,CAAC,CAAC;AACzD,CAAC,CAAC;AAEF,eAAe,SAAS,CAAC","sourcesContent":["import { useEffect, useCallback, RefObject, DependencyList } from 'react';\n\nimport { documentIsAvailable } from '../utils';\n\nconst focusable = `\n a[href],\n button:enabled,\n input[type='checkbox']:enabled,\n input[type='radio']:enabled\n`;\n\n/**\n * @example useArrows(ref, { cycle, selector });\n * @param ref - A reference to the element that will be navigated through. [React RefObject](https://reactjs.org/docs/refs-and-the-dom.html)\n */\nconst useArrows = (\n ref: RefObject<HTMLElement>,\n {\n /** If true, the down or up arrow key will navigate to the first or last element if the element currently focused is the last or first index of the selected elements. */\n cycle = true,\n /** A query selector that will determine which elements to cycle through with the arrow keys. The selector will be used in conjunction with [querySelectorAll](https://developer.mozilla.org/en-US/docs/Web/API/Document/querySelectorAll#selectors). */\n selector = focusable,\n /** Which keys are used to navigate through the list */\n dir = 'up-down',\n allowTabFocus = true\n }: {\n cycle?: boolean;\n selector?: string;\n dir?: 'up-down' | 'left-right';\n allowTabFocus?: boolean;\n } = {},\n /** Pass this prop in the internal dependencies when list is dynamic */\n dependencies: DependencyList = []\n) => {\n const [NextKey, PrevKey] =\n dir === 'up-down' ? ['ArrowDown', 'ArrowUp'] : ['ArrowRight', 'ArrowLeft'];\n\n const setTabIndexes = useCallback(\n (el: HTMLElement) => {\n // don't set tabindex -1 for first element, or an element with a checked input inside of it to be able to focus it\n\n // 0 second timeout added because DOM needs to be up to date after list is updated before running query\n setTimeout(() => {\n const focusableElements = Array.from(el.querySelectorAll(selector));\n\n if (focusableElements.length > 0) {\n if (allowTabFocus) (focusableElements[0] as HTMLElement).tabIndex = 0;\n focusableElements.slice(1).forEach(item => {\n if (item instanceof HTMLElement) {\n const checked = (item as HTMLInputElement).checked;\n if (!checked) item.tabIndex = -1;\n }\n });\n }\n }, 0);\n },\n [selector, ...dependencies]\n );\n\n const listener = useCallback(\n (e: KeyboardEvent) => {\n if (['Home', 'End', NextKey, PrevKey].includes(e.key)) e.preventDefault();\n\n if (!documentIsAvailable) return;\n\n const el = ref.current;\n if (!el) return;\n\n const items = Array.from(el.querySelectorAll(selector)).filter(\n (item): item is HTMLElement => item instanceof HTMLElement\n );\n\n if (!items.length) return;\n\n const rootNode = el.getRootNode();\n\n if (!(rootNode instanceof Document) && !(rootNode instanceof ShadowRoot)) return;\n\n const focusIdx = items.indexOf(rootNode.activeElement as HTMLElement);\n const lastIdx = items.length - 1;\n let newFocusIdx;\n\n if (e.key === 'Home' || (e.key === NextKey && focusIdx === -1)) {\n newFocusIdx = 0;\n } else if (e.key === 'End' || (e.key === PrevKey && focusIdx === -1)) {\n newFocusIdx = lastIdx;\n } else if (e.key === 'Enter') {\n setTabIndexes(el);\n return;\n } else if (e.key === NextKey) {\n if (focusIdx === lastIdx) {\n if (!cycle) return;\n newFocusIdx = 0;\n } else {\n newFocusIdx = focusIdx + 1;\n }\n } else if (e.key === PrevKey) {\n if (focusIdx === 0) {\n if (!cycle) return;\n newFocusIdx = lastIdx;\n } else {\n newFocusIdx = focusIdx - 1;\n }\n } else {\n return;\n }\n\n items[newFocusIdx].focus();\n },\n [ref.current, cycle, selector, ...dependencies]\n );\n\n useEffect(() => {\n const el = ref.current;\n if (!el) return;\n\n setTabIndexes(el);\n el.addEventListener('keydown', listener);\n\n return () => {\n el.removeEventListener('keydown', listener);\n };\n }, [ref.current, selector, listener, ...dependencies]);\n};\n\nexport default useArrows;\n"]}
@@ -8,6 +8,7 @@ declare const useI18n: () => import("../i18n/translate").TranslationFunction<Rea
8
8
  status: string;
9
9
  additional_info: string;
10
10
  search_placeholder_default: string;
11
+ description: string;
11
12
  remove: string;
12
13
  follow: string;
13
14
  unfollow: string;
@@ -29,6 +30,12 @@ declare const useI18n: () => import("../i18n/translate").TranslationFunction<Rea
29
30
  use: string;
30
31
  undo: string;
31
32
  redo: string;
33
+ filter: string;
34
+ sort: string;
35
+ group: string;
36
+ filter_by: string;
37
+ sort_by: string;
38
+ group_by: string;
32
39
  view_all: string;
33
40
  view_less: string;
34
41
  show_more: string;
@@ -37,6 +44,7 @@ declare const useI18n: () => import("../i18n/translate").TranslationFunction<Rea
37
44
  link_open_in_tab_text: string;
38
45
  edit_details: string;
39
46
  add_emoji: string;
47
+ create_new: string;
40
48
  close_noun: string;
41
49
  view_all_noun: string;
42
50
  view_less_noun: string;
@@ -57,6 +65,14 @@ declare const useI18n: () => import("../i18n/translate").TranslationFunction<Rea
57
65
  unknown_error: string;
58
66
  image_load_error: string;
59
67
  selected: string;
68
+ selected_count: {
69
+ zero: string;
70
+ one: string;
71
+ two: string;
72
+ few: string;
73
+ many: string;
74
+ other: string;
75
+ };
60
76
  day_label_a11y: string;
61
77
  day_placeholder: string;
62
78
  quarter_label_a11y: string;
@@ -182,6 +198,13 @@ declare const useI18n: () => import("../i18n/translate").TranslationFunction<Rea
182
198
  };
183
199
  edit_tags: string;
184
200
  tags: string;
201
+ timeline_toolbar_sort_descending: string;
202
+ timeline_toolbar_sort_ascending: string;
203
+ timeline_toolbar_group_date: string;
204
+ timeline_toolbar_group_monthyear: string;
205
+ timeline_toolbar_group_quarteryear: string;
206
+ timeline_toolbar_group_year: string;
207
+ timeline_toolbar_group_none: string;
185
208
  app_announcement_dismiss_button_label_a11y: string;
186
209
  app_announcement_details_list_header: string;
187
210
  app_announcement_whats_new_button_label: string;
@@ -208,6 +231,14 @@ declare const useI18n: () => import("../i18n/translate").TranslationFunction<Rea
208
231
  rte_unindent_selection: string;
209
232
  rte_toolbar_instructions: string;
210
233
  rte_text_formatting_toolbar: string;
234
+ rte_image_description_info: string;
235
+ rte_image_custom_size: string;
236
+ rte_width_in_pixels: string;
237
+ rte_height_in_pixels: string;
238
+ rte_image_settings: string;
239
+ rte_image_key_command: string;
240
+ expand_forwarded_message: string;
241
+ collapse_forwarded_message: string;
211
242
  feed_new_post: string;
212
243
  feed_cancel_conversation: string;
213
244
  feed_context: string;
@@ -246,6 +277,23 @@ declare const useI18n: () => import("../i18n/translate").TranslationFunction<Rea
246
277
  feed_post_removed: string;
247
278
  feed_reply_removed: string;
248
279
  showing_num_of_num: string;
280
+ feed_new_post_added: {
281
+ zero: string;
282
+ one: string;
283
+ two: string;
284
+ few: string;
285
+ many: string;
286
+ other: string;
287
+ };
288
+ new_item_added: {
289
+ zero: string;
290
+ one: string;
291
+ two: string;
292
+ few: string;
293
+ many: string;
294
+ other: string;
295
+ };
296
+ loading_post: string;
249
297
  scroll_to_latest_message: string;
250
298
  scroll_to_unread_messages: string;
251
299
  suggested_replies_current_of_total: string;
@@ -253,6 +301,14 @@ declare const useI18n: () => import("../i18n/translate").TranslationFunction<Rea
253
301
  next_suggested_reply: string;
254
302
  prev_suggested_reply: string;
255
303
  dismiss_suggested_replies: string;
304
+ unique_entities: {
305
+ zero: string;
306
+ one: string;
307
+ two: string;
308
+ few: string;
309
+ many: string;
310
+ other: string;
311
+ };
256
312
  more_count: string;
257
313
  empty_search: string;
258
314
  new_messages: string;
@@ -281,6 +337,7 @@ declare const useI18n: () => import("../i18n/translate").TranslationFunction<Rea
281
337
  email_add_attachment: string;
282
338
  email_disable_attachment: string;
283
339
  email_remove_attachment: string;
340
+ loading_email: string;
284
341
  article_list_label_a11y: string;
285
342
  article_list_filter_label_a11y: string;
286
343
  article_list_header_submit_label: string;
@@ -604,8 +661,13 @@ declare const useI18n: () => import("../i18n/translate").TranslationFunction<Rea
604
661
  add_alternate_stage: string;
605
662
  add_node: string;
606
663
  search_nodes: string;
664
+ delete_decision_step: string;
665
+ delete_decision_step_title: string;
666
+ delete_decision_step_outcome: string;
667
+ delete_all_outcomes: string;
607
668
  zoom_level: string;
608
669
  close_configuration_panel: string;
670
+ clear_object_summary: string;
609
671
  }>>;
610
672
  export default useI18n;
611
673
  //# sourceMappingURL=useI18n.d.ts.map
@@ -1 +1 @@
1
- {"version":3,"file":"useI18n.d.ts","sourceRoot":"","sources":["../../src/hooks/useI18n.ts"],"names":[],"mappings":"AAIA;;;GAGG;AACH,QAAA,MAAM,OAAO;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;GAGZ,CAAC;AAEF,eAAe,OAAO,CAAC"}
1
+ {"version":3,"file":"useI18n.d.ts","sourceRoot":"","sources":["../../src/hooks/useI18n.ts"],"names":[],"mappings":"AAIA;;;GAGG;AACH,QAAA,MAAM,OAAO;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;GAGZ,CAAC;AAEF,eAAe,OAAO,CAAC"}
@@ -1 +1 @@
1
- {"version":3,"file":"useItemIntersection.d.ts","sourceRoot":"","sources":["../../src/hooks/useItemIntersection.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,SAAS,EAAa,MAAM,OAAO,CAAC;AAE7C;;;;;;;GAOG;AAEH,QAAA,MAAM,mBAAmB,iBACT,UAAU,WAAW,CAAC,UAC5B,MAAM,MACV,MAAM,IAAI,gBACA,MAAM,SA6BrB,CAAC;AAEF,eAAe,mBAAmB,CAAC"}
1
+ {"version":3,"file":"useItemIntersection.d.ts","sourceRoot":"","sources":["../../src/hooks/useItemIntersection.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,SAAS,EAAa,MAAM,OAAO,CAAC;AAE7C;;;;;;;GAOG;AAEH,QAAA,MAAM,mBAAmB,iBACT,UAAU,WAAW,CAAC,UAC5B,MAAM,MACV,MAAM,IAAI,gBACA,MAAM,SA8BrB,CAAC;AAEF,eAAe,mBAAmB,CAAC"}
@@ -9,28 +9,26 @@ import { useEffect } from 'react';
9
9
  */
10
10
  const useItemIntersection = (containerRef, offset, cb, itemSelector) => {
11
11
  useEffect(() => {
12
- if (containerRef.current) {
13
- let item = null;
14
- if (offset > 0) {
15
- const items = containerRef.current.querySelectorAll(itemSelector);
16
- if (items.length > offset) {
17
- item = items[offset];
18
- }
19
- }
20
- if (item) {
21
- const intersectionObserver = new IntersectionObserver((entries) => {
22
- if (entries[0].isIntersecting) {
23
- cb();
24
- }
25
- }, {
26
- root: containerRef.current
27
- });
28
- intersectionObserver.observe(item);
29
- return () => {
30
- intersectionObserver.disconnect();
31
- };
12
+ let item = null;
13
+ if (offset > 0) {
14
+ const items = (containerRef.current === null ? document.body : containerRef.current).querySelectorAll(itemSelector);
15
+ if (items.length > offset) {
16
+ item = items[offset];
32
17
  }
33
18
  }
19
+ if (item) {
20
+ const intersectionObserver = new IntersectionObserver((entries) => {
21
+ if (entries[0].isIntersecting) {
22
+ cb();
23
+ }
24
+ }, {
25
+ root: containerRef.current
26
+ });
27
+ intersectionObserver.observe(item);
28
+ return () => {
29
+ intersectionObserver.disconnect();
30
+ };
31
+ }
34
32
  }, [cb, containerRef.current, offset]);
35
33
  };
36
34
  export default useItemIntersection;
@@ -1 +1 @@
1
- {"version":3,"file":"useItemIntersection.js","sourceRoot":"","sources":["../../src/hooks/useItemIntersection.ts"],"names":[],"mappings":"AAAA,OAAO,EAAa,SAAS,EAAE,MAAM,OAAO,CAAC;AAE7C;;;;;;;GAOG;AAEH,MAAM,mBAAmB,GAAG,CAC1B,YAAoC,EACpC,MAAc,EACd,EAAc,EACd,YAAoB,EACpB,EAAE;IACF,SAAS,CAAC,GAAG,EAAE;QACb,IAAI,YAAY,CAAC,OAAO,EAAE;YACxB,IAAI,IAAI,GAAuB,IAAI,CAAC;YACpC,IAAI,MAAM,GAAG,CAAC,EAAE;gBACd,MAAM,KAAK,GAA4B,YAAY,CAAC,OAAO,CAAC,gBAAgB,CAAC,YAAY,CAAC,CAAC;gBAC3F,IAAI,KAAK,CAAC,MAAM,GAAG,MAAM,EAAE;oBACzB,IAAI,GAAG,KAAK,CAAC,MAAM,CAAC,CAAC;iBACtB;aACF;YACD,IAAI,IAAI,EAAE;gBACR,MAAM,oBAAoB,GAAG,IAAI,oBAAoB,CACnD,CAAC,OAAoC,EAAE,EAAE;oBACvC,IAAI,OAAO,CAAC,CAAC,CAAC,CAAC,cAAc,EAAE;wBAC7B,EAAE,EAAE,CAAC;qBACN;gBACH,CAAC,EACD;oBACE,IAAI,EAAE,YAAY,CAAC,OAAO;iBAC3B,CACF,CAAC;gBACF,oBAAoB,CAAC,OAAO,CAAC,IAAI,CAAC,CAAC;gBACnC,OAAO,GAAG,EAAE;oBACV,oBAAoB,CAAC,UAAU,EAAE,CAAC;gBACpC,CAAC,CAAC;aACH;SACF;IACH,CAAC,EAAE,CAAC,EAAE,EAAE,YAAY,CAAC,OAAO,EAAE,MAAM,CAAC,CAAC,CAAC;AACzC,CAAC,CAAC;AAEF,eAAe,mBAAmB,CAAC","sourcesContent":["import { RefObject, useEffect } from 'react';\n\n/**\n * @example useItemIntersection(listRef,offset,() => { do_some_thing; });\n * @param containerRef The ref of the List.\n * @param offset Index of the list item which needs to be observed.\n * @param cb Callback that needs to be fired on intersect\n * @param itemSelector Selector used to get the node list of items\n * @returns void.\n */\n\nconst useItemIntersection = (\n containerRef: RefObject<HTMLElement>,\n offset: number,\n cb: () => void,\n itemSelector: string\n) => {\n useEffect(() => {\n if (containerRef.current) {\n let item: HTMLElement | null = null;\n if (offset > 0) {\n const items: NodeListOf<HTMLElement> = containerRef.current.querySelectorAll(itemSelector);\n if (items.length > offset) {\n item = items[offset];\n }\n }\n if (item) {\n const intersectionObserver = new IntersectionObserver(\n (entries: IntersectionObserverEntry[]) => {\n if (entries[0].isIntersecting) {\n cb();\n }\n },\n {\n root: containerRef.current\n }\n );\n intersectionObserver.observe(item);\n return () => {\n intersectionObserver.disconnect();\n };\n }\n }\n }, [cb, containerRef.current, offset]);\n};\n\nexport default useItemIntersection;\n"]}
1
+ {"version":3,"file":"useItemIntersection.js","sourceRoot":"","sources":["../../src/hooks/useItemIntersection.ts"],"names":[],"mappings":"AAAA,OAAO,EAAa,SAAS,EAAE,MAAM,OAAO,CAAC;AAE7C;;;;;;;GAOG;AAEH,MAAM,mBAAmB,GAAG,CAC1B,YAAoC,EACpC,MAAc,EACd,EAAc,EACd,YAAoB,EACpB,EAAE;IACF,SAAS,CAAC,GAAG,EAAE;QACb,IAAI,IAAI,GAAuB,IAAI,CAAC;QACpC,IAAI,MAAM,GAAG,CAAC,EAAE;YACd,MAAM,KAAK,GAA4B,CACrC,YAAY,CAAC,OAAO,KAAK,IAAI,CAAC,CAAC,CAAC,QAAQ,CAAC,IAAI,CAAC,CAAC,CAAC,YAAY,CAAC,OAAO,CACrE,CAAC,gBAAgB,CAAC,YAAY,CAAC,CAAC;YAEjC,IAAI,KAAK,CAAC,MAAM,GAAG,MAAM,EAAE;gBACzB,IAAI,GAAG,KAAK,CAAC,MAAM,CAAC,CAAC;aACtB;SACF;QACD,IAAI,IAAI,EAAE;YACR,MAAM,oBAAoB,GAAG,IAAI,oBAAoB,CACnD,CAAC,OAAoC,EAAE,EAAE;gBACvC,IAAI,OAAO,CAAC,CAAC,CAAC,CAAC,cAAc,EAAE;oBAC7B,EAAE,EAAE,CAAC;iBACN;YACH,CAAC,EACD;gBACE,IAAI,EAAE,YAAY,CAAC,OAAO;aAC3B,CACF,CAAC;YACF,oBAAoB,CAAC,OAAO,CAAC,IAAI,CAAC,CAAC;YACnC,OAAO,GAAG,EAAE;gBACV,oBAAoB,CAAC,UAAU,EAAE,CAAC;YACpC,CAAC,CAAC;SACH;IACH,CAAC,EAAE,CAAC,EAAE,EAAE,YAAY,CAAC,OAAO,EAAE,MAAM,CAAC,CAAC,CAAC;AACzC,CAAC,CAAC;AAEF,eAAe,mBAAmB,CAAC","sourcesContent":["import { RefObject, useEffect } from 'react';\n\n/**\n * @example useItemIntersection(listRef,offset,() => { do_some_thing; });\n * @param containerRef The ref of the List.\n * @param offset Index of the list item which needs to be observed.\n * @param cb Callback that needs to be fired on intersect\n * @param itemSelector Selector used to get the node list of items\n * @returns void.\n */\n\nconst useItemIntersection = (\n containerRef: RefObject<HTMLElement>,\n offset: number,\n cb: () => void,\n itemSelector: string\n) => {\n useEffect(() => {\n let item: HTMLElement | null = null;\n if (offset > 0) {\n const items: NodeListOf<HTMLElement> = (\n containerRef.current === null ? document.body : containerRef.current\n ).querySelectorAll(itemSelector);\n\n if (items.length > offset) {\n item = items[offset];\n }\n }\n if (item) {\n const intersectionObserver = new IntersectionObserver(\n (entries: IntersectionObserverEntry[]) => {\n if (entries[0].isIntersecting) {\n cb();\n }\n },\n {\n root: containerRef.current\n }\n );\n intersectionObserver.observe(item);\n return () => {\n intersectionObserver.disconnect();\n };\n }\n }, [cb, containerRef.current, offset]);\n};\n\nexport default useItemIntersection;\n"]}
@@ -4,6 +4,7 @@ declare const _default: {
4
4
  status: string;
5
5
  additional_info: string;
6
6
  search_placeholder_default: string;
7
+ description: string;
7
8
  remove: string;
8
9
  follow: string;
9
10
  unfollow: string;
@@ -25,6 +26,12 @@ declare const _default: {
25
26
  use: string;
26
27
  undo: string;
27
28
  redo: string;
29
+ filter: string;
30
+ sort: string;
31
+ group: string;
32
+ filter_by: string;
33
+ sort_by: string;
34
+ group_by: string;
28
35
  view_all: string;
29
36
  view_less: string;
30
37
  show_more: string;
@@ -33,6 +40,7 @@ declare const _default: {
33
40
  link_open_in_tab_text: string;
34
41
  edit_details: string;
35
42
  add_emoji: string;
43
+ create_new: string;
36
44
  close_noun: string;
37
45
  view_all_noun: string;
38
46
  view_less_noun: string;
@@ -53,6 +61,14 @@ declare const _default: {
53
61
  unknown_error: string;
54
62
  image_load_error: string;
55
63
  selected: string;
64
+ selected_count: {
65
+ zero: string;
66
+ one: string;
67
+ two: string;
68
+ few: string;
69
+ many: string;
70
+ other: string;
71
+ };
56
72
  day_label_a11y: string;
57
73
  day_placeholder: string;
58
74
  quarter_label_a11y: string;
@@ -178,6 +194,13 @@ declare const _default: {
178
194
  };
179
195
  edit_tags: string;
180
196
  tags: string;
197
+ timeline_toolbar_sort_descending: string;
198
+ timeline_toolbar_sort_ascending: string;
199
+ timeline_toolbar_group_date: string;
200
+ timeline_toolbar_group_monthyear: string;
201
+ timeline_toolbar_group_quarteryear: string;
202
+ timeline_toolbar_group_year: string;
203
+ timeline_toolbar_group_none: string;
181
204
  app_announcement_dismiss_button_label_a11y: string;
182
205
  app_announcement_details_list_header: string;
183
206
  app_announcement_whats_new_button_label: string;
@@ -204,6 +227,14 @@ declare const _default: {
204
227
  rte_unindent_selection: string;
205
228
  rte_toolbar_instructions: string;
206
229
  rte_text_formatting_toolbar: string;
230
+ rte_image_description_info: string;
231
+ rte_image_custom_size: string;
232
+ rte_width_in_pixels: string;
233
+ rte_height_in_pixels: string;
234
+ rte_image_settings: string;
235
+ rte_image_key_command: string;
236
+ expand_forwarded_message: string;
237
+ collapse_forwarded_message: string;
207
238
  feed_new_post: string;
208
239
  feed_cancel_conversation: string;
209
240
  feed_context: string;
@@ -242,6 +273,23 @@ declare const _default: {
242
273
  feed_post_removed: string;
243
274
  feed_reply_removed: string;
244
275
  showing_num_of_num: string;
276
+ feed_new_post_added: {
277
+ zero: string;
278
+ one: string;
279
+ two: string;
280
+ few: string;
281
+ many: string;
282
+ other: string;
283
+ };
284
+ new_item_added: {
285
+ zero: string;
286
+ one: string;
287
+ two: string;
288
+ few: string;
289
+ many: string;
290
+ other: string;
291
+ };
292
+ loading_post: string;
245
293
  scroll_to_latest_message: string;
246
294
  scroll_to_unread_messages: string;
247
295
  suggested_replies_current_of_total: string;
@@ -249,6 +297,14 @@ declare const _default: {
249
297
  next_suggested_reply: string;
250
298
  prev_suggested_reply: string;
251
299
  dismiss_suggested_replies: string;
300
+ unique_entities: {
301
+ zero: string;
302
+ one: string;
303
+ two: string;
304
+ few: string;
305
+ many: string;
306
+ other: string;
307
+ };
252
308
  more_count: string;
253
309
  empty_search: string;
254
310
  new_messages: string;
@@ -277,6 +333,7 @@ declare const _default: {
277
333
  email_add_attachment: string;
278
334
  email_disable_attachment: string;
279
335
  email_remove_attachment: string;
336
+ loading_email: string;
280
337
  article_list_label_a11y: string;
281
338
  article_list_filter_label_a11y: string;
282
339
  article_list_header_submit_label: string;
@@ -600,8 +657,13 @@ declare const _default: {
600
657
  add_alternate_stage: string;
601
658
  add_node: string;
602
659
  search_nodes: string;
660
+ delete_decision_step: string;
661
+ delete_decision_step_title: string;
662
+ delete_decision_step_outcome: string;
663
+ delete_all_outcomes: string;
603
664
  zoom_level: string;
604
665
  close_configuration_panel: string;
666
+ clear_object_summary: string;
605
667
  };
606
668
  export default _default;
607
669
  //# sourceMappingURL=default.d.ts.map
@@ -1 +1 @@
1
- {"version":3,"file":"default.d.ts","sourceRoot":"","sources":["../../src/i18n/default.ts"],"names":[],"mappings":";;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;AAAA,wBA4rBE"}
1
+ {"version":3,"file":"default.d.ts","sourceRoot":"","sources":["../../src/i18n/default.ts"],"names":[],"mappings":";;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;AAAA,wBAiwBE"}
@@ -8,6 +8,7 @@ export default {
8
8
  status: 'Status',
9
9
  additional_info: 'Additional info',
10
10
  search_placeholder_default: 'Search…',
11
+ description: 'Description',
11
12
  /* Verbs */
12
13
  remove: 'Remove',
13
14
  follow: 'Follow',
@@ -30,6 +31,12 @@ export default {
30
31
  use: 'Use',
31
32
  undo: 'Undo',
32
33
  redo: 'Redo',
34
+ filter: 'Filter',
35
+ sort: 'Sort',
36
+ group: 'Group',
37
+ filter_by: 'Filter by',
38
+ sort_by: 'Sort by',
39
+ group_by: 'Group by',
33
40
  /* Static verb noun */
34
41
  view_all: 'View all',
35
42
  view_less: 'View less',
@@ -39,6 +46,7 @@ export default {
39
46
  link_open_in_tab_text: 'Open in tab',
40
47
  edit_details: 'Edit details',
41
48
  add_emoji: 'Add emoji',
49
+ create_new: 'Create new',
42
50
  /* Dynamic verb {noun} */
43
51
  close_noun: 'Close: {0}',
44
52
  view_all_noun: 'View all: {0}',
@@ -61,6 +69,14 @@ export default {
61
69
  unknown_error: 'Unknown error',
62
70
  image_load_error: 'Error loading image',
63
71
  selected: 'Selected',
72
+ selected_count: {
73
+ zero: '{0} selected',
74
+ one: '{0} selected',
75
+ two: '{0} selected',
76
+ few: '{0} selected',
77
+ many: '{0} selected',
78
+ other: '{0} selected'
79
+ },
64
80
  /* Date and time */
65
81
  day_label_a11y: 'Day',
66
82
  day_placeholder: 'DD',
@@ -210,6 +226,14 @@ export default {
210
226
  /* work:Tags */
211
227
  edit_tags: 'Edit tags',
212
228
  tags: 'Tags',
229
+ /* work:Timeline */
230
+ timeline_toolbar_sort_descending: 'Newest first',
231
+ timeline_toolbar_sort_ascending: 'Oldest first',
232
+ timeline_toolbar_group_date: 'By day',
233
+ timeline_toolbar_group_monthyear: 'By month',
234
+ timeline_toolbar_group_quarteryear: 'By quarter',
235
+ timeline_toolbar_group_year: 'By year',
236
+ timeline_toolbar_group_none: 'Off',
213
237
  /* work:AppAnnouncement */
214
238
  app_announcement_dismiss_button_label_a11y: 'Hide until next update',
215
239
  app_announcement_details_list_header: 'Announcements',
@@ -238,6 +262,15 @@ export default {
238
262
  rte_unindent_selection: 'Unindent selection',
239
263
  rte_toolbar_instructions: 'Hit tab to enter the editor toolbar',
240
264
  rte_text_formatting_toolbar: 'Text formatting toolbar',
265
+ rte_image_description_info: 'Provides an alternate (ALT) description for the visually impaired',
266
+ rte_image_custom_size: 'Custom size',
267
+ rte_width_in_pixels: 'Width (in pixels)',
268
+ rte_height_in_pixels: 'Height (in pixels)',
269
+ rte_image_settings: 'Image settings',
270
+ rte_image_key_command: 'Press enter to edit the image',
271
+ /* social:Email */
272
+ expand_forwarded_message: 'Expand forwarded message',
273
+ collapse_forwarded_message: 'Collapse forwarded message',
241
274
  /* social:Feed */
242
275
  feed_new_post: 'New post',
243
276
  feed_cancel_conversation: 'Cancel conversation',
@@ -277,6 +310,23 @@ export default {
277
310
  feed_post_removed: 'Post has been removed',
278
311
  feed_reply_removed: 'Reply has been removed',
279
312
  showing_num_of_num: 'Showing {0} of {1}',
313
+ feed_new_post_added: {
314
+ zero: 'No posts added',
315
+ one: '{0} post added',
316
+ two: '{0} posts added',
317
+ few: '{0} posts added',
318
+ many: '{0} posts added',
319
+ other: '{0} posts added'
320
+ },
321
+ new_item_added: {
322
+ zero: 'No items added',
323
+ one: '{0} new item added',
324
+ two: '{0} new items added',
325
+ few: '{0} new items added',
326
+ many: '{0} new items added',
327
+ other: '{0} new items added'
328
+ },
329
+ loading_post: 'Loading post',
280
330
  /* cs:Chat */
281
331
  scroll_to_latest_message: 'Scroll to latest message',
282
332
  scroll_to_unread_messages: 'Scroll to unread messages',
@@ -286,6 +336,14 @@ export default {
286
336
  prev_suggested_reply: 'Previous suggested reply',
287
337
  dismiss_suggested_replies: 'Dismiss suggested replies',
288
338
  /* cs:Email */
339
+ unique_entities: {
340
+ zero: 'No unique entities',
341
+ one: '{0} unique entity',
342
+ two: '{0} unique entities',
343
+ few: '{0} unique entities',
344
+ many: '{0} unique entities',
345
+ other: '{0} unique entities'
346
+ },
289
347
  more_count: '{0} more…',
290
348
  empty_search: 'Enter a search term',
291
349
  new_messages: 'New messages',
@@ -314,6 +372,7 @@ export default {
314
372
  email_add_attachment: 'Add attachment, the maximum number of attachments allowed is {0}.',
315
373
  email_disable_attachment: 'Adding attachments are disabled, the maximum number of attachments allowed is {0}.',
316
374
  email_remove_attachment: 'Remove attachment',
375
+ loading_email: 'Loading email',
317
376
  /* cs:ArticleList */
318
377
  article_list_label_a11y: 'Article list',
319
378
  article_list_filter_label_a11y: 'Article lists filter',
@@ -384,10 +443,10 @@ export default {
384
443
  task_manager_picker_add_label: {
385
444
  zero: 'No items to add',
386
445
  one: 'Add {0} new item',
387
- two: 'Add {0} new item',
388
- few: 'Add {0} new item',
389
- many: 'Add {0} new item',
390
- other: 'Add {0} new item'
446
+ two: 'Add {0} new items',
447
+ few: 'Add {0} new items',
448
+ many: 'Add {0} new items',
449
+ other: 'Add {0} new items'
391
450
  },
392
451
  /* cs:Sentiment */
393
452
  sentiment_positive: 'Positive',
@@ -648,8 +707,14 @@ export default {
648
707
  /* build:FlowModeller */
649
708
  add_node: 'Add node',
650
709
  search_nodes: 'Search nodes',
710
+ delete_decision_step: 'Select outcome that you want to retain. The remaining highlighted outcome and steps will be deleted',
711
+ delete_decision_step_title: 'Delete step',
712
+ delete_decision_step_outcome: 'Outcome to keep',
713
+ delete_all_outcomes: 'None (delete all outcomes)',
651
714
  /* build:Workbench */
652
715
  zoom_level: 'Zoom level',
653
- close_configuration_panel: 'Close configuration panel'
716
+ close_configuration_panel: 'Close configuration panel',
717
+ /* build:ObjectSelect */
718
+ clear_object_summary: 'Clear {0} selection'
654
719
  };
655
720
  //# sourceMappingURL=default.js.map