@dxos/react-ui 0.6.9 → 0.6.10-main.3cfcc89

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 (102) hide show
  1. package/dist/lib/browser/index.mjs +332 -300
  2. package/dist/lib/browser/index.mjs.map +4 -4
  3. package/dist/lib/browser/meta.json +1 -1
  4. package/dist/types/src/components/Avatars/Avatar.d.ts +5 -0
  5. package/dist/types/src/components/Avatars/Avatar.d.ts.map +1 -1
  6. package/dist/types/src/components/Avatars/Avatar.stories.d.ts +1 -1
  7. package/dist/types/src/components/Avatars/Avatar.stories.d.ts.map +1 -1
  8. package/dist/types/src/components/Avatars/AvatarGroup.stories.d.ts +1 -1
  9. package/dist/types/src/components/Avatars/AvatarGroup.stories.d.ts.map +1 -1
  10. package/dist/types/src/components/Breadcrumb/Breadcrumb.stories.d.ts +1 -1
  11. package/dist/types/src/components/Breadcrumb/Breadcrumb.stories.d.ts.map +1 -1
  12. package/dist/types/src/components/Buttons/Button.stories.d.ts +1 -1
  13. package/dist/types/src/components/Buttons/Button.stories.d.ts.map +1 -1
  14. package/dist/types/src/components/Buttons/Toggle.stories.d.ts +1 -1
  15. package/dist/types/src/components/Buttons/Toggle.stories.d.ts.map +1 -1
  16. package/dist/types/src/components/Buttons/ToggleGroup.stories.d.ts +1 -1
  17. package/dist/types/src/components/Buttons/ToggleGroup.stories.d.ts.map +1 -1
  18. package/dist/types/src/components/Dialogs/AlertDialog.stories.d.ts +1 -1
  19. package/dist/types/src/components/Dialogs/AlertDialog.stories.d.ts.map +1 -1
  20. package/dist/types/src/components/Dialogs/Dialog.stories.d.ts +1 -1
  21. package/dist/types/src/components/Dialogs/Dialog.stories.d.ts.map +1 -1
  22. package/dist/types/src/components/Icon/Icon.d.ts +10 -0
  23. package/dist/types/src/components/Icon/Icon.d.ts.map +1 -0
  24. package/dist/types/src/components/Icon/index.d.ts +2 -0
  25. package/dist/types/src/components/Icon/index.d.ts.map +1 -0
  26. package/dist/types/src/components/Input/Input.stories.d.ts +1 -1
  27. package/dist/types/src/components/Input/Input.stories.d.ts.map +1 -1
  28. package/dist/types/src/components/Link/Link.stories.d.ts +1 -1
  29. package/dist/types/src/components/Link/Link.stories.d.ts.map +1 -1
  30. package/dist/types/src/components/Lists/List.stories.d.ts +1 -1
  31. package/dist/types/src/components/Lists/List.stories.d.ts.map +1 -1
  32. package/dist/types/src/components/Lists/Tree.stories.d.ts +1 -1
  33. package/dist/types/src/components/Lists/Tree.stories.d.ts.map +1 -1
  34. package/dist/types/src/components/Lists/Treegrid.stories.d.ts.map +1 -1
  35. package/dist/types/src/components/Main/Main.stories.d.ts +1 -1
  36. package/dist/types/src/components/Main/Main.stories.d.ts.map +1 -1
  37. package/dist/types/src/components/Menus/ContextMenu.stories.d.ts +1 -1
  38. package/dist/types/src/components/Menus/ContextMenu.stories.d.ts.map +1 -1
  39. package/dist/types/src/components/Menus/DropdownMenu.stories.d.ts +1 -1
  40. package/dist/types/src/components/Menus/DropdownMenu.stories.d.ts.map +1 -1
  41. package/dist/types/src/components/Message/Message.stories.d.ts +1 -1
  42. package/dist/types/src/components/Message/Message.stories.d.ts.map +1 -1
  43. package/dist/types/src/components/Popover/Popover.stories.d.ts +1 -1
  44. package/dist/types/src/components/Popover/Popover.stories.d.ts.map +1 -1
  45. package/dist/types/src/components/ScrollArea/ScrollArea.stories.d.ts +1 -1
  46. package/dist/types/src/components/ScrollArea/ScrollArea.stories.d.ts.map +1 -1
  47. package/dist/types/src/components/Select/Select.stories.d.ts +1 -1
  48. package/dist/types/src/components/Select/Select.stories.d.ts.map +1 -1
  49. package/dist/types/src/components/Status/Status.stories.d.ts +1 -1
  50. package/dist/types/src/components/Status/Status.stories.d.ts.map +1 -1
  51. package/dist/types/src/components/Tag/Tag.stories.d.ts +1 -1
  52. package/dist/types/src/components/Tag/Tag.stories.d.ts.map +1 -1
  53. package/dist/types/src/components/Toast/Toast.stories.d.ts +1 -1
  54. package/dist/types/src/components/Toast/Toast.stories.d.ts.map +1 -1
  55. package/dist/types/src/components/Toolbar/Toolbar.stories.d.ts +1 -1
  56. package/dist/types/src/components/Toolbar/Toolbar.stories.d.ts.map +1 -1
  57. package/dist/types/src/components/Tooltip/Tooltip.stories.d.ts +1 -1
  58. package/dist/types/src/components/Tooltip/Tooltip.stories.d.ts.map +1 -1
  59. package/dist/types/src/components/index.d.ts +1 -0
  60. package/dist/types/src/components/index.d.ts.map +1 -1
  61. package/dist/types/src/playground/Controls.stories.d.ts +1 -1
  62. package/dist/types/src/playground/Controls.stories.d.ts.map +1 -1
  63. package/dist/types/src/playground/Surfaces.stories.d.ts +1 -1
  64. package/dist/types/src/playground/Surfaces.stories.d.ts.map +1 -1
  65. package/dist/types/src/playground/Typography.stories.d.ts +1 -1
  66. package/dist/types/src/playground/Typography.stories.d.ts.map +1 -1
  67. package/dist/types/src/playground/helpers.d.ts +1 -1
  68. package/dist/types/src/playground/helpers.d.ts.map +1 -1
  69. package/package.json +10 -9
  70. package/src/components/Avatars/Avatar.stories.tsx +1 -1
  71. package/src/components/Avatars/Avatar.tsx +20 -0
  72. package/src/components/Avatars/AvatarGroup.stories.tsx +1 -1
  73. package/src/components/Breadcrumb/Breadcrumb.stories.tsx +2 -2
  74. package/src/components/Buttons/Button.stories.tsx +1 -1
  75. package/src/components/Buttons/Toggle.stories.tsx +1 -1
  76. package/src/components/Buttons/ToggleGroup.stories.tsx +1 -1
  77. package/src/components/Dialogs/AlertDialog.stories.tsx +1 -1
  78. package/src/components/Dialogs/Dialog.stories.tsx +1 -1
  79. package/src/components/Icon/Icon.tsx +22 -0
  80. package/src/components/Icon/index.ts +5 -0
  81. package/src/components/Input/Input.stories.tsx +1 -1
  82. package/src/components/Link/Link.stories.tsx +1 -1
  83. package/src/components/Lists/List.stories.tsx +1 -1
  84. package/src/components/Lists/Tree.stories.tsx +1 -1
  85. package/src/components/Lists/Treegrid.stories.tsx +2 -5
  86. package/src/components/Main/Main.stories.tsx +1 -1
  87. package/src/components/Menus/ContextMenu.stories.tsx +1 -1
  88. package/src/components/Menus/DropdownMenu.stories.tsx +1 -1
  89. package/src/components/Message/Message.stories.tsx +1 -1
  90. package/src/components/Popover/Popover.stories.tsx +1 -1
  91. package/src/components/ScrollArea/ScrollArea.stories.tsx +1 -1
  92. package/src/components/Select/Select.stories.tsx +1 -1
  93. package/src/components/Status/Status.stories.tsx +1 -1
  94. package/src/components/Tag/Tag.stories.tsx +1 -1
  95. package/src/components/Toast/Toast.stories.tsx +1 -1
  96. package/src/components/Toolbar/Toolbar.stories.tsx +1 -1
  97. package/src/components/Tooltip/Tooltip.stories.tsx +1 -1
  98. package/src/components/index.ts +1 -0
  99. package/src/playground/Controls.stories.tsx +1 -1
  100. package/src/playground/Surfaces.stories.tsx +1 -1
  101. package/src/playground/Typography.stories.tsx +1 -1
  102. package/src/playground/helpers.tsx +1 -1
