@dxos/shell 0.8.0 → 0.8.1-main.303c73a
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/bundle/shell.js +2708 -2706
- package/dist/bundle/shell.js.map +1 -1
- package/dist/bundle/shell.umd.cjs +59 -59
- package/dist/bundle/shell.umd.cjs.map +1 -1
- package/dist/types/src/components/AgentConfig.d.ts +2 -1
- package/dist/types/src/components/AgentConfig.d.ts.map +1 -1
- package/dist/types/src/components/AgentConfig.js +38 -15
- package/dist/types/src/components/AgentConfig.js.map +1 -1
- package/dist/types/src/components/AuthCode.d.ts +2 -2
- package/dist/types/src/components/AuthCode.d.ts.map +1 -1
- package/dist/types/src/components/AuthCode.js +4 -3
- package/dist/types/src/components/AuthCode.js.map +1 -1
- package/dist/types/src/components/CompoundButton/CompoundButton.d.ts +2 -2
- package/dist/types/src/components/CompoundButton/CompoundButton.d.ts.map +1 -1
- package/dist/types/src/components/CompoundButton/CompoundButton.js +10 -2
- package/dist/types/src/components/CompoundButton/CompoundButton.js.map +1 -1
- package/dist/types/src/components/CompoundButton/CompoundButton.stories.d.ts +8 -7
- package/dist/types/src/components/CompoundButton/CompoundButton.stories.d.ts.map +1 -1
- package/dist/types/src/components/CompoundButton/CompoundButton.stories.js +9 -7
- package/dist/types/src/components/CompoundButton/CompoundButton.stories.js.map +1 -1
- package/dist/types/src/components/DeviceList/DeviceList.d.ts +2 -1
- package/dist/types/src/components/DeviceList/DeviceList.d.ts.map +1 -1
- package/dist/types/src/components/DeviceList/DeviceList.js +11 -4
- package/dist/types/src/components/DeviceList/DeviceList.js.map +1 -1
- package/dist/types/src/components/DeviceList/DeviceListItem.js +23 -4
- package/dist/types/src/components/DeviceList/DeviceListItem.js.map +1 -1
- package/dist/types/src/components/IdentityList/IdentityListItem.js +6 -3
- package/dist/types/src/components/IdentityList/IdentityListItem.js.map +1 -1
- package/dist/types/src/components/IdentityList/SpaceMemberList.d.ts +3 -2
- package/dist/types/src/components/IdentityList/SpaceMemberList.d.ts.map +1 -1
- package/dist/types/src/components/IdentityList/SpaceMemberList.js +6 -6
- package/dist/types/src/components/IdentityList/SpaceMemberList.js.map +1 -1
- package/dist/types/src/components/IdentityList/SpaceMemberList.stories.d.ts +3 -2
- package/dist/types/src/components/IdentityList/SpaceMemberList.stories.d.ts.map +1 -1
- package/dist/types/src/components/IdentityList/SpaceMemberList.stories.js +2 -2
- package/dist/types/src/components/IdentityList/SpaceMemberList.stories.js.map +1 -1
- package/dist/types/src/components/InvitationList/InvitationList.d.ts +2 -2
- package/dist/types/src/components/InvitationList/InvitationList.d.ts.map +1 -1
- package/dist/types/src/components/InvitationList/InvitationList.js +8 -5
- package/dist/types/src/components/InvitationList/InvitationList.js.map +1 -1
- package/dist/types/src/components/InvitationList/InvitationList.stories.d.ts +3 -2
- package/dist/types/src/components/InvitationList/InvitationList.stories.d.ts.map +1 -1
- package/dist/types/src/components/InvitationList/InvitationList.stories.js +2 -2
- package/dist/types/src/components/InvitationList/InvitationList.stories.js.map +1 -1
- package/dist/types/src/components/InvitationList/InvitationListContainer.d.ts +2 -1
- package/dist/types/src/components/InvitationList/InvitationListContainer.d.ts.map +1 -1
- package/dist/types/src/components/InvitationList/InvitationListContainer.js +2 -3
- package/dist/types/src/components/InvitationList/InvitationListContainer.js.map +1 -1
- package/dist/types/src/components/InvitationList/InvitationListItem.d.ts +3 -3
- package/dist/types/src/components/InvitationList/InvitationListItem.d.ts.map +1 -1
- package/dist/types/src/components/InvitationList/InvitationListItem.js +34 -5
- package/dist/types/src/components/InvitationList/InvitationListItem.js.map +1 -1
- package/dist/types/src/components/Panel/Action.js +23 -6
- package/dist/types/src/components/Panel/Action.js.map +1 -1
- package/dist/types/src/components/Panel/Actions.js +2 -3
- package/dist/types/src/components/Panel/Actions.js.map +1 -1
- package/dist/types/src/components/Panel/CloseButton.d.ts +2 -1
- package/dist/types/src/components/Panel/CloseButton.d.ts.map +1 -1
- package/dist/types/src/components/Panel/CloseButton.js +4 -2
- package/dist/types/src/components/Panel/CloseButton.js.map +1 -1
- package/dist/types/src/components/Panel/Emoji.d.ts +3 -3
- package/dist/types/src/components/Panel/Emoji.d.ts.map +1 -1
- package/dist/types/src/components/Panel/Emoji.js +8 -3
- package/dist/types/src/components/Panel/Emoji.js.map +1 -1
- package/dist/types/src/components/Panel/Heading.js +6 -3
- package/dist/types/src/components/Panel/Heading.js.map +1 -1
- package/dist/types/src/components/Panel/Input.d.ts +2 -2
- package/dist/types/src/components/Panel/Input.d.ts.map +1 -1
- package/dist/types/src/components/Panel/Input.js +8 -2
- package/dist/types/src/components/Panel/Input.js.map +1 -1
- package/dist/types/src/components/Panel/Label.d.ts +2 -2
- package/dist/types/src/components/Panel/Label.d.ts.map +1 -1
- package/dist/types/src/components/Panel/Label.js +5 -2
- package/dist/types/src/components/Panel/Label.js.map +1 -1
- package/dist/types/src/components/Panel/Panel.stories.d.ts +4 -3
- package/dist/types/src/components/Panel/Panel.stories.d.ts.map +1 -1
- package/dist/types/src/components/Panel/Panel.stories.js +15 -3
- package/dist/types/src/components/Panel/Panel.stories.js.map +1 -1
- package/dist/types/src/components/Panel/StepHeading.js +2 -3
- package/dist/types/src/components/Panel/StepHeading.js.map +1 -1
- package/dist/types/src/components/SpaceListItem.js +6 -3
- package/dist/types/src/components/SpaceListItem.js.map +1 -1
- package/dist/types/src/components/StorybookDialog.d.ts +2 -2
- package/dist/types/src/components/StorybookDialog.d.ts.map +1 -1
- package/dist/types/src/components/StorybookDialog.js +8 -2
- package/dist/types/src/components/StorybookDialog.js.map +1 -1
- package/dist/types/src/components/Viewport/Viewport.d.ts +2 -2
- package/dist/types/src/components/Viewport/Viewport.js +5 -5
- package/dist/types/src/components/Viewport/Viewport.js.map +1 -1
- package/dist/types/src/components/Viewport/Viewport.stories.d.ts +2 -1
- package/dist/types/src/components/Viewport/Viewport.stories.d.ts.map +1 -1
- package/dist/types/src/components/Viewport/Viewport.stories.js +22 -3
- package/dist/types/src/components/Viewport/Viewport.stories.js.map +1 -1
- package/dist/types/src/composites/IdentityDialog/IdentityDialog.d.ts +2 -1
- package/dist/types/src/composites/IdentityDialog/IdentityDialog.d.ts.map +1 -1
- package/dist/types/src/composites/IdentityDialog/IdentityDialog.js +11 -3
- package/dist/types/src/composites/IdentityDialog/IdentityDialog.js.map +1 -1
- package/dist/types/src/composites/JoinDialog/JoinDialog.d.ts +2 -1
- package/dist/types/src/composites/JoinDialog/JoinDialog.d.ts.map +1 -1
- package/dist/types/src/composites/JoinDialog/JoinDialog.js +11 -4
- package/dist/types/src/composites/JoinDialog/JoinDialog.js.map +1 -1
- package/dist/types/src/composites/Shell/Shell.d.ts +2 -1
- package/dist/types/src/composites/Shell/Shell.d.ts.map +1 -1
- package/dist/types/src/composites/Shell/Shell.js +6 -7
- package/dist/types/src/composites/Shell/Shell.js.map +1 -1
- package/dist/types/src/composites/Shell/ShellContext.d.ts +2 -2
- package/dist/types/src/composites/Shell/ShellContext.d.ts.map +1 -1
- package/dist/types/src/composites/Shell/ShellContext.js +5 -3
- package/dist/types/src/composites/Shell/ShellContext.js.map +1 -1
- package/dist/types/src/composites/Shell/run-shell.js +17 -5
- package/dist/types/src/composites/Shell/run-shell.js.map +1 -1
- package/dist/types/src/composites/SpaceDialog/SpaceDialog.d.ts +2 -1
- package/dist/types/src/composites/SpaceDialog/SpaceDialog.d.ts.map +1 -1
- package/dist/types/src/composites/SpaceDialog/SpaceDialog.js +11 -3
- package/dist/types/src/composites/SpaceDialog/SpaceDialog.js.map +1 -1
- package/dist/types/src/composites/StatusDialog/StatusDialog.d.ts +2 -1
- package/dist/types/src/composites/StatusDialog/StatusDialog.d.ts.map +1 -1
- package/dist/types/src/composites/StatusDialog/StatusDialog.js +9 -2
- package/dist/types/src/composites/StatusDialog/StatusDialog.js.map +1 -1
- package/dist/types/src/panels/IdentityPanel/IdentityPanel.d.ts +3 -2
- package/dist/types/src/panels/IdentityPanel/IdentityPanel.d.ts.map +1 -1
- package/dist/types/src/panels/IdentityPanel/IdentityPanel.js +56 -14
- package/dist/types/src/panels/IdentityPanel/IdentityPanel.js.map +1 -1
- package/dist/types/src/panels/IdentityPanel/IdentityPanel.stories.d.ts +11 -10
- package/dist/types/src/panels/IdentityPanel/IdentityPanel.stories.d.ts.map +1 -1
- package/dist/types/src/panels/IdentityPanel/IdentityPanel.stories.js +5 -3
- package/dist/types/src/panels/IdentityPanel/IdentityPanel.stories.js.map +1 -1
- package/dist/types/src/panels/IdentityPanel/steps/IdentityActionChooser.d.ts +3 -2
- package/dist/types/src/panels/IdentityPanel/steps/IdentityActionChooser.d.ts.map +1 -1
- package/dist/types/src/panels/IdentityPanel/steps/IdentityActionChooser.js +8 -3
- package/dist/types/src/panels/IdentityPanel/steps/IdentityActionChooser.js.map +1 -1
- package/dist/types/src/panels/IdentityPanel/steps/ProfileForm.d.ts +2 -1
- package/dist/types/src/panels/IdentityPanel/steps/ProfileForm.d.ts.map +1 -1
- package/dist/types/src/panels/IdentityPanel/steps/ProfileForm.js +20 -11
- package/dist/types/src/panels/IdentityPanel/steps/ProfileForm.js.map +1 -1
- package/dist/types/src/panels/JoinPanel/JoinHeading.js +5 -4
- package/dist/types/src/panels/JoinPanel/JoinHeading.js.map +1 -1
- package/dist/types/src/panels/JoinPanel/JoinPanel.d.ts +3 -2
- package/dist/types/src/panels/JoinPanel/JoinPanel.d.ts.map +1 -1
- package/dist/types/src/panels/JoinPanel/JoinPanel.js +28 -4
- package/dist/types/src/panels/JoinPanel/JoinPanel.js.map +1 -1
- package/dist/types/src/panels/JoinPanel/JoinPanel.stories.d.ts +15 -14
- package/dist/types/src/panels/JoinPanel/JoinPanel.stories.d.ts.map +1 -1
- package/dist/types/src/panels/JoinPanel/JoinPanel.stories.js +16 -15
- package/dist/types/src/panels/JoinPanel/JoinPanel.stories.js.map +1 -1
- package/dist/types/src/panels/JoinPanel/steps/AdditionMethodChooser.d.ts +2 -1
- package/dist/types/src/panels/JoinPanel/steps/AdditionMethodChooser.d.ts.map +1 -1
- package/dist/types/src/panels/JoinPanel/steps/AdditionMethodChooser.js +8 -3
- package/dist/types/src/panels/JoinPanel/steps/AdditionMethodChooser.js.map +1 -1
- package/dist/types/src/panels/JoinPanel/steps/IdentityAdded.d.ts +2 -1
- package/dist/types/src/panels/JoinPanel/steps/IdentityAdded.d.ts.map +1 -1
- package/dist/types/src/panels/JoinPanel/steps/IdentityAdded.js +11 -4
- package/dist/types/src/panels/JoinPanel/steps/IdentityAdded.js.map +1 -1
- package/dist/types/src/panels/JoinPanel/steps/IdentityInput.d.ts +3 -2
- package/dist/types/src/panels/JoinPanel/steps/IdentityInput.d.ts.map +1 -1
- package/dist/types/src/panels/JoinPanel/steps/IdentityInput.js +7 -4
- package/dist/types/src/panels/JoinPanel/steps/IdentityInput.js.map +1 -1
- package/dist/types/src/panels/JoinPanel/steps/InvitationAccepted.d.ts +2 -2
- package/dist/types/src/panels/JoinPanel/steps/InvitationAccepted.d.ts.map +1 -1
- package/dist/types/src/panels/JoinPanel/steps/InvitationAccepted.js +6 -4
- package/dist/types/src/panels/JoinPanel/steps/InvitationAccepted.js.map +1 -1
- package/dist/types/src/panels/JoinPanel/steps/InvitationAuthenticator.d.ts +2 -1
- package/dist/types/src/panels/JoinPanel/steps/InvitationAuthenticator.d.ts.map +1 -1
- package/dist/types/src/panels/JoinPanel/steps/InvitationAuthenticator.js +28 -14
- package/dist/types/src/panels/JoinPanel/steps/InvitationAuthenticator.js.map +1 -1
- package/dist/types/src/panels/JoinPanel/steps/InvitationInput.d.ts +2 -1
- package/dist/types/src/panels/JoinPanel/steps/InvitationInput.d.ts.map +1 -1
- package/dist/types/src/panels/JoinPanel/steps/InvitationInput.js +14 -10
- package/dist/types/src/panels/JoinPanel/steps/InvitationInput.js.map +1 -1
- package/dist/types/src/panels/JoinPanel/steps/InvitationRescuer.d.ts +2 -1
- package/dist/types/src/panels/JoinPanel/steps/InvitationRescuer.d.ts.map +1 -1
- package/dist/types/src/panels/JoinPanel/steps/InvitationRescuer.js +24 -8
- package/dist/types/src/panels/JoinPanel/steps/InvitationRescuer.js.map +1 -1
- package/dist/types/src/panels/Panels.stories.d.ts +3 -3
- package/dist/types/src/panels/Panels.stories.d.ts.map +1 -1
- package/dist/types/src/panels/Panels.stories.js +8 -3
- package/dist/types/src/panels/Panels.stories.js.map +1 -1
- package/dist/types/src/panels/SpacePanel/SpacePanel.d.ts +3 -2
- package/dist/types/src/panels/SpacePanel/SpacePanel.d.ts.map +1 -1
- package/dist/types/src/panels/SpacePanel/SpacePanel.js +15 -6
- package/dist/types/src/panels/SpacePanel/SpacePanel.js.map +1 -1
- package/dist/types/src/panels/SpacePanel/SpacePanel.stories.d.ts +18 -17
- package/dist/types/src/panels/SpacePanel/SpacePanel.stories.d.ts.map +1 -1
- package/dist/types/src/panels/SpacePanel/SpacePanel.stories.js +38 -30
- package/dist/types/src/panels/SpacePanel/SpacePanel.stories.js.map +1 -1
- package/dist/types/src/panels/SpacePanel/steps/SpaceManager.d.ts +3 -3
- package/dist/types/src/panels/SpacePanel/steps/SpaceManager.d.ts.map +1 -1
- package/dist/types/src/panels/SpacePanel/steps/SpaceManager.js +14 -4
- package/dist/types/src/panels/SpacePanel/steps/SpaceManager.js.map +1 -1
- package/dist/types/src/panels/StatusPanel/StatusPanel.d.ts +2 -1
- package/dist/types/src/panels/StatusPanel/StatusPanel.d.ts.map +1 -1
- package/dist/types/src/panels/StatusPanel/StatusPanel.js +7 -2
- package/dist/types/src/panels/StatusPanel/StatusPanel.js.map +1 -1
- package/dist/types/src/steps/ConfirmReset.d.ts +3 -2
- package/dist/types/src/steps/ConfirmReset.d.ts.map +1 -1
- package/dist/types/src/steps/ConfirmReset.js +19 -10
- package/dist/types/src/steps/ConfirmReset.js.map +1 -1
- package/dist/types/src/steps/InvitationManager.d.ts +2 -1
- package/dist/types/src/steps/InvitationManager.d.ts.map +1 -1
- package/dist/types/src/steps/InvitationManager.js +21 -4
- package/dist/types/src/steps/InvitationManager.js.map +1 -1
- package/dist/types/src/stories/Invitations.e2e-stories.d.ts +2 -1
- package/dist/types/src/stories/Invitations.e2e-stories.d.ts.map +1 -1
- package/dist/types/src/stories/Invitations.e2e-stories.js +40 -13
- package/dist/types/src/stories/Invitations.e2e-stories.js.map +1 -1
- package/package.json +26 -26
|
@@ -1,8 +1,8 @@
|
|
|
1
|
-
import { jsx as _jsx } from "react/jsx-runtime";
|
|
2
1
|
//
|
|
3
2
|
// Copyright 2023 DXOS.org
|
|
4
3
|
//
|
|
5
4
|
import '@dxos-theme';
|
|
5
|
+
import React from 'react';
|
|
6
6
|
import { withTheme } from '@dxos/storybook-utils';
|
|
7
7
|
import { SpaceMemberListImpl } from './SpaceMemberList';
|
|
8
8
|
import { alice } from '../../testing/fixtures';
|
|
@@ -13,6 +13,6 @@ export default {
|
|
|
13
13
|
parameters: { chromatic: { disableSnapshot: false } },
|
|
14
14
|
};
|
|
15
15
|
export const Default = (props) => {
|
|
16
|
-
return
|
|
16
|
+
return React.createElement(SpaceMemberListImpl, { ...props, members: [alice] });
|
|
17
17
|
};
|
|
18
18
|
//# sourceMappingURL=SpaceMemberList.stories.js.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"SpaceMemberList.stories.js","sourceRoot":"","sources":["../../../../../src/components/IdentityList/SpaceMemberList.stories.tsx"],"names":[],"mappings":"
|
|
1
|
+
{"version":3,"file":"SpaceMemberList.stories.js","sourceRoot":"","sources":["../../../../../src/components/IdentityList/SpaceMemberList.stories.tsx"],"names":[],"mappings":"AAAA,EAAE;AACF,0BAA0B;AAC1B,EAAE;AAEF,OAAO,aAAa,CAAC;AAErB,OAAO,KAAK,MAAM,OAAO,CAAC;AAE1B,OAAO,EAAE,SAAS,EAAE,MAAM,uBAAuB,CAAC;AAElD,OAAO,EAAE,mBAAmB,EAAE,MAAM,mBAAmB,CAAC;AACxD,OAAO,EAAE,KAAK,EAAE,MAAM,wBAAwB,CAAC;AAE/C,eAAe;IACb,KAAK,EAAE,2BAA2B;IAClC,SAAS,EAAE,mBAAmB;IAC9B,UAAU,EAAE,CAAC,SAAS,CAAC;IACvB,UAAU,EAAE,EAAE,SAAS,EAAE,EAAE,eAAe,EAAE,KAAK,EAAE,EAAE;CACtD,CAAC;AAEF,MAAM,CAAC,MAAM,OAAO,GAAG,CAAC,KAAU,EAAE,EAAE;IACpC,OAAO,oBAAC,mBAAmB,OAAK,KAAK,EAAE,OAAO,EAAE,CAAC,KAAK,CAAC,GAAI,CAAC;AAC9D,CAAC,CAAC"}
|
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
import { type ComponentType } from 'react';
|
|
1
|
+
import React, { type ComponentType } from 'react';
|
|
2
2
|
import type { CancellableInvitationObservable } from '@dxos/react-client/invitations';
|
|
3
3
|
import { type InvitationListItemProps } from './InvitationListItem';
|
|
4
4
|
import { type SharedInvitationListProps } from './InvitationListProps';
|
|
@@ -7,5 +7,5 @@ export interface InvitationListProps extends Omit<InvitationListItemProps, 'invi
|
|
|
7
7
|
InvitationListItem?: ComponentType<InvitationListItemProps>;
|
|
8
8
|
className?: string;
|
|
9
9
|
}
|
|
10
|
-
export declare const InvitationList: ({ invitations, send, ...invitationProps }: InvitationListProps) =>
|
|
10
|
+
export declare const InvitationList: ({ invitations, send, ...invitationProps }: InvitationListProps) => React.JSX.Element;
|
|
11
11
|
//# sourceMappingURL=InvitationList.d.ts.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"InvitationList.d.ts","sourceRoot":"","sources":["../../../../../src/components/InvitationList/InvitationList.tsx"],"names":[],"mappings":"AAGA,
|
|
1
|
+
{"version":3,"file":"InvitationList.d.ts","sourceRoot":"","sources":["../../../../../src/components/InvitationList/InvitationList.tsx"],"names":[],"mappings":"AAGA,OAAO,KAAK,EAAE,EAAE,KAAK,aAAa,EAAE,MAAM,OAAO,CAAC;AAElD,OAAO,KAAK,EAAE,+BAA+B,EAAE,MAAM,gCAAgC,CAAC;AAItF,OAAO,EAAsB,KAAK,uBAAuB,EAAE,MAAM,sBAAsB,CAAC;AACxF,OAAO,EAAE,KAAK,yBAAyB,EAAE,MAAM,uBAAuB,CAAC;AAEvE,MAAM,WAAW,mBACf,SAAQ,IAAI,CAAC,uBAAuB,EAAE,YAAY,GAAG,OAAO,CAAC,EAC3D,IAAI,CAAC,yBAAyB,EAAE,MAAM,CAAC;IACzC,WAAW,EAAE,+BAA+B,EAAE,CAAC;IAC/C,kBAAkB,CAAC,EAAE,aAAa,CAAC,uBAAuB,CAAC,CAAC;IAC5D,SAAS,CAAC,EAAE,MAAM,CAAC;CACpB;AAED,eAAO,MAAM,cAAc,8CAA+C,mBAAmB,sBAU5F,CAAC"}
|
|
@@ -1,12 +1,15 @@
|
|
|
1
|
-
|
|
1
|
+
//
|
|
2
|
+
// Copyright 2023 DXOS.org
|
|
3
|
+
//
|
|
4
|
+
import React from 'react';
|
|
2
5
|
import { List } from '@dxos/react-ui';
|
|
3
6
|
import { mx } from '@dxos/react-ui-theme';
|
|
4
7
|
import { InvitationListItem } from './InvitationListItem';
|
|
5
8
|
export const InvitationList = ({ invitations, send, ...invitationProps }) => {
|
|
6
9
|
const { className, InvitationListItem: Item = InvitationListItem } = invitationProps;
|
|
7
|
-
return (
|
|
8
|
-
|
|
9
|
-
|
|
10
|
-
|
|
10
|
+
return (React.createElement(List, { classNames: mx('flex flex-col gap-2', className) }, invitations.map((invitation) => {
|
|
11
|
+
const value = invitation.get().invitationId;
|
|
12
|
+
return React.createElement(Item, { key: value, send: send, invitation: invitation, ...invitationProps });
|
|
13
|
+
})));
|
|
11
14
|
};
|
|
12
15
|
//# sourceMappingURL=InvitationList.js.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"InvitationList.js","sourceRoot":"","sources":["../../../../../src/components/InvitationList/InvitationList.tsx"],"names":[],"mappings":";
|
|
1
|
+
{"version":3,"file":"InvitationList.js","sourceRoot":"","sources":["../../../../../src/components/InvitationList/InvitationList.tsx"],"names":[],"mappings":"AAAA,EAAE;AACF,0BAA0B;AAC1B,EAAE;AACF,OAAO,KAA6B,MAAM,OAAO,CAAC;AAGlD,OAAO,EAAE,IAAI,EAAE,MAAM,gBAAgB,CAAC;AACtC,OAAO,EAAE,EAAE,EAAE,MAAM,sBAAsB,CAAC;AAE1C,OAAO,EAAE,kBAAkB,EAAgC,MAAM,sBAAsB,CAAC;AAWxF,MAAM,CAAC,MAAM,cAAc,GAAG,CAAC,EAAE,WAAW,EAAE,IAAI,EAAE,GAAG,eAAe,EAAuB,EAAE,EAAE;IAC/F,MAAM,EAAE,SAAS,EAAE,kBAAkB,EAAE,IAAI,GAAG,kBAAkB,EAAE,GAAG,eAAe,CAAC;IACrF,OAAO,CACL,oBAAC,IAAI,IAAC,UAAU,EAAE,EAAE,CAAC,qBAAqB,EAAE,SAAS,CAAC,IACnD,WAAW,CAAC,GAAG,CAAC,CAAC,UAAU,EAAE,EAAE;QAC9B,MAAM,KAAK,GAAG,UAAU,CAAC,GAAG,EAAE,CAAC,YAAY,CAAC;QAC5C,OAAO,oBAAC,IAAI,IAAC,GAAG,EAAE,KAAK,EAAE,IAAI,EAAE,IAAI,EAAE,UAAU,EAAE,UAAU,KAAM,eAAe,GAAI,CAAC;IACvF,CAAC,CAAC,CACG,CACR,CAAC;AACJ,CAAC,CAAC"}
|
|
@@ -1,7 +1,8 @@
|
|
|
1
1
|
import '@dxos-theme';
|
|
2
|
+
import React from 'react';
|
|
2
3
|
declare const _default: {
|
|
3
4
|
title: string;
|
|
4
|
-
component: ({ invitations, send, ...invitationProps }: import("./InvitationList").InvitationListProps) =>
|
|
5
|
+
component: ({ invitations, send, ...invitationProps }: import("./InvitationList").InvitationListProps) => React.JSX.Element;
|
|
5
6
|
decorators: import("@storybook/react").Decorator[];
|
|
6
7
|
parameters: {
|
|
7
8
|
chromatic: {
|
|
@@ -10,5 +11,5 @@ declare const _default: {
|
|
|
10
11
|
};
|
|
11
12
|
};
|
|
12
13
|
export default _default;
|
|
13
|
-
export declare const Default: () =>
|
|
14
|
+
export declare const Default: () => React.JSX.Element;
|
|
14
15
|
//# sourceMappingURL=InvitationList.stories.d.ts.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"InvitationList.stories.d.ts","sourceRoot":"","sources":["../../../../../src/components/InvitationList/InvitationList.stories.tsx"],"names":[],"mappings":"AAIA,OAAO,aAAa,CAAC;;;;;;;;;;;
|
|
1
|
+
{"version":3,"file":"InvitationList.stories.d.ts","sourceRoot":"","sources":["../../../../../src/components/InvitationList/InvitationList.stories.tsx"],"names":[],"mappings":"AAIA,OAAO,aAAa,CAAC;AAErB,OAAO,KAAK,MAAM,OAAO,CAAC;;;;;;;;;;;AAQ1B,wBAKE;AAEF,eAAO,MAAM,OAAO,yBAkBnB,CAAC"}
|
|
@@ -1,8 +1,8 @@
|
|
|
1
|
-
import { jsx as _jsx } from "react/jsx-runtime";
|
|
2
1
|
//
|
|
3
2
|
// Copyright 2023 DXOS.org
|
|
4
3
|
//
|
|
5
4
|
import '@dxos-theme';
|
|
5
|
+
import React from 'react';
|
|
6
6
|
import { Invitation } from '@dxos/react-client/invitations';
|
|
7
7
|
import { withLayout, withTheme } from '@dxos/storybook-utils';
|
|
8
8
|
import { InvitationList } from './InvitationList';
|
|
@@ -14,7 +14,7 @@ export default {
|
|
|
14
14
|
parameters: { chromatic: { disableSnapshot: false } },
|
|
15
15
|
};
|
|
16
16
|
export const Default = () => {
|
|
17
|
-
return (
|
|
17
|
+
return (React.createElement(InvitationList, { invitations: [
|
|
18
18
|
inviteWithState(Invitation.State.INIT),
|
|
19
19
|
inviteWithState(Invitation.State.CONNECTING),
|
|
20
20
|
inviteWithState(Invitation.State.CONNECTED),
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"InvitationList.stories.js","sourceRoot":"","sources":["../../../../../src/components/InvitationList/InvitationList.stories.tsx"],"names":[],"mappings":"
|
|
1
|
+
{"version":3,"file":"InvitationList.stories.js","sourceRoot":"","sources":["../../../../../src/components/InvitationList/InvitationList.stories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AAC,MAAM,EAAE,EAAE,CAAC,MAAM,GACvC,CACH,CAAC;AACJ,CAAC,CAAC"}
|
|
@@ -1,7 +1,8 @@
|
|
|
1
|
+
import React from 'react';
|
|
1
2
|
import { type PublicKey } from '@dxos/react-client';
|
|
2
3
|
import { type SharedInvitationListProps } from './InvitationListProps';
|
|
3
4
|
export interface InvitationListContainerProps extends SharedInvitationListProps {
|
|
4
5
|
spaceKey: PublicKey;
|
|
5
6
|
}
|
|
6
|
-
export declare const InvitationListContainer: ({ spaceKey, createInvitationUrl, send }: InvitationListContainerProps) =>
|
|
7
|
+
export declare const InvitationListContainer: ({ spaceKey, createInvitationUrl, send }: InvitationListContainerProps) => React.JSX.Element;
|
|
7
8
|
//# sourceMappingURL=InvitationListContainer.d.ts.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"InvitationListContainer.d.ts","sourceRoot":"","sources":["../../../../../src/components/InvitationList/InvitationListContainer.tsx"],"names":[],"mappings":"
|
|
1
|
+
{"version":3,"file":"InvitationListContainer.d.ts","sourceRoot":"","sources":["../../../../../src/components/InvitationList/InvitationListContainer.tsx"],"names":[],"mappings":"AAGA,OAAO,KAAsB,MAAM,OAAO,CAAC;AAE3C,OAAO,EAAE,KAAK,SAAS,EAAE,MAAM,oBAAoB,CAAC;AAKpD,OAAO,EAAE,KAAK,yBAAyB,EAAE,MAAM,uBAAuB,CAAC;AAEvE,MAAM,WAAW,4BAA6B,SAAQ,yBAAyB;IAC7E,QAAQ,EAAE,SAAS,CAAC;CACrB;AAED,eAAO,MAAM,uBAAuB,4CAA6C,4BAA4B,sBAa5G,CAAC"}
|
|
@@ -1,8 +1,7 @@
|
|
|
1
|
-
import { jsx as _jsx } from "react/jsx-runtime";
|
|
2
1
|
//
|
|
3
2
|
// Copyright 2023 DXOS.org
|
|
4
3
|
//
|
|
5
|
-
import { useCallback } from 'react';
|
|
4
|
+
import React, { useCallback } from 'react';
|
|
6
5
|
import { useSpace, useSpaceInvitations } from '@dxos/react-client/echo';
|
|
7
6
|
import { InvitationList } from './InvitationList';
|
|
8
7
|
export const InvitationListContainer = ({ spaceKey, createInvitationUrl, send }) => {
|
|
@@ -11,6 +10,6 @@ export const InvitationListContainer = ({ spaceKey, createInvitationUrl, send })
|
|
|
11
10
|
const handleClickRemove = useCallback((invitation) => {
|
|
12
11
|
void invitation.cancel();
|
|
13
12
|
}, [space]);
|
|
14
|
-
return (
|
|
13
|
+
return (React.createElement(InvitationList, { invitations: invitations, onClickRemove: handleClickRemove, createInvitationUrl, send }));
|
|
15
14
|
};
|
|
16
15
|
//# sourceMappingURL=InvitationListContainer.js.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"InvitationListContainer.js","sourceRoot":"","sources":["../../../../../src/components/InvitationList/InvitationListContainer.tsx"],"names":[],"mappings":"
|
|
1
|
+
{"version":3,"file":"InvitationListContainer.js","sourceRoot":"","sources":["../../../../../src/components/InvitationList/InvitationListContainer.tsx"],"names":[],"mappings":"AAAA,EAAE;AACF,0BAA0B;AAC1B,EAAE;AACF,OAAO,KAAK,EAAE,EAAE,WAAW,EAAE,MAAM,OAAO,CAAC;AAG3C,OAAO,EAAE,QAAQ,EAAE,mBAAmB,EAAE,MAAM,yBAAyB,CAAC;AAGxE,OAAO,EAAE,cAAc,EAAE,MAAM,kBAAkB,CAAC;AAOlD,MAAM,CAAC,MAAM,uBAAuB,GAAG,CAAC,EAAE,QAAQ,EAAE,mBAAmB,EAAE,IAAI,EAAgC,EAAE,EAAE;IAC/G,MAAM,KAAK,GAAG,QAAQ,CAAC,QAAQ,CAAC,CAAC;IACjC,MAAM,WAAW,GAAG,mBAAmB,CAAC,QAAQ,CAAC,CAAC;IAClD,MAAM,iBAAiB,GAAG,WAAW,CACnC,CAAC,UAA2C,EAAE,EAAE;QAC9C,KAAK,UAAU,CAAC,MAAM,EAAE,CAAC;IAC3B,CAAC,EACD,CAAC,KAAK,CAAC,CACR,CAAC;IAEF,OAAO,CACL,oBAAC,cAAc,IAAC,WAAW,EAAE,WAAW,EAAQ,aAAa,EAAE,iBAAiB,EAAE,mBAAmB,EAAE,IAAI,GAAM,CAClH,CAAC;AACJ,CAAC,CAAC"}
|
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
import { type ComponentPropsWithoutRef } from 'react';
|
|
1
|
+
import React, { type ComponentPropsWithoutRef } from 'react';
|
|
2
2
|
import { type CancellableInvitationObservable, type InvitationStatus } from '@dxos/react-client/invitations';
|
|
3
3
|
import { type ThemedClassName } from '@dxos/react-ui';
|
|
4
4
|
import { type SharedInvitationListProps } from './InvitationListProps';
|
|
@@ -10,6 +10,6 @@ export type InvitationListItemProps = SharedInvitationListProps & {
|
|
|
10
10
|
export type InvitationListItemImplProps = InvitationListItemProps & {
|
|
11
11
|
invitationStatus: InvitationStatus;
|
|
12
12
|
};
|
|
13
|
-
export declare const InvitationListItem: (props: InvitationListItemProps) =>
|
|
14
|
-
export declare const InvitationListItemImpl: ({ invitation, invitationStatus: propsInvitationStatus, send, onClickRemove, createInvitationUrl, reverseEffects, ...props }: InvitationListItemImplProps) =>
|
|
13
|
+
export declare const InvitationListItem: (props: InvitationListItemProps) => React.JSX.Element;
|
|
14
|
+
export declare const InvitationListItemImpl: ({ invitation, invitationStatus: propsInvitationStatus, send, onClickRemove, createInvitationUrl, reverseEffects, ...props }: InvitationListItemImplProps) => React.JSX.Element;
|
|
15
15
|
//# sourceMappingURL=InvitationListItem.d.ts.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"InvitationListItem.d.ts","sourceRoot":"","sources":["../../../../../src/components/InvitationList/InvitationListItem.tsx"],"names":[],"mappings":"AAKA,
|
|
1
|
+
{"version":3,"file":"InvitationListItem.d.ts","sourceRoot":"","sources":["../../../../../src/components/InvitationList/InvitationListItem.tsx"],"names":[],"mappings":"AAKA,OAAO,KAAK,EAAE,EAAE,KAAK,wBAAwB,EAAe,MAAM,OAAO,CAAC;AAE1E,OAAO,EACL,KAAK,+BAA+B,EAEpC,KAAK,gBAAgB,EAEtB,MAAM,gCAAgC,CAAC;AACxC,OAAO,EASL,KAAK,eAAe,EACrB,MAAM,gBAAgB,CAAC;AAIxB,OAAO,EAAE,KAAK,yBAAyB,EAAE,MAAM,uBAAuB,CAAC;AAGvE,MAAM,MAAM,uBAAuB,GAAG,yBAAyB,GAAG;IAChE,UAAU,EAAE,+BAA+B,CAAC;IAC5C,aAAa,CAAC,EAAE,CAAC,UAAU,EAAE,+BAA+B,KAAK,IAAI,CAAC;IACtE,cAAc,CAAC,EAAE,OAAO,CAAC;CAC1B,GAAG,eAAe,CAAC,wBAAwB,CAAC,IAAI,CAAC,CAAC,CAAC;AAEpD,MAAM,MAAM,2BAA2B,GAAG,uBAAuB,GAAG;IAClE,gBAAgB,EAAE,gBAAgB,CAAC;CACpC,CAAC;AAEF,eAAO,MAAM,kBAAkB,UAAW,uBAAuB,sBAIhE,CAAC;AA4CF,eAAO,MAAM,sBAAsB,gIAQhC,2BAA2B,sBAkI7B,CAAC"}
|
|
@@ -1,10 +1,9 @@
|
|
|
1
|
-
import { jsx as _jsx, Fragment as _Fragment, jsxs as _jsxs } from "react/jsx-runtime";
|
|
2
1
|
//
|
|
3
2
|
// Copyright 2023 DXOS.org
|
|
4
3
|
//
|
|
5
4
|
import { X } from '@phosphor-icons/react';
|
|
6
5
|
import { formatDistanceToNow } from 'date-fns';
|
|
7
|
-
import { useCallback } from 'react';
|
|
6
|
+
import React, { useCallback } from 'react';
|
|
8
7
|
import { Invitation, useInvitationStatus, } from '@dxos/react-client/invitations';
|
|
9
8
|
import { Button, Clipboard, ListItem, useTranslation, Avatar, useThemeContext, Tooltip, } from '@dxos/react-ui';
|
|
10
9
|
import { focusRing, getSize, mx } from '@dxos/react-ui-theme';
|
|
@@ -13,12 +12,16 @@ import { AuthCode } from '../AuthCode';
|
|
|
13
12
|
export const InvitationListItem = (props) => {
|
|
14
13
|
const { invitation } = props;
|
|
15
14
|
const invitationStatus = useInvitationStatus(invitation);
|
|
16
|
-
return
|
|
15
|
+
return React.createElement(InvitationListItemImpl, { ...props, invitationStatus: invitationStatus });
|
|
17
16
|
};
|
|
18
17
|
const avatarProps = { size: 10, variant: 'circle' };
|
|
19
18
|
const AvatarStackEffect = ({ animation, status, reverseEffects, }) => {
|
|
20
19
|
const { tx } = useThemeContext();
|
|
21
|
-
return (
|
|
20
|
+
return (React.createElement(React.Fragment, null,
|
|
21
|
+
React.createElement("span", { role: 'none', className: mx('absolute inline-end-auto opacity-20', reverseEffects ? 'inline-start-3' : 'inline-start-1', getSize(avatarProps.size)) },
|
|
22
|
+
React.createElement("span", { role: 'none', className: tx('avatar.ring', 'avatar__ring', { ...avatarProps, status, animation }), style: { animationDelay: '400ms' } })),
|
|
23
|
+
React.createElement("span", { role: 'none', className: mx('absolute inline-end-auto opacity-50', reverseEffects ? 'inline-start-2' : 'inline-start-2', getSize(avatarProps.size)) },
|
|
24
|
+
React.createElement("span", { role: 'none', className: tx('avatar.ring', 'avatar__ring', { ...avatarProps, status, animation }), style: { animationDelay: '200ms' } }))));
|
|
22
25
|
};
|
|
23
26
|
export const InvitationListItemImpl = ({ invitation, invitationStatus: propsInvitationStatus, send, onClickRemove, createInvitationUrl, reverseEffects, ...props }) => {
|
|
24
27
|
const { t } = useTranslation('os');
|
|
@@ -52,6 +55,32 @@ export const InvitationListItemImpl = ({ invitation, invitationStatus: propsInvi
|
|
|
52
55
|
Invitation.State.SUCCESS,
|
|
53
56
|
].includes(invitationStatus);
|
|
54
57
|
const avatarStatus = avatarError ? 'error' : avatarGreen ? 'active' : 'inactive';
|
|
55
|
-
return (
|
|
58
|
+
return (React.createElement(ListItem.Root, { id: invitationCode, ...props, classNames: ['flex gap-2 pis-3 pie-1 items-center relative', props.classNames] },
|
|
59
|
+
React.createElement(ListItem.Heading, { classNames: 'sr-only' }, t(multiUse ? 'invite many list item label' : 'invite one list item label')),
|
|
60
|
+
multiUse && (React.createElement(AvatarStackEffect, { status: avatarStatus, animation: avatarAnimation, reverseEffects: reverseEffects })),
|
|
61
|
+
React.createElement(Tooltip.Root, null,
|
|
62
|
+
React.createElement(Avatar.Root, { ...avatarProps, animation: avatarAnimation, status: avatarStatus },
|
|
63
|
+
React.createElement(Tooltip.Trigger, { asChild: true },
|
|
64
|
+
React.createElement(Avatar.Frame, { tabIndex: 0, classNames: [focusRing, 'relative rounded-full place-self-center'] },
|
|
65
|
+
React.createElement(Avatar.Fallback, { text: hexToEmoji(invitationId) })))),
|
|
66
|
+
React.createElement(Tooltip.Portal, null,
|
|
67
|
+
React.createElement(Tooltip.Content, { side: 'left' },
|
|
68
|
+
t(multiUse ? 'invite many qr label' : 'invite one qr label'),
|
|
69
|
+
React.createElement(Tooltip.Arrow, null)))),
|
|
70
|
+
showShare && invitationUrl ? (React.createElement(Tooltip.Root, null,
|
|
71
|
+
React.createElement(React.Fragment, null,
|
|
72
|
+
React.createElement(Tooltip.Trigger, { asChild: true },
|
|
73
|
+
React.createElement(Button, { variant: 'ghost', classNames: 'grow justify-start font-medium', onClick: () => send({ type: 'selectInvitation', invitation }), "data-testid": 'show-qrcode' },
|
|
74
|
+
React.createElement("span", null, t('open share panel label')))),
|
|
75
|
+
React.createElement(Clipboard.IconButton, { variant: 'ghost', value: invitationUrl })),
|
|
76
|
+
React.createElement(Tooltip.Portal, null,
|
|
77
|
+
React.createElement(Tooltip.Content, { side: 'left' }, invitationHasLifetime && React.createElement("span", null,
|
|
78
|
+
"Expires ",
|
|
79
|
+
invitationTimeLeft))))) : showAuthCode ? (React.createElement(AuthCode, { code: authCode, classNames: 'grow' })) : invitationStatus === Invitation.State.CONNECTING ? (React.createElement("span", { className: 'pli-2 grow text-neutral-500' }, "Connecting...")) : invitationStatus === Invitation.State.AUTHENTICATING ? (React.createElement("span", { className: 'pli-2 grow text-neutral-500' }, "Authenticating...")) : invitationStatus === Invitation.State.ERROR || invitationStatus === Invitation.State.TIMEOUT ? (React.createElement("span", { className: 'pli-2 grow text-neutral-500' }, "Failed")) : invitationStatus === Invitation.State.CANCELLED ? (React.createElement("span", { className: 'pli-2 grow text-neutral-500' }, "Cancelled")) : invitationStatus === Invitation.State.SUCCESS ? (React.createElement("span", { className: 'pli-2 grow truncate' }, "User joined")) : !shareable ? (React.createElement("span", { className: 'pli-2 grow text-neutral-500' }, "Pending Invitation")) : (React.createElement("span", { className: 'grow' }, " ")),
|
|
80
|
+
isCancellable ? (React.createElement(Button, { variant: 'ghost', classNames: 'flex gap-1 pli-0', onClick: cancel, "data-testid": 'cancel-invitation' },
|
|
81
|
+
React.createElement("span", { className: 'sr-only' }, t('cancel invitation label')),
|
|
82
|
+
React.createElement(X, { className: getSize(4) }))) : (React.createElement(Button, { variant: 'ghost', classNames: 'flex gap-1 pli-0', onClick: handleClickRemove, "data-testid": 'remove-invitation' },
|
|
83
|
+
React.createElement("span", { className: 'sr-only' }, t('remove invitation label')),
|
|
84
|
+
React.createElement(X, { className: getSize(4) })))));
|
|
56
85
|
};
|
|
57
86
|
//# sourceMappingURL=InvitationListItem.js.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"InvitationListItem.js","sourceRoot":"","sources":["../../../../../src/components/InvitationList/InvitationListItem.tsx"],"names":[],"mappings":"
|
|
1
|
+
{"version":3,"file":"InvitationListItem.js","sourceRoot":"","sources":["../../../../../src/components/InvitationList/InvitationListItem.tsx"],"names":[],"mappings":"AAAA,EAAE;AACF,0BAA0B;AAC1B,EAAE;AACF,OAAO,EAAE,CAAC,EAAE,MAAM,uBAAuB,CAAC;AAC1C,OAAO,EAAE,mBAAmB,EAAE,MAAM,UAAU,CAAC;AAC/C,OAAO,KAAK,EAAE,EAAiC,WAAW,EAAE,MAAM,OAAO,CAAC;AAE1E,OAAO,EAEL,UAAU,EAEV,mBAAmB,GACpB,MAAM,gCAAgC,CAAC;AACxC,OAAO,EACL,MAAM,EACN,SAAS,EACT,QAAQ,EACR,cAAc,EACd,MAAM,EACN,eAAe,EAEf,OAAO,GAER,MAAM,gBAAgB,CAAC;AACxB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AK,CAAC,OAAO,CAAC,CAAC,CAAC,CAClD,8BAAM,SAAS,EAAC,qBAAqB,kBAAmB,CACzD,CAAC,CAAC,CAAC,CAAC,SAAS,CAAC,CAAC,CAAC,CACf,8BAAM,SAAS,EAAC,6BAA6B,yBAA0B,CACxE,CAAC,CAAC,CAAC,CACF,8BAAM,SAAS,EAAC,MAAM,QAAS,CAChC;QACA,aAAa,CAAC,CAAC,CAAC,CACf,oBAAC,MAAM,IAAC,OAAO,EAAC,OAAO,EAAC,UAAU,EAAC,kBAAkB,EAAC,OAAO,EAAE,MAAM,iBAAc,mBAAmB;YACpG,8BAAM,SAAS,EAAC,SAAS,IAAE,CAAC,CAAC,yBAAyB,CAAC,CAAQ;YAC/D,oBAAC,CAAC,IAAC,SAAS,EAAE,OAAO,CAAC,CAAC,CAAC,GAAI,CACrB,CACV,CAAC,CAAC,CAAC,CACF,oBAAC,MAAM,IACL,OAAO,EAAC,OAAO,EACf,UAAU,EAAC,kBAAkB,EAC7B,OAAO,EAAE,iBAAiB,iBACd,mBAAmB;YAE/B,8BAAM,SAAS,EAAC,SAAS,IAAE,CAAC,CAAC,yBAAyB,CAAC,CAAQ;YAC/D,oBAAC,CAAC,IAAC,SAAS,EAAE,OAAO,CAAC,CAAC,CAAC,GAAI,CACrB,CACV,CACa,CACjB,CAAC;AACJ,CAAC,CAAC"}
|
|
@@ -1,10 +1,9 @@
|
|
|
1
|
-
import { jsx as _jsx, jsxs as _jsxs } from "react/jsx-runtime";
|
|
2
1
|
//
|
|
3
2
|
// Copyright 2023 DXOS.org
|
|
4
3
|
//
|
|
5
4
|
import { CaretDown, Check, Placeholder } from '@phosphor-icons/react';
|
|
6
5
|
import { useControllableState } from '@radix-ui/react-use-controllable-state';
|
|
7
|
-
import { forwardRef } from 'react';
|
|
6
|
+
import React, { forwardRef } from 'react';
|
|
8
7
|
import { Button, DropdownMenu, useTranslation } from '@dxos/react-ui';
|
|
9
8
|
import { descriptionText, getSize, mx } from '@dxos/react-ui-theme';
|
|
10
9
|
const defaultActions = {
|
|
@@ -26,12 +25,30 @@ export const BifurcatedAction = forwardRef((props, forwardedRef) => {
|
|
|
26
25
|
});
|
|
27
26
|
const activeAction = (_a = actions[activeActionKey]) !== null && _a !== void 0 ? _a : {};
|
|
28
27
|
const { t } = useTranslation('os');
|
|
29
|
-
return (
|
|
30
|
-
|
|
31
|
-
|
|
28
|
+
return (React.createElement("div", { role: 'none', className: mx('mbs-2 flex gap-px items-center', isFull && 'is-full') },
|
|
29
|
+
React.createElement(Button, { ...rest, classNames: ['bs-11 flex-1 min-is-0 flex gap-2 rounded-ie-none', classNames], ref: forwardedRef, variant: variant, "data-testid": testId, onClick: activeAction.onClick },
|
|
30
|
+
activeAction.icon && React.createElement(activeAction.icon, { className: getSize(5) }),
|
|
31
|
+
React.createElement("span", null, activeAction.label)),
|
|
32
|
+
React.createElement(DropdownMenu.Root, null,
|
|
33
|
+
React.createElement(DropdownMenu.Trigger, { asChild: true },
|
|
34
|
+
React.createElement(Button, { classNames: ['bs-11 flex-none rounded-is-none', classNames], "data-testid": dropdownTestId },
|
|
35
|
+
React.createElement("span", { className: 'sr-only' }, t('invite options label')),
|
|
36
|
+
React.createElement(CaretDown, { className: getSize(4) }))),
|
|
37
|
+
React.createElement(DropdownMenu.Portal, null,
|
|
38
|
+
React.createElement(DropdownMenu.Content, null,
|
|
39
|
+
React.createElement(DropdownMenu.Viewport, null, Object.entries(actions).map(([id, action]) => {
|
|
40
|
+
return (React.createElement(DropdownMenu.CheckboxItem, { key: id, "aria-labelledby": `${id}__label`, "aria-describedby": `${id}__description`, checked: activeActionKey === id, onCheckedChange: (checked) => checked && setActiveAction(id), classNames: 'gap-2', "data-testid": action.testId },
|
|
41
|
+
action.icon && React.createElement(action.icon, { className: getSize(5) }),
|
|
42
|
+
React.createElement("div", { role: 'none', className: 'flex-1 min-is-0 space-b-1' },
|
|
43
|
+
React.createElement("p", { id: `${id}__label` }, action.label),
|
|
44
|
+
action.description && (React.createElement("p", { id: `${id}__description`, className: descriptionText }, action.description))),
|
|
45
|
+
React.createElement(DropdownMenu.ItemIndicator, { asChild: true },
|
|
46
|
+
React.createElement(Check, { weight: 'bold', className: getSize(4) }))));
|
|
47
|
+
})),
|
|
48
|
+
React.createElement(DropdownMenu.Arrow, null))))));
|
|
32
49
|
});
|
|
33
50
|
export const Action = forwardRef((props, forwardedRef) => {
|
|
34
51
|
const { children, classNames, variant, isFull = true, ...rest } = props;
|
|
35
|
-
return (
|
|
52
|
+
return (React.createElement(Button, { ...rest, classNames: [isFull && 'is-full', 'bs-11 flex gap-2 mbs-2', classNames], ref: forwardedRef, variant: variant }, children));
|
|
36
53
|
});
|
|
37
54
|
//# sourceMappingURL=Action.js.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"Action.js","sourceRoot":"","sources":["../../../../../src/components/Panel/Action.tsx"],"names":[],"mappings":"
|
|
1
|
+
{"version":3,"file":"Action.js","sourceRoot":"","sources":["../../../../../src/components/Panel/Action.tsx"],"names":[],"mappings":"AAAA,EAAE;AACF,0BAA0B;AAC1B,EAAE;AAEF,OAAO,EAAE,SAAS,EAAE,KAAK,EAAkB,WAAW,EAAE,MAAM,uBAAuB,CAAC;AACtF,OAAO,EAAE,oBAAoB,EAAE,MAAM,wCAAwC,CAAC;AAC9E,OAAO,KAAK,EAAE,EAA0B,UAAU,EAAuB,MAAM,OAAO,CAAC;AAEvF,OAAO,EAAoB,MAAM,EAAE,YAAY,EAAE,cAAc,EAAE,MAAM,gBAAgB,CAAC;AACxF,OAAO,EAAE,eAAe,EAAE,OAAO,EAAE,EAAE,EAAE,MAAM,sBAAsB,CAAC;AAqBpE,MAAM,cAAc,GAAG;IACrB,UAAU,EAAE;QACV,KAAK,EAAE,OAAO;QACd,WAAW,EAAE,EAAE;QACf,IAAI,EAAE,WAAW;QACjB,OAAO,EAAE,GAAG,EAAE,GAAE,CAAC;KAClB;CACgC,CAAC;AAEpC,MAAM,CAAC,MAAM,gBAAgB,GAA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C;oBACJ,CAAC,CAAC,CACoB;oBACxB,oBAAC,YAAY,CAAC,KAAK,OAAG,CACD,CACH,CACJ,CAChB,CACP,CAAC;AACJ,CAAC,CAAC,CAAC;AAEH,MAAM,CAAC,MAAM,MAAM,GAAG,UAAU,CAAsC,CAAC,KAAK,EAAE,YAAY,EAAE,EAAE;IAC5F,MAAM,EAAE,QAAQ,EAAE,UAAU,EAAE,OAAO,EAAE,MAAM,GAAG,IAAI,EAAE,GAAG,IAAI,EAAE,GAAG,KAAK,CAAC;IACxE,OAAO,CACL,oBAAC,MAAM,OACD,IAAI,EACR,UAAU,EAAE,CAAC,MAAM,IAAI,SAAS,EAAE,wBAAwB,EAAE,UAAU,CAAC,EACvE,GAAG,EAAE,YAAY,EACjB,OAAO,EAAE,OAAO,IAEf,QAAQ,CACF,CACV,CAAC;AACJ,CAAC,CAAC,CAAC"}
|
|
@@ -1,11 +1,10 @@
|
|
|
1
|
-
import { jsx as _jsx } from "react/jsx-runtime";
|
|
2
1
|
//
|
|
3
2
|
// Copyright 2023 DXOS.org
|
|
4
3
|
//
|
|
5
|
-
import { forwardRef } from 'react';
|
|
4
|
+
import React, { forwardRef } from 'react';
|
|
6
5
|
import { mx } from '@dxos/react-ui-theme';
|
|
7
6
|
const Actions = forwardRef(({ classNames, children, ...props }, forwardedRef) => {
|
|
8
|
-
return (
|
|
7
|
+
return (React.createElement("div", { ...props, className: mx('flex flex-col gap-2 mbs-2', Array.isArray(children) && children.length > 1 ? 'justify-between' : 'justify-center', classNames), ref: forwardedRef }, children));
|
|
9
8
|
});
|
|
10
9
|
export { Actions };
|
|
11
10
|
//# sourceMappingURL=Actions.js.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"Actions.js","sourceRoot":"","sources":["../../../../../src/components/Panel/Actions.tsx"],"names":[],"mappings":"
|
|
1
|
+
{"version":3,"file":"Actions.js","sourceRoot":"","sources":["../../../../../src/components/Panel/Actions.tsx"],"names":[],"mappings":"AAAA,EAAE;AACF,0BAA0B;AAC1B,EAAE;AAEF,OAAO,KAAK,EAAE,EAAiC,UAAU,EAAkB,MAAM,OAAO,CAAC;AAGzF,OAAO,EAAE,EAAE,EAAE,MAAM,sBAAsB,CAAC;AAM1C,MAAM,OAAO,GAAG,UAAU,CAA+B,CAAC,EAAE,UAAU,EAAE,QAAQ,EAAE,GAAG,KAAK,EAAE,EAAE,YAAY,EAAE,EAAE;IAC5G,OAAO,CACL,gCACM,KAAK,EACT,SAAS,EAAE,EAAE,CACX,2BAA2B,EAC3B,KAAK,CAAC,OAAO,CAAC,QAAQ,CAAC,IAAI,QAAQ,CAAC,MAAM,GAAG,CAAC,CAAC,CAAC,CAAC,iBAAiB,CAAC,CAAC,CAAC,gBAAgB,EACrF,UAAU,CACX,EACD,GAAG,EAAE,YAAY,IAEhB,QAAQ,CACL,CACP,CAAC;AACJ,CAAC,CAAC,CAAC;AAEH,OAAO,EAAE,OAAO,EAAE,CAAC"}
|
|
@@ -1,5 +1,6 @@
|
|
|
1
|
+
import React from 'react';
|
|
1
2
|
import { type ButtonProps } from '@dxos/react-ui';
|
|
2
3
|
export declare const CloseButton: ({ onDone, ...props }: Omit<ButtonProps, "onClick"> & {
|
|
3
4
|
onDone?: () => void;
|
|
4
|
-
}) =>
|
|
5
|
+
}) => React.JSX.Element;
|
|
5
6
|
//# sourceMappingURL=CloseButton.d.ts.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"CloseButton.d.ts","sourceRoot":"","sources":["../../../../../src/components/Panel/CloseButton.tsx"],"names":[],"mappings":"
|
|
1
|
+
{"version":3,"file":"CloseButton.d.ts","sourceRoot":"","sources":["../../../../../src/components/Panel/CloseButton.tsx"],"names":[],"mappings":"AAKA,OAAO,KAAK,MAAM,OAAO,CAAC;AAE1B,OAAO,EAAU,KAAK,WAAW,EAAkB,MAAM,gBAAgB,CAAC;AAG1E,eAAO,MAAM,WAAW,yBAA0B,IAAI,CAAC,WAAW,EAAE,SAAS,CAAC,GAAG;IAAE,MAAM,CAAC,EAAE,MAAM,IAAI,CAAA;CAAE,sBAavG,CAAC"}
|
|
@@ -1,12 +1,14 @@
|
|
|
1
|
-
import { jsx as _jsx, jsxs as _jsxs } from "react/jsx-runtime";
|
|
2
1
|
//
|
|
3
2
|
// Copyright 2023 DXOS.org
|
|
4
3
|
//
|
|
5
4
|
import { X } from '@phosphor-icons/react';
|
|
5
|
+
import React from 'react';
|
|
6
6
|
import { Button, useTranslation } from '@dxos/react-ui';
|
|
7
7
|
import { getSize, mx } from '@dxos/react-ui-theme';
|
|
8
8
|
export const CloseButton = ({ onDone, ...props }) => {
|
|
9
9
|
const { t } = useTranslation('os');
|
|
10
|
-
return (
|
|
10
|
+
return (React.createElement(Button, { variant: 'ghost', classNames: mx('plb-0 pli-2 absolute block-start-0 inline-end-0 z-[1]'), onClick: () => onDone === null || onDone === void 0 ? void 0 : onDone(), ...props },
|
|
11
|
+
React.createElement(X, { weight: 'bold', className: getSize(4) }),
|
|
12
|
+
React.createElement("span", { className: 'sr-only' }, t('exit label'))));
|
|
11
13
|
};
|
|
12
14
|
//# sourceMappingURL=CloseButton.js.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"CloseButton.js","sourceRoot":"","sources":["../../../../../src/components/Panel/CloseButton.tsx"],"names":[],"mappings":"
|
|
1
|
+
{"version":3,"file":"CloseButton.js","sourceRoot":"","sources":["../../../../../src/components/Panel/CloseButton.tsx"],"names":[],"mappings":"AAAA,EAAE;AACF,0BAA0B;AAC1B,EAAE;AAEF,OAAO,EAAE,CAAC,EAAE,MAAM,uBAAuB,CAAC;AAC1C,OAAO,KAAK,MAAM,OAAO,CAAC;AAE1B,OAAO,EAAE,MAAM,EAAoB,cAAc,EAAE,MAAM,gBAAgB,CAAC;AAC1E,OAAO,EAAE,OAAO,EAAE,EAAE,EAAE,MAAM,sBAAsB,CAAC;AAEnD,MAAM,CAAC,MAAM,WAAW,GAAG,CAAC,EAAE,MAAM,EAAE,GAAG,KAAK,EAA0D,EAAE,EAAE;IAC1G,MAAM,EAAE,CAAC,EAAE,GAAG,cAAc,CAAC,IAAI,CAAC,CAAC;IACnC,OAAO,CACL,oBAAC,MAAM,IACL,OAAO,EAAC,OAAO,EACf,UAAU,EAAE,EAAE,CAAC,uDAAuD,CAAC,EACvE,OAAO,EAAE,GAAG,EAAE,CAAC,MAAM,aAAN,MAAM,uBAAN,MAAM,EAAI,KACrB,KAAK;QAET,oBAAC,CAAC,IAAC,MAAM,EAAC,MAAM,EAAC,SAAS,EAAE,OAAO,CAAC,CAAC,CAAC,GAAI;QAC1C,8BAAM,SAAS,EAAC,SAAS,IAAE,CAAC,CAAC,YAAY,CAAC,CAAQ,CAC3C,CACV,CAAC;AACJ,CAAC,CAAC"}
|
|
@@ -1,7 +1,7 @@
|
|
|
1
|
-
import { type PropsWithChildren } from 'react';
|
|
1
|
+
import React, { type PropsWithChildren } from 'react';
|
|
2
2
|
export declare const Emoji: ({ text, className }: {
|
|
3
3
|
text?: string;
|
|
4
4
|
className?: string;
|
|
5
|
-
}) =>
|
|
6
|
-
export declare const Centered: (props: PropsWithChildren) =>
|
|
5
|
+
}) => React.JSX.Element;
|
|
6
|
+
export declare const Centered: (props: PropsWithChildren) => React.JSX.Element;
|
|
7
7
|
//# sourceMappingURL=Emoji.d.ts.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"Emoji.d.ts","sourceRoot":"","sources":["../../../../../src/components/Panel/Emoji.tsx"],"names":[],"mappings":"AAIA,
|
|
1
|
+
{"version":3,"file":"Emoji.d.ts","sourceRoot":"","sources":["../../../../../src/components/Panel/Emoji.tsx"],"names":[],"mappings":"AAIA,OAAO,KAAK,EAAE,EAAE,KAAK,iBAAiB,EAAE,MAAM,OAAO,CAAC;AAItD,eAAO,MAAM,KAAK,wBAAyB;IAAE,IAAI,CAAC,EAAE,MAAM,CAAC;IAAC,SAAS,CAAC,EAAE,MAAM,CAAA;CAAE,sBAkB/E,CAAC;AAEF,eAAO,MAAM,QAAQ,UAAW,iBAAiB,sBAOhD,CAAC"}
|
|
@@ -1,11 +1,16 @@
|
|
|
1
|
-
|
|
1
|
+
//
|
|
2
|
+
// Copyright 2023 DXOS.org
|
|
3
|
+
//
|
|
4
|
+
import React from 'react';
|
|
2
5
|
import { mx, getSize } from '@dxos/react-ui-theme';
|
|
3
6
|
export const Emoji = ({ text, className }) => {
|
|
4
7
|
const size = 14;
|
|
5
|
-
return (
|
|
8
|
+
return (React.createElement("div", { role: 'none', className: mx(getSize(size), 'rounded relative pointer-events-none', className) },
|
|
9
|
+
React.createElement("svg", { viewBox: `0 0 ${size * 4} ${size * 4}`, width: size * 4, height: size * 4 },
|
|
10
|
+
React.createElement("text", { x: '50%', y: '50%', textAnchor: 'middle', dominantBaseline: 'middle', baselineShift: '-0.25rem', fontSize: '2.25rem' }, text))));
|
|
6
11
|
};
|
|
7
12
|
export const Centered = (props) => {
|
|
8
13
|
const { children } = props;
|
|
9
|
-
return (
|
|
14
|
+
return (React.createElement("div", { role: 'none', className: 'absolute inset-0 flex items-center justify-center' }, children));
|
|
10
15
|
};
|
|
11
16
|
//# sourceMappingURL=Emoji.js.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"Emoji.js","sourceRoot":"","sources":["../../../../../src/components/Panel/Emoji.tsx"],"names":[],"mappings":";
|
|
1
|
+
{"version":3,"file":"Emoji.js","sourceRoot":"","sources":["../../../../../src/components/Panel/Emoji.tsx"],"names":[],"mappings":"AAAA,EAAE;AACF,0BAA0B;AAC1B,EAAE;AAEF,OAAO,KAAiC,MAAM,OAAO,CAAC;AAEtD,OAAO,EAAE,EAAE,EAAE,OAAO,EAAE,MAAM,sBAAsB,CAAC;AAEnD,MAAM,CAAC,MAAM,KAAK,GAAG,CAAC,EAAE,IAAI,EAAE,SAAS,EAAyC,EAAE,EAAE;IAClF,MAAM,IAAI,GAAG,EAAE,CAAC;IAChB,OAAO,CACL,6BAAK,IAAI,EAAC,MAAM,EAAC,SAAS,EAAE,EAAE,CAAC,OAAO,CAAC,IAAI,CAAC,EAAE,sCAAsC,EAAE,SAAS,CAAC;QAC9F,6BAAK,OAAO,EAAE,OAAO,IAAI,GAAG,CAAC,IAAI,IAAI,GAAG,CAAC,EAAE,EAAE,KAAK,EAAE,IAAI,GAAG,CAAC,EAAE,MAAM,EAAE,IAAI,GAAG,CAAC;YAC5E,8BACE,CAAC,EAAC,KAAK,EACP,CAAC,EAAC,KAAK,EACP,UAAU,EAAC,QAAQ,EACnB,gBAAgB,EAAC,QAAQ,EACzB,aAAa,EAAE,UAAU,EACzB,QAAQ,EAAE,SAAS,IAElB,IAAI,CACA,CACH,CACF,CACP,CAAC;AACJ,CAAC,CAAC;AAEF,MAAM,CAAC,MAAM,QAAQ,GAAG,CAAC,KAAwB,EAAE,EAAE;IACnD,MAAM,EAAE,QAAQ,EAAE,GAAG,KAAK,CAAC;IAC3B,OAAO,CACL,6BAAK,IAAI,EAAC,MAAM,EAAC,SAAS,EAAC,mDAAmD,IAC3E,QAAQ,CACL,CACP,CAAC;AACJ,CAAC,CAAC"}
|
|
@@ -1,10 +1,13 @@
|
|
|
1
|
-
import { jsx as _jsx, jsxs as _jsxs } from "react/jsx-runtime";
|
|
2
1
|
//
|
|
3
2
|
// Copyright 2023 DXOS.org
|
|
4
3
|
//
|
|
5
|
-
import { forwardRef } from 'react';
|
|
4
|
+
import React, { forwardRef } from 'react';
|
|
6
5
|
import { descriptionText, mx } from '@dxos/react-ui-theme';
|
|
7
6
|
export const Heading = forwardRef(({ titleId, title, titleSrOnly, children, corner }, forwardedRef) => {
|
|
8
|
-
return (
|
|
7
|
+
return (React.createElement("div", { role: 'none', className: 'pbe-2 relative', ref: forwardedRef },
|
|
8
|
+
corner,
|
|
9
|
+
React.createElement("h1", { ...(!titleSrOnly && { id: titleId }), className: mx(descriptionText, 'text-center mlb-2', titleSrOnly && 'invisible') }, title),
|
|
10
|
+
titleSrOnly && React.createElement("span", { id: titleId }, title),
|
|
11
|
+
children));
|
|
9
12
|
});
|
|
10
13
|
//# sourceMappingURL=Heading.js.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"Heading.js","sourceRoot":"","sources":["../../../../../src/components/Panel/Heading.tsx"],"names":[],"mappings":"
|
|
1
|
+
{"version":3,"file":"Heading.js","sourceRoot":"","sources":["../../../../../src/components/Panel/Heading.tsx"],"names":[],"mappings":"AAAA,EAAE;AACF,0BAA0B;AAC1B,EAAE;AAEF,OAAO,KAAK,EAAE,EAAE,UAAU,EAA0C,MAAM,OAAO,CAAC;AAElF,OAAO,EAAE,eAAe,EAAE,EAAE,EAAE,MAAM,sBAAsB,CAAC;AAS3D,MAAM,CAAC,MAAM,OAAO,GAAG,UAAU,CAC/B,CAAC,EAAE,OAAO,EAAE,KAAK,EAAE,WAAW,EAAE,QAAQ,EAAE,MAAM,EAAE,EAAE,YAAY,EAAE,EAAE;IAClE,OAAO,CACL,6BAAK,IAAI,EAAC,MAAM,EAAC,SAAS,EAAC,gBAAgB,EAAC,GAAG,EAAE,YAAY;QAC1D,MAAM;QACP,+BACM,CAAC,CAAC,WAAW,IAAI,EAAE,EAAE,EAAE,OAAO,EAAE,CAAC,EACrC,SAAS,EAAE,EAAE,CAAC,eAAe,EAAE,mBAAmB,EAAE,WAAW,IAAI,WAAW,CAAC,IAE9E,KAAK,CACH;QACJ,WAAW,IAAI,8BAAM,EAAE,EAAE,OAAO,IAAG,KAAK,CAAQ;QAChD,QAAQ,CACL,CACP,CAAC;AACJ,CAAC,CACF,CAAC"}
|
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
import { type ChangeEventHandler, type ReactNode } from 'react';
|
|
1
|
+
import React, { type ChangeEventHandler, type ReactNode } from 'react';
|
|
2
2
|
import { type TextInputProps } from '@dxos/react-ui';
|
|
3
3
|
export type LargeInputProps = TextInputProps & {
|
|
4
4
|
validationMessage?: string;
|
|
@@ -7,5 +7,5 @@ export type LargeInputProps = TextInputProps & {
|
|
|
7
7
|
placeholder?: string;
|
|
8
8
|
onChange?: ChangeEventHandler<HTMLInputElement>;
|
|
9
9
|
};
|
|
10
|
-
export declare const Input: ({ validationMessage, label, ...props }: LargeInputProps) =>
|
|
10
|
+
export declare const Input: ({ validationMessage, label, ...props }: LargeInputProps) => React.JSX.Element;
|
|
11
11
|
//# sourceMappingURL=Input.d.ts.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"Input.d.ts","sourceRoot":"","sources":["../../../../../src/components/Panel/Input.tsx"],"names":[],"mappings":"AAIA,
|
|
1
|
+
{"version":3,"file":"Input.d.ts","sourceRoot":"","sources":["../../../../../src/components/Panel/Input.tsx"],"names":[],"mappings":"AAIA,OAAO,KAAK,EAAE,EAAE,KAAK,kBAAkB,EAAE,KAAK,SAAS,EAAE,MAAM,OAAO,CAAC;AAEvE,OAAO,EAAoB,KAAK,cAAc,EAAE,MAAM,gBAAgB,CAAC;AAEvE,MAAM,MAAM,eAAe,GAAG,cAAc,GAAG;IAC7C,iBAAiB,CAAC,EAAE,MAAM,CAAC;IAC3B,KAAK,CAAC,EAAE,SAAS,CAAC;IAClB,QAAQ,CAAC,EAAE,OAAO,CAAC;IACnB,WAAW,CAAC,EAAE,MAAM,CAAC;IACrB,QAAQ,CAAC,EAAE,kBAAkB,CAAC,gBAAgB,CAAC,CAAC;CACjD,CAAC;AAEF,eAAO,MAAM,KAAK,2CAA4C,eAAe,sBAU5E,CAAC"}
|
|
@@ -1,6 +1,12 @@
|
|
|
1
|
-
|
|
1
|
+
//
|
|
2
|
+
// Copyright 2023 DXOS.org
|
|
3
|
+
//
|
|
4
|
+
import React from 'react';
|
|
2
5
|
import { Input as UiInput } from '@dxos/react-ui';
|
|
3
6
|
export const Input = ({ validationMessage, label, ...props }) => {
|
|
4
|
-
return (
|
|
7
|
+
return (React.createElement(UiInput.Root, null,
|
|
8
|
+
React.createElement(UiInput.Label, null, label),
|
|
9
|
+
React.createElement(UiInput.TextInput, { ...props, classNames: 'plb-3 mbs-2 text-center' }),
|
|
10
|
+
React.createElement(UiInput.DescriptionAndValidation, null, validationMessage && React.createElement(UiInput.Validation, null, validationMessage))));
|
|
5
11
|
};
|
|
6
12
|
//# sourceMappingURL=Input.js.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"Input.js","sourceRoot":"","sources":["../../../../../src/components/Panel/Input.tsx"],"names":[],"mappings":";
|
|
1
|
+
{"version":3,"file":"Input.js","sourceRoot":"","sources":["../../../../../src/components/Panel/Input.tsx"],"names":[],"mappings":"AAAA,EAAE;AACF,0BAA0B;AAC1B,EAAE;AAEF,OAAO,KAAkD,MAAM,OAAO,CAAC;AAEvE,OAAO,EAAE,KAAK,IAAI,OAAO,EAAuB,MAAM,gBAAgB,CAAC;AAUvE,MAAM,CAAC,MAAM,KAAK,GAAG,CAAC,EAAE,iBAAiB,EAAE,KAAK,EAAE,GAAG,KAAK,EAAmB,EAAE,EAAE;IAC/E,OAAO,CACL,oBAAC,OAAO,CAAC,IAAI;QACX,oBAAC,OAAO,CAAC,KAAK,QAAE,KAAK,CAAiB;QACtC,oBAAC,OAAO,CAAC,SAAS,OAAK,KAAK,EAAE,UAAU,EAAC,yBAAyB,GAAG;QACrE,oBAAC,OAAO,CAAC,wBAAwB,QAC9B,iBAAiB,IAAI,oBAAC,OAAO,CAAC,UAAU,QAAE,iBAAiB,CAAsB,CACjD,CACtB,CAChB,CAAC;AACJ,CAAC,CAAC"}
|
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
import { type PropsWithChildren } from 'react';
|
|
1
|
+
import React, { type PropsWithChildren } from 'react';
|
|
2
2
|
export type LabelProps = PropsWithChildren<{}>;
|
|
3
|
-
export declare const Label: (props: LabelProps) =>
|
|
3
|
+
export declare const Label: (props: LabelProps) => React.JSX.Element;
|
|
4
4
|
//# sourceMappingURL=Label.d.ts.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"Label.d.ts","sourceRoot":"","sources":["../../../../../src/components/Panel/Label.tsx"],"names":[],"mappings":"AAIA,
|
|
1
|
+
{"version":3,"file":"Label.d.ts","sourceRoot":"","sources":["../../../../../src/components/Panel/Label.tsx"],"names":[],"mappings":"AAIA,OAAO,KAAK,EAAE,EAAE,KAAK,iBAAiB,EAAE,MAAM,OAAO,CAAC;AAItD,MAAM,MAAM,UAAU,GAAG,iBAAiB,CAAC,EAAE,CAAC,CAAC;AAE/C,eAAO,MAAM,KAAK,UAAW,UAAU,sBAGtC,CAAC"}
|