Skip to content

Commit f359c0b

Browse files
authored
Merge pull request #219 from jdogresorg/counterparty-2.0
Merge changes from counterparty-2.0 branch to master
2 parents 7c8b9fc + 654a842 commit f359c0b

9 files changed

Lines changed: 434 additions & 391 deletions

File tree

CHANGELOG.md

Lines changed: 8 additions & 200 deletions
Original file line numberDiff line numberDiff line change
@@ -1,200 +1,8 @@
1-
Version 0.9.35 - Version 0.9.37 Removed and replaced with:
2-
- `counterparty-classic` branch
3-
- `counterparty-2.0` branch
4-
5-
Version 0.9.34 - August 30th, 2024
6-
- Fix issue with divisiblity on `Reset Supply` form
7-
- Updates to support datatables 2.1.5
8-
9-
Version 0.9.33 - July 29th, 2024
10-
- Fix issue with closing dispensers from `origin` address
11-
12-
Version 0.9.32 - July 23rd, 2024
13-
- Set default CP API servers to public.tokenscan.io
14-
- Set default explorer API servers to tokenscan.io
15-
- Fixed numeric value parsing / validation for order forms
16-
- Fixed `checkWalletUpgrade()` to handle semantic versioning properly
17-
- Updated NFT display method to load data from API JSON projects array
18-
- Removed "Counterparty General Fund" from ADS donation options
19-
- Removed "View Transaction" context menu from history
20-
- Added "Create Subasset" context menu
21-
- Added "Verify" option to signing transaction dialog
22-
- Added support for displaying change address and amount when verifying transaction
23-
- Added support for closing dispensers from origin address
24-
- Added support for saving preferred sort order on markets and dispensers
25-
26-
Version 0.9.31 - April 15th, 2024
27-
- Set default CP API servers to public.xchain.io
28-
- Add ‘Reset to Defaults’ option in server settings
29-
30-
Version 0.9.30 - April 11th, 2024
31-
- Start using SSL by default for CP API
32-
33-
Version 0.9.29 - February 29th, 2024
34-
- Fixed issue with ADS and tx fee calculations
35-
- Added "UTXO Usage" preference in settings
36-
37-
Version 0.9.28 - February 15th, 2024
38-
- Improved transaction fee interface
39-
- Improved MPMA send transaction fee support
40-
- Adjusted default tx size to 256 bytes
41-
42-
Version 0.9.27 - February 8th, 2024
43-
- Better transaction fee estimation support
44-
45-
Version 0.9.26 - November 30th, 2023
46-
- Added support for new issuance IDs (22/23)
47-
- Added checks to verify wallet is unlocked before allowing add/import addresses
48-
- Update to pass `null` for description in asset issuance transfers
49-
- Update to start using `lock` flag in issuances instead of `LOCK` text
50-
51-
Version 0.9.25 - September 22nd, 2023
52-
- Fixed issue with missing first address
53-
- Fixed issue with wallet auto-locking
54-
55-
Version 0.9.24 - September 19th, 2023
56-
- Added support for pooling ADS donations
57-
- Added support for reviewing license agreement
58-
- Started passing forward `advanced` params in CP API requests
59-
- Fixed issues with sweep form
60-
- Fixed issue with fee not being properly passed on issuances
61-
- Added Betting tab back with build bounty
62-
- Added support for adding up to 100 new addresses at once
63-
- Added support for importing many private keys at once
64-
- Added support for auto-lock feature
65-
- Added support for decoding XCP transactions in sign transactions
66-
67-
Version 0.9.23 - May 4th, 2023
68-
- Added support for editing DUST preferences
69-
- Added support for CIP25 (Viewing NFTs and Stamps)
70-
- Increase max asset description length to 10k characters
71-
- Fixed security issue with autocomplete
72-
- Fixed Trezor Support
73-
- Added issuance data encoding cost notification
74-
- Added Automatic Donation System (ADS)
75-
- Added lazy loading of asset list images
76-
- Added balance list view options menu
77-
- Fixed issues with BTC/XCP asset divisibility not being set
78-
- Fixed satoshi rounding issues by using `getSatoshis()`
79-
80-
Version 0.9.22 - September 9th, 2022
81-
- Issue with `reset supply` form always passing divisible as true
82-
83-
Version 0.9.21 - September 2nd, 2022
84-
- Changed default token type to non-divisible
85-
- Updated MPMA data encoding fee calculations
86-
- updated `checkWalletUpgrade()` to use `ajax()`
87-
- Got basic Trezor integration working again
88-
- Updates to support CIP03 Token Resets
89-
- Updates to support CIP24 Oracled Dispensers
90-
- Added 'Close Dispenser' main menu item
91-
92-
Version 0.9.20 - May 26th, 2022
93-
- Update to only pull list of open dispensers for watchlists
94-
- Increased asset description length to 200 characters
95-
- Added additional MPMA Send list validations
96-
- Added better API error handling
97-
- Start passing pubkey on all `create_send` requests
98-
- Fixed issue with asterisks in asset descriptions
99-
- Fixed issue with wallet addresses persisting after wallet reset
100-
- Fixed MAX button to subtract miners fee from max amount
101-
- Fixed issue with mpma amounts being rounded at times
102-
- Support for collapsible subassets
103-
- Support for importing bech32 addresses
104-
105-
Version 0.9.19 - September 7th, 2021
106-
- Adjust minimum tx fee code to allow lower minimums
107-
- Limit dispenser watchlists to 10
108-
- Limit exchange market list to 10
109-
- Allow default market and exchange tabs to be removed
110-
- Dispenser updates to add more protection
111-
- Fixed issue with removing assets from dispenser watchlist
112-
- Ignore tabs when changing amount values
113-
- Hide passphrase by default on entry
114-
- BTC Name Service and asset support in sends
115-
- Added 'Copy' button to view address page
116-
117-
Version 0.9.18 - April 17, 2021
118-
- Added warning about setting up dispensers on used addresses
119-
120-
Version 0.9.17 - March 29, 2021
121-
- Allow segwit addresses to export private keys
122-
- Disabled MPMA sends from segwit addresses to prevent loss of BTC
123-
124-
Version 0.9.16 - March 16, 2021
125-
- Added support for opening dispensers on empty addresses
126-
- Added multiple dispensers on same address warning
127-
- 'Buy FULLACCESS' button now links direct to official dispenser
128-
- Stopped forcing quantity to multiple of what dispensers is offering
129-
130-
Version 0.9.15 - March 14, 2021
131-
- Added support for editing minimum transaction fee
132-
- Started enforcing minimum fee on transactions
133-
- Adjusted MPMA send settings and minimum fee
134-
135-
Version 0.9.14 - March 11, 2021
136-
- Issue with MPMA sends not working properly at times
137-
138-
Version 0.9.13 - March 10, 2021
139-
- Started using api.counterparty.io API
140-
- Issue with sends using text memos
141-
142-
Version 0.9.12 - January 15, 2021
143-
- Added support for destroy transactions
144-
- Added support for displaying transaction status
145-
- Added support for decoding hex memos
146-
- Added "Cancel Order" option to main menu
147-
- Bumped minimum BTC order amount to 0.00001
148-
- Issue with MPMA tx fee not being passed to API
149-
- Issue with context menus appearing in wrong locations
150-
- Issue with asset description changing on issuing supply
151-
152-
Version 0.9.11 - March 1, 2020
153-
- Added BIP39 passphrase support
154-
- Fixed send amount formatting issue
155-
156-
Version 0.9.10 - February 25, 2020
157-
- Changed licensing to MIT
158-
- Added support for segwit addresses
159-
- Added support for burns
160-
- Added support for sweeps
161-
- Added support for dispensers
162-
- Added support for destroys
163-
- Added support for multi-peer-multi-assets sends (MPMA)
164-
- Added donation annoyware
165-
- Opened Exchange interface to everyone
166-
- Added Dispensers watchlist interface
167-
168-
Version 0.9.9 - February 20, 2019
169-
- Removed defunct blocktrail.com API calls (more info)
170-
- Setup all API calls with multiple failovers
171-
- Updated bounty amounts to adjust for XCP value drop in last year
172-
- Added ability to buy XCHAINPEPE and FULLACCESS tokens from DEX
173-
- Added “API Keys” section to settings
174-
175-
Version 0.9.8 - March 29, 2018
176-
- Added basic framework for hardware wallet support (import & sign)
177-
- Added basic Trezor hardware wallet integration
178-
179-
Version 0.9.7 - March 15, 2018
180-
- Issue with create_btcpay API calls failing (more info)
181-
- issue with markets sidebar displaying wrong volume and % (more info)
182-
- Issues with URIs not working on windows/linux (more info)
183-
- Added support for addresses with 1,000+ assets/tokens (more info)
184-
- Ability to check for version update manually
185-
186-
Version 0.9.6 - Feburary 10, 2018
187-
- Added support for Highcharts
188-
- Added support for Decentralized Exchange (DEX)
189-
- Added market view (chart, orders, history, etc)
190-
- Added 20+ technical indicators to market view
191-
- Added suport Auto-BTCpay and manual BTCpay notifications
192-
- Added support for /api/history/address endpoint
193-
- Added support for displaying asset lock status via lock/unlock icons
194-
- Added version update notification system
195-
- Issue where asset description was reset when issuing additional supply
196-
- Issue where issuing additional supply was resetting description
197-
- Display issue with pending transactions in history list
198-
199-
Version 0.9.5 - October 13, 2017
200-
- Initial release for Windows, Mac, and Linux
1+
Version 2.0.0 - October 31st, 2024
2+
- Add `tag` as required field to /compose/destroy
3+
- Updates to detect BTC payment to dispenser
4+
- Updated MPMA sends support new memo format (https://github.com/CounterpartyXCP/counterparty-core/issues/2568)
5+
- Re-enable form submit button after fee estimation failures
6+
- Updates to support creating CP 2.0 `dispense` transactions
7+
- update buy from dispenser form to use `dispense` instead of `send`
8+
- Updated default servers for counterparty 2.0 APIs and Explorer

html/about.html

Lines changed: 10 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -2,7 +2,8 @@
22
<center>
33
<p>FreeWallet is a free wallet which supports Bitcoin and Counterparty.</p>
44
<a href="https://freewallet.io"><img src="images/logo.png" height="100" style="margin-bottom: 5px"></a>
5-
<div id="fw_version"></div>
5+
<br>FreeWallet Version (<span id="fw_version"></span>)
6+
<br>Counterparty API Version (<span id="cp_version"></span>)
67
<hr size=1 class="spacer">
78
<p>Freewallet uses public APIs available from the following providers:</p>
89
<div>
@@ -52,18 +53,23 @@
5253
var address = '1FWDonkMbC6hL64JiysuggHnUAw2CKWszs',
5354
debug = $('#btn-debug'),
5455
update = $('#btn-update'),
55-
version = (is_nwjs()) ? 'Version ' + nw.App.manifest.version : 'Development Build';
56+
apiInfo = FW.COUNTERPARTY_API;
57+
58+
// Set the FreeWallet and API version information
59+
var fw_version = (is_nwjs()) ? nw.App.manifest.version : 'Development Build',
60+
cp_version = apiInfo.version_major + '.' + apiInfo.version_minor + '.' + apiInfo.version_revision;
5661

5762
// Display current version number
58-
$('#fw_version').html(version);
63+
$('#fw_version').html(fw_version);
64+
$('#cp_version').html(cp_version);
5965

6066
// Handle showing/hiding the debug button
6167
if(is_nwjs()){
6268
debug.click($.debounce(100,function(e){
6369
nw.Window.get().showDevTools();
6470
}));
6571
update.click($.debounce(100,function(e){
66-
checkWalletUpgrade(version, true);
72+
checkWalletUpgrade(fw_version, true);
6773
}));
6874
} else {
6975
debug.hide();

html/dispensers/buy.html

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -31,7 +31,7 @@
3131
dest = FW.DIALOG_DATA.destination,
3232
amt_sat = getSatoshis(vals['btc-amount']),
3333
fee_sat = getSatoshis(vals['fee-amount']),
34-
command = (broadcast) ? 'cpSend' : 'createSend';
34+
command = (broadcast) ? 'cpDispense' : 'createDispense';
3535
eval(command)(network, source, dest, null, null, 'BTC', amt_sat, fee_sat, callback);
3636
}
3737

@@ -118,8 +118,8 @@
118118
placement: 'bottom'
119119
});
120120

