diff --git a/src/App.css b/src/App.css index 13bc334e..0c123e2a 100644 --- a/src/App.css +++ b/src/App.css @@ -40,3 +40,151 @@ .ReactCollapse--collapse { transition: height 500ms; } + +/* Custom selection styles for CLI command textareas */ +textarea#prepareCommand::selection, +textarea#submitCommand::selection { + background-color: #0078d4; + color: #ffffff; +} + +/* Copy icon positioning for CLI command textareas */ +.cli-command-container { + position: relative; + display: inline-block; + width: 100%; +} + +.cli-command-container .copy-icon { + position: absolute; + top: 10px; + right: 10px; + z-index: 10; + background: rgba(0, 120, 212, 0.9); + color: white; + border: none; + border-radius: 4px; + padding: 8px 12px; + cursor: pointer; + font-size: 14px; + transition: all 0.2s ease; +} + +.cli-command-container .copy-icon:hover { + background: rgba(0, 120, 212, 1); + transform: scale(1.05); +} + +.cli-command-container .copy-icon:active { + transform: scale(0.95); +} + +/* Governance Proposal Link Button */ +.proposal-link-button { + display: inline-block; + background: linear-gradient(135deg, #ff6b35, #f7931e); + color: white; + text-decoration: none; + padding: 12px 24px; + border-radius: 8px; + font-weight: 700; + font-size: 16px; + text-align: center; + margin: 16px 0; + box-shadow: 0 4px 12px rgba(255, 107, 53, 0.3); + transition: all 0.3s ease; + border: 2px solid transparent; +} + +.proposal-link-button:hover { + background: linear-gradient(135deg, #e55a2b, #e0841a); + transform: translateY(-2px); + box-shadow: 0 6px 20px rgba(255, 107, 53, 0.4); + color: white; + text-decoration: none; +} + +.proposal-link-button:active { + transform: translateY(0); + box-shadow: 0 2px 8px rgba(255, 107, 53, 0.3); +} + +.proposal-link-section { + text-align: center; + margin: 20px 0; +} + +/* Voting Command Sections */ +.voting-command-section { + margin: 16px 0; + width: 100% !important; + max-width: 100% !important; + clear: both; +} + +.voting-command-section .cli-command-container textarea { + min-height: 60px; + height: auto; + width: 100%; + max-width: 100%; + font-family: 'Courier New', monospace; + font-size: 13px; + line-height: 1.4; + padding: 12px 50px 12px 12px; /* top right bottom left - extra padding on right for copy icon */ + word-break: break-all; + box-sizing: border-box; +} + +.voting-command-label { + display: block; + font-weight: 600; + font-size: 14px; + margin-bottom: 8px; + padding: 4px 8px; + border-radius: 4px; + width: fit-content; +} + +.voting-command-label--yes { + background-color: rgba(34, 197, 94, 0.2); + color: #22c55e; + border: 1px solid rgba(34, 197, 94, 0.3); +} + +.voting-command-label--no { + background-color: rgba(239, 68, 68, 0.2); + color: #ef4444; + border: 1px solid rgba(239, 68, 68, 0.3); +} + +.voting-command-label--abstain { + background-color: rgba(156, 163, 175, 0.2); + color: #9ca3af; + border: 1px solid rgba(156, 163, 175, 0.3); +} + +/* Hash Info Section - Less Prominent */ +.hash-info-section { + margin-top: 24px; + padding-top: 16px; + border-top: 1px solid rgba(255, 255, 255, 0.1); + opacity: 0.8; +} + +.hash-info-section p { + font-size: 12px; + margin: 4px 0; +} + +/* Override width constraints for voting commands in proposal budget section */ +.proposal .budget .voting-command-section { + width: 100% !important; + max-width: 100% !important; + float: none !important; + clear: both; +} + +.proposal .budget .voting-command-section .cli-command-container { + width: 100% !important; + max-width: 100% !important; +} diff --git a/src/components/governance/GovDetails.jsx b/src/components/governance/GovDetails.jsx index b452f77e..e4863fc9 100644 --- a/src/components/governance/GovDetails.jsx +++ b/src/components/governance/GovDetails.jsx @@ -47,59 +47,74 @@ class Govdetails extends Component {
| Current SuperBlock: | +{this.state.superBlockData.next_superblock} | +
| SuperBlock Budget: | +{this.state.superBlockData.budget} SYS | +
| Requested SuperBlock Budget: | +{this.state.budgetSum} SYS | +
| SuperBlock Date (UTC): | +{this.state.superBlockData.superblock_date} | +
| Voting Deadline (UTC): | +{this.state.superBlockData.voting_deadline} | +
| SuperBlock | +Budget | +Date | +
|---|---|---|
| {this.state.superBlockData.sb1} | +{this.state.superBlockData.sb1Budget.result} SYS | +{this.state.superBlockData.sb1Date} | +
| {this.state.superBlockData.sb2} | +{this.state.superBlockData.sb2Budget.result} SYS | +{this.state.superBlockData.sb2Date} | +
| {this.state.superBlockData.sb3} | +{this.state.superBlockData.sb3Budget.result} SYS | +{this.state.superBlockData.sb3Date} | +
| {this.state.superBlockData.sb4} | +{this.state.superBlockData.sb4Budget.result} SYS | +{this.state.superBlockData.sb4Date} | +
| {this.state.superBlockData.sb5} | +{this.state.superBlockData.sb5Budget.result} SYS | +{this.state.superBlockData.sb5Date} | +
- Hash:
- Collateral hash:{" "} - - {proposal.ColHash} - -
+ + {/* Prominent View Proposal Button */} +{days_remaining < 30 ? ( {`(${days_remaining} Day${ @@ -101,41 +96,93 @@ function ProposalCardInfo({ } Remaining)`} )}
- Voting strings (CLI): -
+ Hash:
+ Collateral hash:{" "} + + {proposal.ColHash} + +
+Prepare command is ready to be copied. Please copy and paste it into Syscoin Q.T console for payment txid. @@ -399,7 +407,7 @@ function ProposalForm() { text={prepareCommand} onCopy={copyButton} > - +
go_submit. Submitting too early may cause your proposal to fail.
Submit command is ready to be copied. Please copy and paste it into Syscoin Q.T console to submit your proposal. This could take a couple minutes. @@ -451,7 +467,7 @@ function ProposalForm() { text={submitCommand} onCopy={copyButton} > - +