@@ -15,7 +15,7 @@ import setServerAllocationNotes from '@/api/server/network/setServerAllocationNo
1515import useFlash from '@/plugins/useFlash' ;
1616import { ServerContext } from '@/state/server' ;
1717
18- const Code = styled . code `${ tw `font-mono py-1 px-2 bg-neutral-900 rounded text-sm block` } ` ;
18+ const Code = styled . code `${ tw `font-mono py-1 px-2 bg-neutral-900 rounded text-sm inline- block break-all ` } ` ;
1919const Label = styled . label `${ tw `uppercase text-xs mt-1 text-neutral-400 block px-1 select-none transition-colors duration-150` } ` ;
2020
2121interface Props {
@@ -40,22 +40,21 @@ const AllocationRow = ({ allocation, onSetPrimary, onNotesChanged }: Props) => {
4040 } , 750 ) ;
4141
4242 return (
43- < GreyRowBox
44- $hoverable = { false }
45- // css={index > 0 ? tw`mt-2 overflow-x-auto` : tw`overflow-x-auto`}
46- >
47- < div css = { tw `hidden md:block pl-4 pr-6 text-neutral-400` } >
48- < FontAwesomeIcon icon = { faNetworkWired } />
43+ < GreyRowBox $hoverable = { false } css = { tw `flex-wrap md:flex-no-wrap mt-2` } >
44+ < div css = { tw `flex items-center w-full md:w-auto` } >
45+ < div css = { tw `pl-4 pr-6 text-neutral-400` } >
46+ < FontAwesomeIcon icon = { faNetworkWired } />
47+ </ div >
48+ < div css = { tw `mr-4 flex-1 md:w-40` } >
49+ < Code > { allocation . alias || allocation . ip } </ Code >
50+ < Label > IP Address</ Label >
51+ </ div >
52+ < div css = { tw `w-16 md:w-24 overflow-hidden` } >
53+ < Code > { allocation . port } </ Code >
54+ < Label > Port</ Label >
55+ </ div >
4956 </ div >
50- < div css = { tw `mr-4` } >
51- < Code > { allocation . alias || allocation . ip } </ Code >
52- < Label > IP Address</ Label >
53- </ div >
54- < div >
55- < Code > { allocation . port } </ Code >
56- < Label > Port</ Label >
57- </ div >
58- < div css = { tw `px-8 flex-none sm:flex-1 self-start` } >
57+ < div css = { tw `mt-4 w-full md:mt-0 md:flex-1 md:w-auto` } >
5958 < InputSpinner visible = { loading } >
6059 < Textarea
6160 css = { tw `bg-neutral-800 hover:border-neutral-600 border-transparent` }
@@ -65,7 +64,7 @@ const AllocationRow = ({ allocation, onSetPrimary, onNotesChanged }: Props) => {
6564 />
6665 </ InputSpinner >
6766 </ div >
68- < div css = { tw `w-32 text-right pr -4 sm:pr-0 ` } >
67+ < div css = { tw `w-full md:flex-none md:w- 32 md: text-center mt -4 md:mt-0 text-right ml-4 ` } >
6968 { allocation . isDefault ?
7069 < span css = { tw `bg-green-500 py-1 px-2 rounded text-green-50 text-xs` } > Primary</ span >
7170 :
0 commit comments