浏览代码

make subdomain input better accommodate long domains

Milo Schwartz 5 月之前
父节点
当前提交
c244ef387b
共有 1 个文件被更改,包括 4 次插入4 次删除
  1. 4 4
      src/app/[orgId]/settings/resources/[resourceId]/CustomDomainInput.tsx

+ 4 - 4
src/app/[orgId]/settings/resources/[resourceId]/CustomDomainInput.tsx

@@ -14,7 +14,7 @@ export default function CustomDomainInput({
     domainSuffix,
     domainSuffix,
     placeholder = "Enter subdomain",
     placeholder = "Enter subdomain",
     value: defaultValue,
     value: defaultValue,
-    onChange,
+    onChange
 }: CustomDomainInputProps) {
 }: CustomDomainInputProps) {
     const [value, setValue] = React.useState(defaultValue);
     const [value, setValue] = React.useState(defaultValue);
 
 
@@ -34,10 +34,10 @@ export default function CustomDomainInput({
                     placeholder={placeholder}
                     placeholder={placeholder}
                     value={value}
                     value={value}
                     onChange={handleChange}
                     onChange={handleChange}
-                    className="rounded-r-none flex-grow"
+                    className="rounded-r-none w-full"
                 />
                 />
-                <div className="inline-flex items-center px-3 rounded-r-md border border-l-0 border-input bg-muted text-muted-foreground">
-                    <span className="text-sm">.{domainSuffix}</span>
+                <div className="max-w-1/2 flex items-center px-3 rounded-r-md border border-l-0 border-input bg-muted text-muted-foreground">
+                    <span className="text-sm truncate">.{domainSuffix}</span>
                 </div>
                 </div>
             </div>
             </div>
         </div>
         </div>