@@ -1,4 +1,4 @@
1
- import '@dxosTheme';
1
+ import '@dxos-theme';
2
2
  import React from 'react';
3
3
  declare const _default: {
4
4
  title: string;
@@ -1 +1 @@
1
- {"version":3,"file":"ContextMenu.stories.d.ts","sourceRoot":"","sources":["../../../../../src/components/Menus/ContextMenu.stories.tsx"],"names":[],"mappings":"AAIA,OAAO,YAAY,CAAC;AAEpB,OAAO,KAAK,MAAM,OAAO,CAAC;;;;;;;;;;;AAuF1B,wBAKE;AAEF,eAAO,MAAM,OAAO;;;;;;;CAKnB,CAAC"}
1
+ {"version":3,"file":"ContextMenu.stories.d.ts","sourceRoot":"","sources":["../../../../../src/components/Menus/ContextMenu.stories.tsx"],"names":[],"mappings":"AAIA,OAAO,aAAa,CAAC;AAErB,OAAO,KAAK,MAAM,OAAO,CAAC;;;;;;;;;;;AAuF1B,wBAKE;AAEF,eAAO,MAAM,OAAO;;;;;;;CAKnB,CAAC"}
@@ -1,4 +1,4 @@
1
- import '@dxosTheme';
1
+ import '@dxos-theme';
2
2
  import React from 'react';
3
3
  declare const _default: {
4
4
  title: string;
@@ -1 +1 @@
1
- {"version":3,"file":"DropdownMenu.stories.d.ts","sourceRoot":"","sources":["../../../../../src/components/Menus/DropdownMenu.stories.tsx"],"names":[],"mappings":"AAIA,OAAO,YAAY,CAAC;AAEpB,OAAO,KAAK,MAAM,OAAO,CAAC;;;;;;;;;;;AAuF1B,wBAKE;AAEF,eAAO,MAAM,OAAO;;;;;;;CAKnB,CAAC"}
1
+ {"version":3,"file":"DropdownMenu.stories.d.ts","sourceRoot":"","sources":["../../../../../src/components/Menus/DropdownMenu.stories.tsx"],"names":[],"mappings":"AAIA,OAAO,aAAa,CAAC;AAErB,OAAO,KAAK,MAAM,OAAO,CAAC;;;;;;;;;;;AAuF1B,wBAKE;AAEF,eAAO,MAAM,OAAO;;;;;;;CAKnB,CAAC"}
@@ -1,4 +1,4 @@
1
- import '@dxosTheme';
1
+ import '@dxos-theme';
2
2
  import React from 'react';
3
3
  import { type MessageValence } from '@dxos/react-ui-types';
4
4
  type StoryMessageProps = {
@@ -1 +1 @@
1
- {"version":3,"file":"Message.stories.d.ts","sourceRoot":"","sources":["../../../../../src/components/Message/Message.stories.tsx"],"names":[],"mappings":"AAIA,OAAO,YAAY,CAAC;AAGpB,OAAO,KAAK,MAAM,OAAO,CAAC;AAE1B,OAAO,EAAE,KAAK,cAAc,EAAE,MAAM,sBAAsB,CAAC;AAK3D,KAAK,iBAAiB,GAAG;IACvB,OAAO,EAAE,cAAc,CAAC;IACxB,KAAK,EAAE,MAAM,CAAC;IACd,IAAI,EAAE,MAAM,CAAC;CACd,CAAC;;;0CAE8C,iBAAiB;;;;;;;;AASjE,wBAKE;AAEF,eAAO,MAAM,OAAO;;;;;;CAMnB,CAAC"}
1
+ {"version":3,"file":"Message.stories.d.ts","sourceRoot":"","sources":["../../../../../src/components/Message/Message.stories.tsx"],"names":[],"mappings":"AAIA,OAAO,aAAa,CAAC;AAGrB,OAAO,KAAK,MAAM,OAAO,CAAC;AAE1B,OAAO,EAAE,KAAK,cAAc,EAAE,MAAM,sBAAsB,CAAC;AAK3D,KAAK,iBAAiB,GAAG;IACvB,OAAO,EAAE,cAAc,CAAC;IACxB,KAAK,EAAE,MAAM,CAAC;IACd,IAAI,EAAE,MAAM,CAAC;CACd,CAAC;;;0CAE8C,iBAAiB;;;;;;;;AASjE,wBAKE;AAEF,eAAO,MAAM,OAAO;;;;;;CAMnB,CAAC"}
@@ -1,4 +1,4 @@
1
- import '@dxosTheme';
1
+ import '@dxos-theme';
2
2
  import React, { type PropsWithChildren, type ReactNode } from 'react';
3
3
  declare const _default: {
4
4
  title: string;
@@ -1 +1 @@
1
- {"version":3,"file":"Popover.stories.d.ts","sourceRoot":"","sources":["../../../../../src/components/Popover/Popover.stories.tsx"],"names":[],"mappings":"AAIA,OAAO,YAAY,CAAC;AAEpB,OAAO,KAAK,EAAE,EAAE,KAAK,iBAAiB,EAAE,KAAK,SAAS,EAAE,MAAM,OAAO,CAAC;;;2CAUjB,iBAAiB,CAAC;QAAE,WAAW,EAAE,SAAS,CAAA;KAAE,CAAC;;;;;;;;AAclG,wBAKE;AAEF,eAAO,MAAM,OAAO;;;;;CAKnB,CAAC"}
1
+ {"version":3,"file":"Popover.stories.d.ts","sourceRoot":"","sources":["../../../../../src/components/Popover/Popover.stories.tsx"],"names":[],"mappings":"AAIA,OAAO,aAAa,CAAC;AAErB,OAAO,KAAK,EAAE,EAAE,KAAK,iBAAiB,EAAE,KAAK,SAAS,EAAE,MAAM,OAAO,CAAC;;;2CAUjB,iBAAiB,CAAC;QAAE,WAAW,EAAE,SAAS,CAAA;KAAE,CAAC;;;;;;;;AAclG,wBAKE;AAEF,eAAO,MAAM,OAAO;;;;;CAKnB,CAAC"}
@@ -1,4 +1,4 @@
1
- import '@dxosTheme';
1
+ import '@dxos-theme';
2
2
  import React, { type PropsWithChildren } from 'react';
3
3
  declare const _default: {
4
4
  title: string;
@@ -1 +1 @@
1
- {"version":3,"file":"ScrollArea.stories.d.ts","sourceRoot":"","sources":["../../../../../src/components/ScrollArea/ScrollArea.stories.tsx"],"names":[],"mappings":"AAIA,OAAO,YAAY,CAAC;AAEpB,OAAO,KAAK,EAAE,EAAE,KAAK,iBAAiB,EAAE,MAAM,OAAO,CAAC;;;8BAUX,iBAAiB,CAAC,EAAE,CAAC;;;;;;;;AAmBhE,wBAKE;AAEF,eAAO,MAAM,OAAO;;;;CAInB,CAAC"}
1
+ {"version":3,"file":"ScrollArea.stories.d.ts","sourceRoot":"","sources":["../../../../../src/components/ScrollArea/ScrollArea.stories.tsx"],"names":[],"mappings":"AAIA,OAAO,aAAa,CAAC;AAErB,OAAO,KAAK,EAAE,EAAE,KAAK,iBAAiB,EAAE,MAAM,OAAO,CAAC;;;8BAUX,iBAAiB,CAAC,EAAE,CAAC;;;;;;;;AAmBhE,wBAKE;AAEF,eAAO,MAAM,OAAO;;;;CAInB,CAAC"}
@@ -1,4 +1,4 @@
1
- import '@dxosTheme';
1
+ import '@dxos-theme';
2
2
  import React from 'react';
3
3
  declare const _default: {
4
4
  title: string;
@@ -1 +1 @@
1
- {"version":3,"file":"Select.stories.d.ts","sourceRoot":"","sources":["../../../../../src/components/Select/Select.stories.tsx"],"names":[],"mappings":"AAIA,OAAO,YAAY,CAAC;AAEpB,OAAO,KAAoD,MAAM,OAAO,CAAC;;;;;;;;;;;;;AAsDzE,wBAKE;AAEF,eAAO,MAAM,OAAO;;;;;;;CAInB,CAAC"}
1
+ {"version":3,"file":"Select.stories.d.ts","sourceRoot":"","sources":["../../../../../src/components/Select/Select.stories.tsx"],"names":[],"mappings":"AAIA,OAAO,aAAa,CAAC;AAErB,OAAO,KAAoD,MAAM,OAAO,CAAC;;;;;;;;;;;;;AAsDzE,wBAKE;AAEF,eAAO,MAAM,OAAO;;;;;;;CAInB,CAAC"}
@@ -1,4 +1,4 @@
1
- import '@dxosTheme';
1
+ import '@dxos-theme';
2
2
  import React from 'react';
3
3
  declare const _default: {
4
4
  title: string;
@@ -1 +1 @@
1
- {"version":3,"file":"Status.stories.d.ts","sourceRoot":"","sources":["../../../../../src/components/Status/Status.stories.tsx"],"names":[],"mappings":"AAIA,OAAO,YAAY,CAAC;AAEpB,OAAO,KAAK,MAAM,OAAO,CAAC;;;;;;;;;;;;;;AAK1B,wBAME;AAEF,eAAO,MAAM,MAAM,UAAW,GAAG,sBAShC,CAAC;AAEF,eAAO,MAAM,aAAa,UAAW,GAAG,sBAMvC,CAAC"}
1
+ {"version":3,"file":"Status.stories.d.ts","sourceRoot":"","sources":["../../../../../src/components/Status/Status.stories.tsx"],"names":[],"mappings":"AAIA,OAAO,aAAa,CAAC;AAErB,OAAO,KAAK,MAAM,OAAO,CAAC;;;;;;;;;;;;;;AAK1B,wBAME;AAEF,eAAO,MAAM,MAAM,UAAW,GAAG,sBAShC,CAAC;AAEF,eAAO,MAAM,aAAa,UAAW,GAAG,sBAMvC,CAAC"}
@@ -1,4 +1,4 @@
1
- import '@dxosTheme';
1
+ import '@dxos-theme';
2
2
  declare const _default: any;
3
3
  export default _default;
4
4
  export declare const Default: {
@@ -1 +1 @@
1
- {"version":3,"file":"Tag.stories.d.ts","sourceRoot":"","sources":["../../../../../src/components/Tag/Tag.stories.tsx"],"names":[],"mappings":"AAIA,OAAO,YAAY,CAAC;wBAuCf,GAAG;AAlCR,wBAkCS;AAET,eAAO,MAAM,OAAO;;;;;CAAsD,CAAC"}
1
+ {"version":3,"file":"Tag.stories.d.ts","sourceRoot":"","sources":["../../../../../src/components/Tag/Tag.stories.tsx"],"names":[],"mappings":"AAIA,OAAO,aAAa,CAAC;wBAuChB,GAAG;AAlCR,wBAkCS;AAET,eAAO,MAAM,OAAO;;;;;CAAsD,CAAC"}
@@ -1,4 +1,4 @@
1
- import '@dxosTheme';
1
+ import '@dxos-theme';
2
2
  import React, { type ReactNode } from 'react';
3
3
  type ActionTriggerProps = {
4
4
  altText: string;
@@ -1 +1 @@
1
- {"version":3,"file":"Toast.stories.d.ts","sourceRoot":"","sources":["../../../../../src/components/Toast/Toast.stories.tsx"],"names":[],"mappings":"AAIA,OAAO,YAAY,CAAC;AAEpB,OAAO,KAAK,EAAE,EAAE,KAAK,SAAS,EAAY,MAAM,OAAO,CAAC;AAMxD,KAAK,kBAAkB,GAAG;IAAE,OAAO,EAAE,MAAM,CAAC;IAAC,OAAO,EAAE,SAAS,CAAA;CAAE,CAAC;AAElE,KAAK,mBAAmB,GAAG,OAAO,CAAC;IACjC,WAAW,EAAE,MAAM,CAAC;IACpB,KAAK,EAAE,MAAM,CAAC;IACd,WAAW,EAAE,MAAM,CAAC;IACpB,cAAc,EAAE,kBAAkB,EAAE,CAAC;IACrC,YAAY,EAAE,SAAS,CAAC;CACzB,CAAC,CAAC;;;uBAE4B,mBAAmB;;;;;;;;AAwBlD,wBAKE;AAEF,eAAO,MAAM,OAAO;;;;;;;;;;;;;;;;CAWnB,CAAC"}
1
+ {"version":3,"file":"Toast.stories.d.ts","sourceRoot":"","sources":["../../../../../src/components/Toast/Toast.stories.tsx"],"names":[],"mappings":"AAIA,OAAO,aAAa,CAAC;AAErB,OAAO,KAAK,EAAE,EAAE,KAAK,SAAS,EAAY,MAAM,OAAO,CAAC;AAMxD,KAAK,kBAAkB,GAAG;IAAE,OAAO,EAAE,MAAM,CAAC;IAAC,OAAO,EAAE,SAAS,CAAA;CAAE,CAAC;AAElE,KAAK,mBAAmB,GAAG,OAAO,CAAC;IACjC,WAAW,EAAE,MAAM,CAAC;IACpB,KAAK,EAAE,MAAM,CAAC;IACd,WAAW,EAAE,MAAM,CAAC;IACpB,cAAc,EAAE,kBAAkB,EAAE,CAAC;IACrC,YAAY,EAAE,SAAS,CAAC;CACzB,CAAC,CAAC;;;uBAE4B,mBAAmB;;;;;;;;AAwBlD,wBAKE;AAEF,eAAO,MAAM,OAAO;;;;;;;;;;;;;;;;CAWnB,CAAC"}
@@ -1,4 +1,4 @@
1
- import '@dxosTheme';
1
+ import '@dxos-theme';
2
2
  import React from 'react';
3
3
  type StorybookToolbarProps = {};
4
4
  declare const _default: {
@@ -1 +1 @@
1
- {"version":3,"file":"Toolbar.stories.d.ts","sourceRoot":"","sources":["../../../../../src/components/Toolbar/Toolbar.stories.tsx"],"names":[],"mappings":"AAIA,OAAO,YAAY,CAAC;AAGpB,OAAO,KAAK,MAAM,OAAO,CAAC;AAO1B,KAAK,qBAAqB,GAAG,EAAE,CAAC;;;uBAEC,qBAAqB;;;;;;;;AAuDtD,wBAKE;AAEF,eAAO,MAAM,OAAO;;CAEnB,CAAC"}
1
+ {"version":3,"file":"Toolbar.stories.d.ts","sourceRoot":"","sources":["../../../../../src/components/Toolbar/Toolbar.stories.tsx"],"names":[],"mappings":"AAIA,OAAO,aAAa,CAAC;AAGrB,OAAO,KAAK,MAAM,OAAO,CAAC;AAO1B,KAAK,qBAAqB,GAAG,EAAE,CAAC;;;uBAEC,qBAAqB;;;;;;;;AAuDtD,wBAKE;AAEF,eAAO,MAAM,OAAO;;CAEnB,CAAC"}
@@ -1,4 +1,4 @@
1
- import '@dxosTheme';
1
+ import '@dxos-theme';
2
2
  import React from 'react';
3
3
  type StoryTooltipProps = {
4
4
  content: string;
@@ -1 +1 @@
1
- {"version":3,"file":"Tooltip.stories.d.ts","sourceRoot":"","sources":["../../../../../src/components/Tooltip/Tooltip.stories.tsx"],"names":[],"mappings":"AAIA,OAAO,YAAY,CAAC;AAEpB,OAAO,KAAK,MAAM,OAAO,CAAC;AAM1B,KAAK,iBAAiB,GAAG;IACvB,OAAO,EAAE,MAAM,CAAC;CACjB,CAAC;;;6BAEiC,iBAAiB;;;;;;;;AAcpD,wBAKE;AAEF,eAAO,MAAM,OAAO;;;;;;;;;CAOnB,CAAC"}
1
+ {"version":3,"file":"Tooltip.stories.d.ts","sourceRoot":"","sources":["../../../../../src/components/Tooltip/Tooltip.stories.tsx"],"names":[],"mappings":"AAIA,OAAO,aAAa,CAAC;AAErB,OAAO,KAAK,MAAM,OAAO,CAAC;AAM1B,KAAK,iBAAiB,GAAG;IACvB,OAAO,EAAE,MAAM,CAAC;CACjB,CAAC;;;6BAEiC,iBAAiB;;;;;;;;AAcpD,wBAKE;AAEF,eAAO,MAAM,OAAO;;;;;;;;;CAOnB,CAAC"}
@@ -4,6 +4,7 @@ export * from './Breadcrumb';
4
4
  export * from './Buttons';
5
5
  export * from './Dialogs';
6
6
  export * from './Menus';
7
+ export * from './Icon';
7
8
  export * from './Input';
8
9
  export * from './Link';
9
10
  export * from './Lists';
@@ -1 +1 @@
1
- {"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../../../../src/components/index.ts"],"names":[],"mappings":"AAIA,cAAc,oBAAoB,CAAC;AACnC,cAAc,WAAW,CAAC;AAC1B,cAAc,cAAc,CAAC;AAC7B,cAAc,WAAW,CAAC;AAC1B,cAAc,WAAW,CAAC;AAC1B,cAAc,SAAS,CAAC;AACxB,cAAc,SAAS,CAAC;AACxB,cAAc,QAAQ,CAAC;AACvB,cAAc,SAAS,CAAC;AACxB,cAAc,QAAQ,CAAC;AACvB,cAAc,WAAW,CAAC;AAC1B,cAAc,WAAW,CAAC;AAC1B,cAAc,UAAU,CAAC;AACzB,cAAc,cAAc,CAAC;AAC7B,cAAc,UAAU,CAAC;AACzB,cAAc,aAAa,CAAC;AAC5B,cAAc,OAAO,CAAC;AACtB,cAAc,SAAS,CAAC;AACxB,cAAc,WAAW,CAAC;AAC1B,cAAc,WAAW,CAAC;AAE1B,cAAc,mBAAmB,CAAC;AAClC,cAAc,qBAAqB,CAAC;AACpC,cAAc,iBAAiB,CAAC"}
1
+ {"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../../../../src/components/index.ts"],"names":[],"mappings":"AAIA,cAAc,oBAAoB,CAAC;AACnC,cAAc,WAAW,CAAC;AAC1B,cAAc,cAAc,CAAC;AAC7B,cAAc,WAAW,CAAC;AAC1B,cAAc,WAAW,CAAC;AAC1B,cAAc,SAAS,CAAC;AACxB,cAAc,QAAQ,CAAC;AACvB,cAAc,SAAS,CAAC;AACxB,cAAc,QAAQ,CAAC;AACvB,cAAc,SAAS,CAAC;AACxB,cAAc,QAAQ,CAAC;AACvB,cAAc,WAAW,CAAC;AAC1B,cAAc,WAAW,CAAC;AAC1B,cAAc,UAAU,CAAC;AACzB,cAAc,cAAc,CAAC;AAC7B,cAAc,UAAU,CAAC;AACzB,cAAc,aAAa,CAAC;AAC5B,cAAc,OAAO,CAAC;AACtB,cAAc,SAAS,CAAC;AACxB,cAAc,WAAW,CAAC;AAC1B,cAAc,WAAW,CAAC;AAE1B,cAAc,mBAAmB,CAAC;AAClC,cAAc,qBAAqB,CAAC;AACpC,cAAc,iBAAiB,CAAC"}
@@ -1,4 +1,4 @@
1
- import '@dxosTheme';
1
+ import '@dxos-theme';
2
2
  import React from 'react';
3
3
  declare const _default: {
4
4
  title: string;
@@ -1 +1 @@
1
- {"version":3,"file":"Controls.stories.d.ts","sourceRoot":"","sources":["../../../../src/playground/Controls.stories.tsx"],"names":[],"mappings":"AAIA,OAAO,YAAY,CAAC;AAGpB,OAAO,KAAmB,MAAM,OAAO,CAAC;;;;;;;;;;;AA6ExC,wBAKE;AAEF,eAAO,MAAM,OAAO;;;;CAEnB,CAAC"}
1
+ {"version":3,"file":"Controls.stories.d.ts","sourceRoot":"","sources":["../../../../src/playground/Controls.stories.tsx"],"names":[],"mappings":"AAIA,OAAO,aAAa,CAAC;AAGrB,OAAO,KAAmB,MAAM,OAAO,CAAC;;;;;;;;;;;AA6ExC,wBAKE;AAEF,eAAO,MAAM,OAAO;;;;CAEnB,CAAC"}
@@ -1,4 +1,4 @@
1
- import '@dxosTheme';
1
+ import '@dxos-theme';
2
2
  import React from 'react';
3
3
  declare const _default: {
4
4
  title: string;
@@ -1 +1 @@
1
- {"version":3,"file":"Surfaces.stories.d.ts","sourceRoot":"","sources":["../../../../src/playground/Surfaces.stories.tsx"],"names":[],"mappings":"AAIA,OAAO,YAAY,CAAC;AAEpB,OAAO,KAAiC,MAAM,OAAO,CAAC;;;;;;;;;;;AAwDtD,wBAKE;AAEF,eAAO,MAAM,OAAO;;CAEnB,CAAC"}
1
+ {"version":3,"file":"Surfaces.stories.d.ts","sourceRoot":"","sources":["../../../../src/playground/Surfaces.stories.tsx"],"names":[],"mappings":"AAIA,OAAO,aAAa,CAAC;AAErB,OAAO,KAAiC,MAAM,OAAO,CAAC;;;;;;;;;;;AAwDtD,wBAKE;AAEF,eAAO,MAAM,OAAO;;CAEnB,CAAC"}
@@ -1,4 +1,4 @@
1
- import '@dxosTheme';
1
+ import '@dxos-theme';
2
2
  import React from 'react';
3
3
  declare const _default: {
4
4
  title: string;
@@ -1 +1 @@
1
- {"version":3,"file":"Typography.stories.d.ts","sourceRoot":"","sources":["../../../../src/playground/Typography.stories.tsx"],"names":[],"mappings":"AAIA,OAAO,YAAY,CAAC;AAEpB,OAAO,KAAK,MAAM,OAAO,CAAC;;;;;;;;;;;AAuC1B,wBAKE;AAEF,eAAO,MAAM,OAAO;;CAEnB,CAAC"}
1
+ {"version":3,"file":"Typography.stories.d.ts","sourceRoot":"","sources":["../../../../src/playground/Typography.stories.tsx"],"names":[],"mappings":"AAIA,OAAO,aAAa,CAAC;AAErB,OAAO,KAAK,MAAM,OAAO,CAAC;;;;;;;;;;;AAuC1B,wBAKE;AAEF,eAAO,MAAM,OAAO;;CAEnB,CAAC"}
@@ -1,4 +1,4 @@
1
- import '@dxosTheme';
1
+ import '@dxos-theme';
2
2
  import React, { type FunctionComponent } from 'react';
3
3
  export declare const createScenarios: (Component: FunctionComponent<any>) => ({ ...props }: {
4
4
  [x: string]: any;
@@ -1 +1 @@
1
- {"version":3,"file":"helpers.d.ts","sourceRoot":"","sources":["../../../../src/playground/helpers.tsx"],"names":[],"mappings":"AAIA,OAAO,YAAY,CAAC;AAEpB,OAAO,KAAK,EAAE,EAAE,KAAK,iBAAiB,EAAE,MAAM,OAAO,CAAC;AAOtD,eAAO,MAAM,eAAe,cACd,iBAAiB,CAAC,GAAG,CAAC;;uBAiBjC,CAAC"}
1
+ {"version":3,"file":"helpers.d.ts","sourceRoot":"","sources":["../../../../src/playground/helpers.tsx"],"names":[],"mappings":"AAIA,OAAO,aAAa,CAAC;AAErB,OAAO,KAAK,EAAE,EAAE,KAAK,iBAAiB,EAAE,MAAM,OAAO,CAAC;AAOtD,eAAO,MAAM,eAAe,cACd,iBAAiB,CAAC,GAAG,CAAC;;uBAiBjC,CAAC"}
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@dxos/react-ui",
3
- "version": "0.6.9",
3
+ "version": "0.6.10-main.3cfcc89",
4
4
  "description": "Low-level React components for DXOS, applying a theme to a core group of primitives",
5
5
  "homepage": "https://dxos.org",
6
6
  "bugs": "https://github.com/dxos/dxos/issues",
@@ -49,11 +49,12 @@
49
49
  "i18next": "^21.10.0",
50
50
  "keyborg": "^2.5.0",
51
51
  "react-i18next": "^11.18.6",
52
- "@dxos/react-input": "0.6.9",
53
- "@dxos/log": "0.6.9",
54
- "@dxos/react-hooks": "0.6.9",
55
- "@dxos/react-list": "0.6.9",
56
- "@dxos/react-ui-types": "0.6.9"
52
+ "@dxos/log": "0.6.10-main.3cfcc89",
53
+ "@dxos/react-hooks": "0.6.10-main.3cfcc89",
54
+ "@dxos/react-input": "0.6.10-main.3cfcc89",
55
+ "@dxos/react-ui-types": "0.6.10-main.3cfcc89",
56
+ "@dxos/react-list": "0.6.10-main.3cfcc89",
57
+ "@dxos/util": "0.6.10-main.3cfcc89"
57
58
  },
58
59
  "devDependencies": {
59
60
  "@dnd-kit/core": "^6.0.5",
@@ -65,9 +66,9 @@
65
66
  "react": "~18.2.0",
66
67
  "react-dom": "~18.2.0",
67
68
  "vite": "^5.3.4",
68
- "@dxos/random": "0.6.9",
69
- "@dxos/react-ui-theme": "0.6.9",
70
- "@dxos/util": "0.6.9"
69
+ "@dxos/random": "0.6.10-main.3cfcc89",
70
+ "@dxos/util": "0.6.10-main.3cfcc89",
71
+ "@dxos/react-ui-theme": "0.6.10-main.3cfcc89"
71
72
  },
72
73
  "peerDependencies": {
73
74
  "@phosphor-icons/react": "^2.1.5",
@@ -2,7 +2,7 @@
2
2
  // Copyright 2022 DXOS.org
3
3
  //
4
4
 
5
- import '@dxosTheme';
5
+ import '@dxos-theme';
6
6
 
7
7
  import React, { type PropsWithChildren } from 'react';
8
8
 
@@ -18,6 +18,7 @@ import { type Size } from '@dxos/react-ui-types';
18
18
 
19
19
  import { useThemeContext } from '../../hooks';
20
20
  import { type ThemedClassName } from '../../util';
21
+ import { Icon } from '../Icon';
21
22
 
22
23
  type AvatarVariant = 'square' | 'circle';
23
24
  type AvatarStatus = 'active' | 'inactive' | 'current' | 'error' | 'warning' | 'internal';
@@ -261,6 +262,24 @@ const AvatarImage = forwardRef<SVGImageElement, AvatarImageProps>(
261
262
  },
262
263
  );
263
264
 
265
+ type AvatarIconProps = {
266
+ icon: string;
267
+ onLoadingStatusChange?: (status: ImageLoadingStatus) => void;
268
+ };
269
+
270
+ const AvatarIcon = forwardRef<SVGSVGElement, AvatarIconProps>(({ onLoadingStatusChange, ...props }, forwardedRef) => {
271
+ const { size } = useAvatarContext('AvatarIcon');
272
+ const pxSize = size === 'px' ? 1 : size * 4;
273
+ if (pxSize <= 20) {
274
+ return null;
275
+ }
276
+ return (
277
+ <AvatarFallbackPrimitive asChild>
278
+ <Icon {...props} ref={forwardedRef} />
279
+ </AvatarFallbackPrimitive>
280
+ );
281
+ });
282
+
264
283
  type AvatarFallbackProps = ComponentPropsWithRef<'image'> & {
265
284
  delayMs?: number;
266
285
  text?: string;
@@ -284,6 +303,7 @@ export const Avatar = {
284
303
  Root: AvatarRoot,
285
304
  Frame: AvatarFrame,
286
305
  Image: AvatarImage,
306
+ Icon: AvatarIcon,
287
307
  Fallback: AvatarFallback,
288
308
  Label: AvatarLabel,
289
309
  Description: AvatarDescription,
@@ -2,7 +2,7 @@
2
2
  // Copyright 2023 DXOS.org
3
3
  //
4
4
 
5
- import '@dxosTheme';
5
+ import '@dxos-theme';
6
6
 
7
7
  import React from 'react';
8
8
 
@@ -2,7 +2,7 @@
2
2
  // Copyright 2023 DXOS.org
3
3
  //
4
4
 
5
- import '@dxosTheme';
5
+ import '@dxos-theme';
6
6
 
7
7
  import React from 'react';
8
8
 
@@ -16,7 +16,7 @@ const StorybookBreadcrumb = () => {
16
16
  <Breadcrumb.List>
17
17
  <Breadcrumb.ListItem>
18
18
  <Breadcrumb.Link asChild>
19
- <Button variant='ghost' density='fine' classNames='pli-0 text-base font-normal'>
19
+ <Button variant='ghost' density='fine' classNames='pli-0 text-baseText font-normal'>
20
20
  Grocery
21
21
  </Button>
22
22
  </Breadcrumb.Link>
@@ -2,7 +2,7 @@
2
2
  // Copyright 2022 DXOS.org
3
3
  //
4
4
 
5
- import '@dxosTheme';
5
+ import '@dxos-theme';
6
6
 
7
7
  import { CaretLeft, CaretRight } from '@phosphor-icons/react';
8
8
  import React, { type PropsWithChildren } from 'react';
@@ -2,7 +2,7 @@
2
2
  // Copyright 2023 DXOS.org
3
3
  //
4
4
 
5
- import '@dxosTheme';
5
+ import '@dxos-theme';
6
6
 
7
7
  import { TextB } from '@phosphor-icons/react';
8
8
  import React from 'react';
@@ -2,7 +2,7 @@
2
2
  // Copyright 2023 DXOS.org
3
3
  //
4
4
 
5
- import '@dxosTheme';
5
+ import '@dxos-theme';
6
6
 
7
7
  import { TextB, TextItalic } from '@phosphor-icons/react';
8
8
  import React from 'react';
@@ -2,7 +2,7 @@
2
2
  // Copyright 2022 DXOS.org
3
3
  //
4
4
 
5
- import '@dxosTheme';
5
+ import '@dxos-theme';
6
6
 
7
7
  import React from 'react';
8
8
 
@@ -2,7 +2,7 @@
2
2
  // Copyright 2022 DXOS.org
3
3
  //
4
4
 
5
- import '@dxosTheme';
5
+ import '@dxos-theme';
6
6
 
7
7
  import React from 'react';
8
8
 
@@ -0,0 +1,22 @@
1
+ //
2
+ // Copyright 2024 DXOS.org
3
+ //
4
+
5
+ import { type Primitive } from '@radix-ui/react-primitive';
6
+ import React, { type ComponentPropsWithRef, forwardRef } from 'react';
7
+
8
+ import { type Size } from '@dxos/react-ui-types';
9
+
10
+ import { useThemeContext } from '../../hooks';
11
+ import { type ThemedClassName } from '../../util';
12
+
13
+ export type IconProps = ThemedClassName<ComponentPropsWithRef<typeof Primitive.svg>> & { icon: string; size?: Size };
14
+
15
+ export const Icon = forwardRef<SVGSVGElement, IconProps>(({ icon, classNames, size, ...props }, forwardedRef) => {
16
+ const { tx } = useThemeContext();
17
+ return (
18
+ <svg {...props} className={tx('icon.root', 'icon', { size }, classNames)} ref={forwardedRef}>
19
+ <use href={`/icons.svg#${icon}`} />
20
+ </svg>
21
+ );
22
+ });
@@ -0,0 +1,5 @@
1
+ //
2
+ // Copyright 2022 DXOS.org
3
+ //
4
+
5
+ export * from './Icon';
@@ -2,7 +2,7 @@
2
2
  // Copyright 2022 DXOS.org
3
3
  //
4
4
 
5
- import '@dxosTheme';
5
+ import '@dxos-theme';
6
6
 
7
7
  import React from 'react';
8
8
 
@@ -2,7 +2,7 @@
2
2
  // Copyright 2022 DXOS.org
3
3
  //
4
4
 
5
- import '@dxosTheme';
5
+ import '@dxos-theme';
6
6
 
7
7
  import { Link } from './Link';
8
8
  import { withTheme } from '../../testing';
@@ -2,7 +2,7 @@
2
2
  // Copyright 2022 DXOS.org
3
3
  //
4
4
 
5
- import '@dxosTheme';
5
+ import '@dxos-theme';
6
6
 
7
7
  import { DndContext, type DragEndEvent, type DragStartEvent } from '@dnd-kit/core';
8
8
  import { arrayMove, SortableContext, useSortable, verticalListSortingStrategy } from '@dnd-kit/sortable';
@@ -2,7 +2,7 @@
2
2
  // Copyright 2023 DXOS.org
3
3
  //
4
4
 
5
- import '@dxosTheme';
5
+ import '@dxos-theme';
6
6
 
7
7
  import React from 'react';
8
8
 
@@ -7,6 +7,7 @@ import { faker } from '@dxos/random';
7
7
 
8
8
  import { Treegrid as Tg } from './Treegrid';
9
9
  import { withTheme } from '../../testing';
10
+ import { Icon } from '../Icon';
10
11
 
11
12
  faker.seed(1234);
12
13
 
@@ -129,11 +130,7 @@ const StorybookTreegrid = () => {
129
130
  {...(parentOf && { parentOf: parentOf.join(Tg.PARENT_OF_SEPARATOR) })}
130
131
  >
131
132
  <Tg.Cell indent classNames='flex items-center'>
132
- {node.icon && (
133
- <svg className='is-[1em] bs-[1em] mlb-1'>
134
- <use href={`/icons.svg#${node.icon}`} />
135
- </svg>
136
- )}
133
+ {node.icon && <Icon icon={node.icon} classNames='is-[1em] bs-[1em] mlb-1' />}
137
134
  {node.title}
138
135
  </Tg.Cell>
139
136
  </Tg.Row>
@@ -2,7 +2,7 @@
2
2
  // Copyright 2023 DXOS.org
3
3
  //
4
4
 
5
- import '@dxosTheme';
5
+ import '@dxos-theme';
6
6
 
7
7
  import React from 'react';
8
8
 
@@ -2,7 +2,7 @@
2
2
  // Copyright 2022 DXOS.org
3
3
  //
4
4
 
5
- import '@dxosTheme';
5
+ import '@dxos-theme';
6
6
 
7
7
  import React from 'react';
8
8
 
@@ -2,7 +2,7 @@
2
2
  // Copyright 2022 DXOS.org
3
3
  //
4
4
 
5
- import '@dxosTheme';
5
+ import '@dxos-theme';
6
6
 
7
7
  import React from 'react';
8
8
 
@@ -2,7 +2,7 @@
2
2
  // Copyright 2022 DXOS.org
3
3
  //
4
4
 
5
- import '@dxosTheme';
5
+ import '@dxos-theme';
6
6
 
7
7
  import { Info } from '@phosphor-icons/react';
8
8
  import React from 'react';
@@ -2,7 +2,7 @@
2
2
  // Copyright 2022 DXOS.org
3
3
  //
4
4
 
5
- import '@dxosTheme';
5
+ import '@dxos-theme';
6
6
 
7
7
  import React, { type PropsWithChildren, type ReactNode } from 'react';
8
8
 
@@ -2,7 +2,7 @@
2
2
  // Copyright 2023 DXOS.org
3
3
  //
4
4
 
5
- import '@dxosTheme';
5
+ import '@dxos-theme';
6
6
 
7
7
  import React, { type PropsWithChildren } from 'react';
8
8
 
@@ -2,7 +2,7 @@
2
2
  // Copyright 2023 DXOS.org
3
3
  //
4
4
 
5
- import '@dxosTheme';
5
+ import '@dxos-theme';
6
6
 
7
7
  import React, { type FC, type PropsWithChildren, useState } from 'react';
8
8
 
@@ -2,7 +2,7 @@
2
2
  // Copyright 2023 DXOS.org
3
3
  //
4
4
 
5
- import '@dxosTheme';
5
+ import '@dxos-theme';
6
6
 
7
7
  import React from 'react';
8
8
 
@@ -2,7 +2,7 @@
2
2
  // Copyright 2022 DXOS.org
3
3
  //
4
4
 
5
- import '@dxosTheme';
5
+ import '@dxos-theme';
6
6
 
7
7
  import { Tag } from './Tag';
8
8
  import { withTheme } from '../../testing';
@@ -2,7 +2,7 @@
2
2
  // Copyright 2022 DXOS.org
3
3
  //
4
4
 
5
- import '@dxosTheme';
5
+ import '@dxos-theme';
6
6
 
7
7
  import React, { type ReactNode, useState } from 'react';
8
8
 
@@ -2,7 +2,7 @@
2
2
  // Copyright 2023 DXOS.org
3
3
  //
4
4
 
5
- import '@dxosTheme';
5
+ import '@dxos-theme';
6
6
 
7
7
  import { ArrowClockwise, Bug, FileJs, FileTs, TextB, TextItalic, TextUnderline } from '@phosphor-icons/react';
8
8
  import React from 'react';
@@ -2,7 +2,7 @@
2
2
  // Copyright 2022 DXOS.org
3
3
  //
4
4
 
5
- import '@dxosTheme';
5
+ import '@dxos-theme';
6
6
 
7
7
  import React from 'react';
8
8
 
@@ -8,6 +8,7 @@ export * from './Breadcrumb';
8
8
  export * from './Buttons';
9
9
  export * from './Dialogs';
10
10
  export * from './Menus';
11
+ export * from './Icon';
11
12
  export * from './Input';
12
13
  export * from './Link';
13
14
  export * from './Lists';
@@ -2,7 +2,7 @@
2
2
  // Copyright 2022 DXOS.org
3
3
  //
4
4
 
5
- import '@dxosTheme';
5
+ import '@dxos-theme';
6
6
 
7
7
  import { FileTs, FileJs, ArrowClockwise, Bug, TextUnderline, TextB, TextItalic } from '@phosphor-icons/react';
8
8
  import React, { useState } from 'react';
@@ -2,7 +2,7 @@
2
2
  // Copyright 2023 DXOS.org
3
3
  //
4
4
 
5
- import '@dxosTheme';
5
+ import '@dxos-theme';
6
6
 
7
7
  import React, { type PropsWithChildren } from 'react';
8
8