121-
// Handle updating the transaction fee based on actual tx size
122-
updateTransactionSize();
121+
// Handle updating the transaction fee based on actual tx size (done automatically in amount field)
122+
// updateTransactionSize();
123123

124124
},100);
125125

html/fields/amount.html

Lines changed: 6 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -89,9 +89,9 @@
8989

9090
// Detect any amount change and format as valid number
9191
$('#amount').change(function(e){
92-
// Handle updating tx size as token name changes
93-
if(type=='dividend'||type=='burn'||type=='send')
94-
updateTransactionSize();
92+
// Handle doing pre-flight check for sends to determine if this is a send or a dispense
93+
if(type=='send')
94+
checkDestinationForDispenser();
9595
var amt = String($(this).val()).replace(/[^0-9.]/g,''),
9696
val = $('#available').val(),
9797
fmt = (FW.ASSET_INFO.divisible) ? '0,0.00000000' : '0,0',
@@ -121,6 +121,9 @@
121121
}
122122
$(this).val(numeral(amt).format(fmt));
123123
updateSendValue(amt);
124+
// Handle updating tx size as token amount changes
125+
if(type=='dividend'||type=='burn'||type=='send'||type=='mint-supply'||type=='dispenser-buy')
126+
updateTransactionSize();
124127
});
125128

