Skip to content

Commit 7e1f449

Browse files
committed
improve display for function dropdown
1 parent b3ba54c commit 7e1f449

2 files changed

Lines changed: 8 additions & 8 deletions

File tree

libs/remix-ui/run-tab-deployed-contracts/src/lib/components/DeployedContractItem.tsx

Lines changed: 6 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -674,21 +674,21 @@ Before generating, please ask me about my design preferences first.`
674674
className="btn btn-outline-secondary w-100 d-flex align-items-center justify-content-between"
675675
style={{
676676
backgroundColor: 'var(--custom-onsurface-layer-3)',
677-
border: '1px solid var(--custom-onsurface-layer-4)',
677+
border: '1px solid var(--bs-border-color)',
678678
color: 'var(--dark/text-secondary, #d5d7e3)',
679679
padding: '8px 12px'
680680
}}
681681
icon="fas fa-caret-down"
682682
useDefaultIcon={false}
683683
>
684-
<div className="d-flex align-items-center gap-1 flex-fill text-start">
685-
<span style={{ color: 'var(--text-tertiary, #a2a3bd)' }}>Select a function to interact with...</span>
684+
<div className="d-flex align-items-center gap-1" style={{ flex: '1', minWidth: 0 }}>
685+
<span style={{ color: 'var(--text-tertiary, #a2a3bd)', overflow: 'hidden', textOverflow: 'ellipsis', whiteSpace: 'nowrap' }}>Select a function to interact with...</span>
686686
</div>
687687
</Dropdown.Toggle>
688688
<Dropdown.Menu
689689
style={{
690690
backgroundColor: 'var(--custom-onsurface-layer-2)',
691-
border: '1px solid var(--custom-onsurface-layer-4)',
691+
border: '1px solid var(--bs-border-color)',
692692
maxHeight: '240px',
693693
overflowY: 'auto',
694694
width: '100%',
@@ -697,7 +697,7 @@ Before generating, please ask me about my design preferences first.`
697697
>
698698
<div style={{
699699
padding: '8px',
700-
borderBottom: '1px solid var(--custom-onsurface-layer-4)',
700+
borderBottom: '1px solid var(--bs-border-color)',
701701
backgroundColor: 'var(--custom-onsurface-layer-2)'
702702
}}>
703703
<input
@@ -712,7 +712,7 @@ Before generating, please ask me about my design preferences first.`
712712
onClick={(e) => e.stopPropagation()}
713713
style={{
714714
backgroundColor: 'var(--custom-onsurface-layer-3)',
715-
border: '1px solid var(--custom-onsurface-layer-4)',
715+
border: '1px solid var(--bs-border-color)',
716716
color: 'var(--dark/text-secondary, #d5d7e3)',
717717
fontSize: '11px'
718718
}}

libs/remix-ui/run-tab-environment/src/lib/components/envCategoryUI.tsx

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -59,15 +59,15 @@ export const EnvCategoryUI: React.FC<EnvCategoryUIProps> = ({ isOpen, onToggle }
5959
e.stopPropagation()
6060
}}
6161
>
62-
<Dropdown.Toggle as={CustomToggle} data-id="settingsSelectEnvCategoryOptions" className="btn btn-secondary w-100 d-inline-block pe-0 border-0" icon="fas fa-caret-down text-secondary ms-2" useDefaultIcon={false} style={{ backgroundColor: 'var(--custom-onsurface-layer-3)' }}>
62+
<Dropdown.Toggle as={CustomToggle} data-id="settingsSelectEnvCategoryOptions" className="btn btn-secondary w-100 d-inline-block pe-0" icon="fas fa-caret-down text-secondary ms-2" useDefaultIcon={false} style={{ backgroundColor: 'var(--custom-onsurface-layer-3)', border: '1px solid var(--bs-border-color)' }}>
6363
<div style={{ flexGrow: 1, overflow: 'hidden', display:'flex', justifyContent:'left' }}>
6464
<div className="text-truncate text-secondary">
6565
{<span data-id="selectedVersion">{enforceSelect ? '<select>' : provider?.displayName}</span>}
6666
</div>
6767
</div>
6868
</Dropdown.Toggle>
6969

70-
<Dropdown.Menu as={CustomMenu} className="custom-dropdown-items overflow-hidden" style={{ backgroundColor: 'var(--custom-onsurface-layer-3)', zIndex: 1000, '--theme-text-color': themeQuality === 'dark' ? 'white' : 'black', padding: 0, minWidth: 'max-content', width: 'auto' } as React.CSSProperties}>
70+
<Dropdown.Menu as={CustomMenu} className="custom-dropdown-items overflow-hidden" style={{ backgroundColor: 'var(--custom-onsurface-layer-3)', border: '1px solid var(--bs-border-color)', zIndex: 1000, '--theme-text-color': themeQuality === 'dark' ? 'white' : 'black', padding: 0, minWidth: 'max-content', width: 'auto' } as React.CSSProperties}>
7171
{ (provider?.category === 'Dev' || provider?.category === 'Browser Extension') && <Dropdown.Item onClick={() => {
7272
setEnforceSelect(true)
7373
dispatch({ type: 'CLEAR_ALL_ACCOUNTS', payload: null })

0 commit comments

Comments
 (0)