Browse Source

fix(pending channel): fix pending channel styles

renovate/lint-staged-8.x
Jack Mallers 7 years ago
parent
commit
01dc847515
  1. 2
      app/components/Channels/OpenPendingChannel.js
  2. 4
      app/components/Channels/OpenPendingChannel.scss
  3. 19
      app/reducers/channels.js
  4. 2
      app/routes/channels/components/Channels.js

2
app/components/Channels/OpenPendingChannel.js

@ -6,7 +6,7 @@ import styles from './OpenPendingChannel.scss'
const OpenPendingChannel = ({ ticker, channel: { channel }, currentTicker, explorerLinkBase }) => (
<li className={styles.channel} onClick={() => shell.openExternal(`${explorerLinkBase}/tx/${channel.channel_point.split(':')[0]}`)}>
<h1 className={styles.pending}>Status: Pending</h1>
<h1 className={styles.pending}>Pending</h1>
<div className={styles.left}>
<section className={styles.remotePubkey}>
<span>Remote Pubkey</span>

4
app/components/Channels/OpenPendingChannel.scss

@ -2,7 +2,7 @@
.channel {
position: relative;
background: $white;
background: $lightgrey;
padding: 10px;
display: flex;
flex-direction: row;
@ -13,7 +13,7 @@
opacity: 0.5;
.pending {
color: $green;
color: $main;
position: absolute;
top: 0;
left: 10px;

19
app/reducers/channels.js

@ -190,7 +190,7 @@ const ACTION_HANDLERS = {
[GET_CHANNELS]: state => ({ ...state, channelsLoading: true }),
[RECEIVE_CHANNELS]: (state, { channels, pendingChannels }) => (
{ ...state, channelsLoading: false, channels, pendingChannels }
{ ...state, channelsLoading: false, channels, pendingChannels: state.pendingChannels }
),
[OPENING_CHANNEL]: state => ({ ...state, openingChannel: true }),
@ -248,7 +248,22 @@ const initialState = {
channels: [],
pendingChannels: {
total_limbo_balance: '',
pending_open_channels: [],
pending_open_channels: [
{
"channel": {
"remote_node_pub": "0368b02d9e4a44bb156660cf48ed7492445c7cb95435c86125e74953047c7706e3",
"channel_point": "01de1cddaf47637b71c37e019f42746aa1135351a4e4539d983ca95f12049a82:0",
"capacity": "16777216",
"local_balance": "16768528",
"remote_balance": "0"
},
"confirmation_height": 0,
"blocks_till_open": 0,
"commit_fee": "8688",
"commit_weight": "600",
"fee_per_kw": "12000"
}
],
pending_closing_channels: [],
pending_force_closing_channels: []
},

2
app/routes/channels/components/Channels.js

@ -41,6 +41,8 @@ class Channels extends Component {
setCurrentChannel
} = this.props
console.log('allChannels: ', allChannels)
return (
<div className={`${styles.container} ${viewType === 1 && styles.graphview}`}>
<ChannelForm {...channelFormProps} />

Loading…
Cancel
Save