@dxos/react-ui-thread 0.8.3-staging.0fa589b → 0.8.4-main.1068cf700f

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/src/index.ts CHANGED
@@ -2,9 +2,9 @@
2
2
  // Copyright 2023 DXOS.org
3
3
  //
4
4
 
5
- import translations from './translations';
5
+ import { translations } from './translations';
6
6
 
7
7
  export * from './Thread';
8
8
  export * from './Message';
9
- export * from './types';
9
+ export type * from './types';
10
10
  export { translations };
package/src/testing.tsx CHANGED
@@ -2,11 +2,10 @@
2
2
  // Copyright 2024 DXOS.org
3
3
  //
4
4
 
5
- import { X } from '@phosphor-icons/react';
6
- import React, { type PropsWithChildren } from 'react';
5
+ import React from 'react';
7
6
 
8
- import { Button } from '@dxos/react-ui';
9
- import { hoverableControlItem, hoverableControls, hoverableFocusedWithinControls, mx } from '@dxos/react-ui-theme';
7
+ import { IconButton } from '@dxos/react-ui';
8
+ import { hoverableControlItem, hoverableControls, hoverableFocusedWithinControls, mx } from '@dxos/ui-theme';
10
9
 
11
10
  import { MessageBody, MessageHeading } from './Message';
12
11
  import { type MessageMetadata } from './types';
@@ -26,13 +25,14 @@ export const MessageStoryText = ({ text, onDelete, authorName, timestamp }: Mess
26
25
  <>
27
26
  <MessageHeading authorName={authorName} timestamp={timestamp}>
28
27
  {onDelete && (
29
- <Button
28
+ <IconButton
29
+ icon='ph--x--regular'
30
+ iconOnly
31
+ label='Delete'
30
32
  variant='ghost'
31
33
  classNames={['p-1.5 min-bs-0 mie-1 items-start transition-opacity', hoverableControlItem]}
32
34
  onClick={() => onDelete()}
33
- >
34
- <X />
35
- </Button>
35
+ />
36
36
  )}
37
37
  </MessageHeading>
38
38
  <MessageBody>{text}</MessageBody>
@@ -56,7 +56,3 @@ export const MessageStoryBlock = <PartValue,>({ part }: MessagePartProps<PartVal
56
56
  </div>
57
57
  );
58
58
  };
59
-
60
- export const ThreadStoryContainer = ({ children }: PropsWithChildren) => {
61
- return <div className={mx('bg-white dark:bg-black mli-auto is-96 overflow-y-auto')}>{children}</div>;
62
- };
@@ -2,9 +2,11 @@
2
2
  // Copyright 2023 DXOS.org
3
3
  //
4
4
 
5
- export const translationKey = 'thread';
5
+ import { type Resource } from '@dxos/react-ui';
6
6
 
7
- export default [
7
+ export const translationKey = '@dxos/react-ui-thread';
8
+
9
+ export const translations = [
8
10
  {
9
11
  'en-US': {
10
12
  [translationKey]: {
@@ -21,4 +23,4 @@ export default [
21
23
  },
22
24
  },
23
25
  },
24
- ];
26
+ ] as const satisfies Resource[];