Skip to content

An open source design system that's fully customizable and agent ready

TypeScript

fix(docsite): give ChatComposerInput block examples a definite width (#4012)

Ernest262bff4d7069
diff --git a/packages/cli/templates/blocks/components/ChatComposerInput/ChatComposerInputControlledInput.tsx b/packages/cli/templates/blocks/components/ChatComposerInput/ChatComposerInputControlledInput.tsx
index 82ad3b5c66..593c2de7f0 100644
--- a/packages/cli/templates/blocks/components/ChatComposerInput/ChatComposerInputControlledInput.tsx
+++ b/packages/cli/templates/blocks/components/ChatComposerInput/ChatComposerInputControlledInput.tsx
@@ -10,7 +10,7 @@ import {Text} from '@astryxdesign/core/Text';
export default function ChatComposerInputControlledInput() {
const [value, setValue] = useState('');
return (
- <Stack direction="vertical" gap={3} style={{width: '100%', maxWidth: 450}}>
+ <Stack direction="vertical" gap={3} style={{width: 450, maxWidth: '100%'}}>
<ChatComposer
onSubmit={() => setValue('')}
value={value}
diff --git a/packages/cli/templates/blocks/components/ChatComposerInput/ChatComposerInputDisabled.tsx b/packages/cli/templates/blocks/components/ChatComposerInput/ChatComposerInputDisabled.tsx
index 6302828731..eb9fad0213 100644
--- a/packages/cli/templates/blocks/components/ChatComposerInput/ChatComposerInputDisabled.tsx
+++ b/packages/cli/templates/blocks/components/ChatComposerInput/ChatComposerInputDisabled.tsx
@@ -7,7 +7,7 @@ import {Stack} from '@astryxdesign/core/Layout';
export default function ChatComposerInputDisabled() {
return (
- <Stack direction="vertical" style={{width: '100%', maxWidth: 450}}>
+ <Stack direction="vertical" style={{width: 450, maxWidth: '100%'}}>
<ChatComposer
onSubmit={() => {}}
isDisabled
diff --git a/packages/cli/templates/blocks/components/ChatComposerInput/ChatComposerInputMentionTrigger.tsx b/packages/cli/templates/blocks/components/ChatComposerInput/ChatComposerInputMentionTrigger.tsx
index 0b8da50f88..b1fd059899 100644
--- a/packages/cli/templates/blocks/components/ChatComposerInput/ChatComposerInputMentionTrigger.tsx
+++ b/packages/cli/templates/blocks/components/ChatComposerInput/ChatComposerInputMentionTrigger.tsx
@@ -43,7 +43,7 @@ export default function ChatComposerInputMentionTrigger() {
};
return (
- <Stack direction="vertical" gap={3} style={{width: '100%', maxWidth: 450}}>
+ <Stack direction="vertical" gap={3} style={{width: 450, maxWidth: '100%'}}>
<ChatComposer
onSubmit={() => setValue('')}
input={
diff --git a/packages/cli/templates/blocks/components/ChatComposerInput/ChatComposerInputMultipleTriggers.tsx b/packages/cli/templates/blocks/components/ChatComposerInput/ChatComposerInputMultipleTriggers.tsx
index 63a4fe9bd8..c27a3008ef 100644
--- a/packages/cli/templates/blocks/components/ChatComposerInput/ChatComposerInputMultipleTriggers.tsx
+++ b/packages/cli/templates/blocks/components/ChatComposerInput/ChatComposerInputMultipleTriggers.tsx
@@ -54,7 +54,7 @@ export default function ChatComposerInputMultipleTriggers() {
};
return (
- <Stack direction="vertical" gap={3} style={{width: '100%', maxWidth: 450}}>
+ <Stack direction="vertical" gap={3} style={{width: 450, maxWidth: '100%'}}>
<Text type="supporting" color="secondary">
Type @ for mentions (blue) or / for commands (yellow)
</Text>
diff --git a/packages/cli/templates/blocks/components/ChatComposerInput/ChatComposerInputShowcase.tsx b/packages/cli/templates/blocks/components/ChatComposerInput/ChatComposerInputShowcase.tsx
index 3361e903fe..6d0b44eb80 100644
--- a/packages/cli/templates/blocks/components/ChatComposerInput/ChatComposerInputShowcase.tsx
+++ b/packages/cli/templates/blocks/components/ChatComposerInput/ChatComposerInputShowcase.tsx
@@ -7,7 +7,7 @@ import {Stack} from '@astryxdesign/core/Layout';
export default function ChatComposerInputShowcase() {
return (
- <Stack direction="vertical" style={{width: '100%', maxWidth: 450}}>
+ <Stack direction="vertical" style={{width: 450, maxWidth: '100%'}}>
<ChatComposer
onSubmit={() => {}}
input={
diff --git a/packages/cli/templates/blocks/components/ChatComposerInput/ChatComposerInputSlashCommands.tsx b/packages/cli/templates/blocks/components/ChatComposerInput/ChatComposerInputSlashCommands.tsx
index 794fa82a8b..e2939fa91c 100644
--- a/packages/cli/templates/blocks/components/ChatComposerInput/ChatComposerInputSlashCommands.tsx
+++ b/packages/cli/templates/blocks/components/ChatComposerInput/ChatComposerInputSlashCommands.tsx
@@ -40,7 +40,7 @@ export default function ChatComposerInputSlashCommands() {
};
return (
- <Stack direction="vertical" style={{width: '100%', maxWidth: 450}}>
+ <Stack direction="vertical" style={{width: 450, maxWidth: '100%'}}>
<ChatComposer
onSubmit={() => {}}
input={