126129
// Calculate the fiat value as the user types the amount

html/fields/send-list.html

Lines changed: 9 additions & 16 deletions
Original file line numberDiff line numberDiff line change
@@ -35,7 +35,7 @@
3535
address = String(info[0]).trim(),
3636
asset = (info[1]) ? String(info[1]).trim() : '',
3737
quantity = (info[2]) ? String(info[2]).trim() : '',
38-
memo = (info[3]) ? String(info[3]).trim().replace(/^"|"$/g,'') : '';
38+
memo = (info[3]) ? String(info[3]).trim().replace(/^"|"$/g,'') : '';
3939
// Re-assemble any memos which have commas
4040
if(memo!='')
4141
memo = String(info.slice(3,info.length).join(',')).trim().replace(/^"|"$/g,'');
@@ -75,31 +75,24 @@
7575
if(address==FW.WALLET_ADDRESS)
7676
errors.push('Source address cannot be in send destination list!');
7777

78-
79-
//Second tx size estimation
80-
let addressInList = addressesList.includes(address)
81-
let addressSize = (addressInList?8:21) //21 bytes for the address without checksum and 8 bytes for the integer that represents the index of the address
82-
if (!addressInList){addressesList.push(address)}
83-
78+
// tx size estimation
79+
let addressInList = addressesList.includes(address);
80+
let addressSize = (addressInList?8:21); //21 bytes for the address without checksum and 8 bytes for the integer that represents the index of the address
81+
if (!addressInList){ addressesList.push(address); }
8482
let assetInList = assetsList.includes(asset)
8583
let assetSize = (assetInList?0:(new TextEncoder().encode(asset).length))// assets only appear once in the mpma pack
86-
if (!assetInList){assetsList.push(asset)}
87-
88-
if (memo != ""){
89-
memoAdditionalBits = memoAdditionalBits + 2 //1 bit to signal the memo and 1 bit to tell if the memo is in hex format or not
90-
}
91-
84+
if (!assetInList){ assetsList.push(asset); }
9285
estimatedMultiSendSizeData = estimatedMultiSendSizeData +
9386
addressSize + //Address size in the mpma pack
9487
assetSize + //Asset size in the mpma pack
95-
8 + //quantity in bytes
96-
(new TextEncoder().encode(memo).length)//memo size in bytes
88+
8; //quantity in bytes
9789
});
90+
// memo size in bytes
91+
estimatedMultiSendSizeData = estimatedMultiSendSizeData +(new TextEncoder().encode(memo).length);
9892
if (memoAdditionalBits > 0){
9993
estimatedMultiSendSizeData = estimatedMultiSendSizeData + Math.ceil(memoAdditionalBits/8)
10094
}
10195

102-
10396
// Display any error message
10497
if(errors.length){
10598
dialogMessage('<i class="fa fa-lg fa-fw fa-exclamation-circle"></i> Error(s)', errors.join('<br/>') );

0 commit comments

Comments
 (0)