@box/threaded-annotations 1.95.2 → 1.96.1
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/chunks/annotation-badge.js +15 -14
- package/dist/chunks/message-editor2.module.js +26 -24
- package/dist/chunks/timestamp-toggle.js +36 -0
- package/dist/esm/lib/components/v2/message-editor/message-editor.js +77 -69
- package/dist/esm/lib/components/v2/message-editor/messages.js +4 -0
- package/dist/esm/lib/components/v2/message-editor/subcomponents/timestamp-toggle.js +2 -0
- package/dist/i18n/bn-IN.js +1 -0
- package/dist/i18n/bn-IN.properties +4 -0
- package/dist/i18n/da-DK.js +1 -0
- package/dist/i18n/da-DK.properties +4 -0
- package/dist/i18n/de-DE.js +1 -0
- package/dist/i18n/de-DE.properties +4 -0
- package/dist/i18n/en-AU.js +1 -0
- package/dist/i18n/en-AU.properties +4 -0
- package/dist/i18n/en-CA.js +1 -0
- package/dist/i18n/en-CA.properties +4 -0
- package/dist/i18n/en-GB.js +1 -0
- package/dist/i18n/en-GB.properties +4 -0
- package/dist/i18n/en-US.js +1 -0
- package/dist/i18n/en-US.properties +2 -0
- package/dist/i18n/en-x-pseudo.js +2 -1
- package/dist/i18n/en-x-pseudo.properties +4 -0
- package/dist/i18n/es-419.js +1 -0
- package/dist/i18n/es-419.properties +4 -0
- package/dist/i18n/es-ES.js +1 -0
- package/dist/i18n/es-ES.properties +4 -0
- package/dist/i18n/fi-FI.js +1 -0
- package/dist/i18n/fi-FI.properties +4 -0
- package/dist/i18n/fr-CA.js +1 -0
- package/dist/i18n/fr-CA.properties +4 -0
- package/dist/i18n/fr-FR.js +1 -0
- package/dist/i18n/fr-FR.properties +4 -0
- package/dist/i18n/hi-IN.js +1 -0
- package/dist/i18n/hi-IN.properties +4 -0
- package/dist/i18n/it-IT.js +1 -0
- package/dist/i18n/it-IT.properties +4 -0
- package/dist/i18n/ja-JP.js +1 -0
- package/dist/i18n/ja-JP.properties +4 -0
- package/dist/i18n/json/src/lib/components/v2/message-editor/messages.json +1 -1
- package/dist/i18n/ko-KR.js +1 -0
- package/dist/i18n/ko-KR.properties +4 -0
- package/dist/i18n/nb-NO.js +1 -0
- package/dist/i18n/nb-NO.properties +4 -0
- package/dist/i18n/nl-NL.js +1 -0
- package/dist/i18n/nl-NL.properties +4 -0
- package/dist/i18n/pl-PL.js +1 -0
- package/dist/i18n/pl-PL.properties +4 -0
- package/dist/i18n/pt-BR.js +1 -0
- package/dist/i18n/pt-BR.properties +4 -0
- package/dist/i18n/ru-RU.js +1 -0
- package/dist/i18n/ru-RU.properties +4 -0
- package/dist/i18n/sv-SE.js +1 -0
- package/dist/i18n/sv-SE.properties +4 -0
- package/dist/i18n/tr-TR.js +1 -0
- package/dist/i18n/tr-TR.properties +4 -0
- package/dist/i18n/zh-CN.js +1 -0
- package/dist/i18n/zh-CN.properties +4 -0
- package/dist/i18n/zh-TW.js +1 -0
- package/dist/i18n/zh-TW.properties +4 -0
- package/dist/styles/message-editor2.css +1 -1
- package/dist/styles/timestamp-toggle.css +1 -0
- package/dist/types/index.d.ts +1 -0
- package/dist/types/lib/components/v2/message-editor/message-editor.types.d.ts +15 -0
- package/dist/types/lib/components/v2/message-editor/messages.d.ts +5 -0
- package/dist/types/lib/components/v2/message-editor/stories/shared.d.ts +1 -1
- package/dist/types/lib/components/v2/message-editor/subcomponents/timestamp-toggle.d.ts +9 -0
- package/dist/types/lib/v2/test-utils/test-selectors.d.ts +1 -0
- package/package.json +11 -11
|
@@ -6,6 +6,19 @@ export declare enum MessageEditorVariant {
|
|
|
6
6
|
EDIT_MESSAGE = "EDIT_MESSAGE"
|
|
7
7
|
}
|
|
8
8
|
type MessageActionCallback = (content: JSONContent | null) => Promise<TextMessageType | void> | TextMessageType | void;
|
|
9
|
+
/**
|
|
10
|
+
* Opt-in config for the editor-footer timestamp toggle. Pressed state is
|
|
11
|
+
* controlled by the host; this component does not modify the editor document
|
|
12
|
+
* to record the toggle.
|
|
13
|
+
*/
|
|
14
|
+
export interface VideoTimestampOptions {
|
|
15
|
+
/** Display-formatted timestamp (e.g. "00:43") shown in the toggle. May change as playback progresses. */
|
|
16
|
+
formattedTimestamp: string;
|
|
17
|
+
/** Pressed state of the timestamp toggle. */
|
|
18
|
+
isPressed: boolean;
|
|
19
|
+
/** Called when the user toggles the timestamp pill. */
|
|
20
|
+
onPressedChange: (pressed: boolean) => void;
|
|
21
|
+
}
|
|
9
22
|
interface BaseMessageEditorProps {
|
|
10
23
|
disableComponent?: boolean;
|
|
11
24
|
/** When true (create mode only), editor does not expand to full width. Defaults to false. */
|
|
@@ -21,6 +34,8 @@ interface BaseMessageEditorProps {
|
|
|
21
34
|
maxCharacterCount?: number;
|
|
22
35
|
/** Properties for the user selector component from blueprint-web. */
|
|
23
36
|
userSelectorProps: Omit<HeadlessUserSelectorProps, 'inputElementRef' | 'onSelectedUserChange' | 'open' | 'rootElement' | 'value'>;
|
|
37
|
+
/** When provided, renders the timestamp toggle in the editor footer. */
|
|
38
|
+
videoTimestamp?: VideoTimestampOptions;
|
|
24
39
|
}
|
|
25
40
|
export interface CreateMessageEditorProps extends BaseMessageEditorProps {
|
|
26
41
|
/**
|
|
@@ -4,5 +4,5 @@ export declare const defaultUserSelectorProps: Omit<import('@box/user-selector')
|
|
|
4
4
|
type DefaultMessageEditorProps = MessageEditorProps & {
|
|
5
5
|
fetchCollaboratorState?: (user: UserContactType) => Promise<boolean>;
|
|
6
6
|
};
|
|
7
|
-
export declare const DefaultMessageEditor: ({ fetchCollaboratorState, ...props }: DefaultMessageEditorProps) => import("react/jsx-runtime").JSX.Element;
|
|
7
|
+
export declare const DefaultMessageEditor: ({ fetchCollaboratorState, videoTimestamp, ...props }: DefaultMessageEditorProps) => import("react/jsx-runtime").JSX.Element;
|
|
8
8
|
export {};
|
|
@@ -0,0 +1,9 @@
|
|
|
1
|
+
export interface TimestampToggleProps {
|
|
2
|
+
className?: string;
|
|
3
|
+
disabled?: boolean;
|
|
4
|
+
formattedTimestamp: string;
|
|
5
|
+
isPressed: boolean;
|
|
6
|
+
/** Synchronous; throws propagate to the React error boundary. */
|
|
7
|
+
onChange: (isPressed: boolean) => void;
|
|
8
|
+
}
|
|
9
|
+
export declare const TimestampToggle: ({ className, disabled, formattedTimestamp, isPressed, onChange, }: TimestampToggleProps) => import("react/jsx-runtime").JSX.Element;
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@box/threaded-annotations",
|
|
3
|
-
"version": "1.
|
|
3
|
+
"version": "1.96.1",
|
|
4
4
|
"license": "SEE LICENSE IN LICENSE",
|
|
5
5
|
"dependencies": {
|
|
6
6
|
"@tanstack/react-virtual": "^3.10.8",
|
|
@@ -16,23 +16,23 @@
|
|
|
16
16
|
"uuid": "^9.0.1"
|
|
17
17
|
},
|
|
18
18
|
"peerDependencies": {
|
|
19
|
-
"@box/blueprint-web": "^15.
|
|
20
|
-
"@box/blueprint-web-assets": "^4.123.
|
|
21
|
-
"@box/collaboration-popover": "^1.63.
|
|
22
|
-
"@box/readable-time": "^1.42.
|
|
23
|
-
"@box/user-selector": "^1.77.
|
|
19
|
+
"@box/blueprint-web": "^15.6.0",
|
|
20
|
+
"@box/blueprint-web-assets": "^4.123.2",
|
|
21
|
+
"@box/collaboration-popover": "^1.63.13",
|
|
22
|
+
"@box/readable-time": "^1.42.13",
|
|
23
|
+
"@box/user-selector": "^1.77.13",
|
|
24
24
|
"clsx": "^1.2.1",
|
|
25
25
|
"react": "^18.0.0",
|
|
26
26
|
"react-dom": "^18.0.0",
|
|
27
27
|
"react-intl": "^6.4.2"
|
|
28
28
|
},
|
|
29
29
|
"devDependencies": {
|
|
30
|
-
"@box/blueprint-web": "^15.
|
|
31
|
-
"@box/blueprint-web-assets": "^4.123.
|
|
30
|
+
"@box/blueprint-web": "^15.6.0",
|
|
31
|
+
"@box/blueprint-web-assets": "^4.123.2",
|
|
32
32
|
"@box/eslint-plugin-blueprint": "1.2.5",
|
|
33
|
-
"@box/readable-time": "^1.42.
|
|
34
|
-
"@box/storybook-utils": "^0.20.
|
|
35
|
-
"@box/user-selector": "^1.77.
|
|
33
|
+
"@box/readable-time": "^1.42.13",
|
|
34
|
+
"@box/storybook-utils": "^0.20.12",
|
|
35
|
+
"@box/user-selector": "^1.77.13",
|
|
36
36
|
"react": "^18.0.0",
|
|
37
37
|
"react-dom": "^18.0.0"
|
|
38
38
|
},
|