tick_checkboxes template for spectrum (delete whitepaper) + correct connection urls

This commit is contained in:
moneymanolis 2023-02-21 20:04:11 +01:00
parent 8787fb0d4f
commit 8e685192af
4 changed files with 97 additions and 4 deletions

View file

@ -1,4 +1,4 @@
<h2 class="mt-8 mb-2">{{ _('Getting Started') }}</h2>
<h2 class="mt-8 mb-2">{{ _('Getting Started with Bitcoin Core') }}</h2>
<table class="mb-10">
<tbody>
@ -7,8 +7,8 @@
<img class="h-6 w-6" src="{{ url_for('static', filename='img/checkbox-' + ('un' if not specter.chain else '') + 'tick.svg') }}">
</td>
<td>
<a href="{{ url_for('setup_endpoint.node_type') }}">
<p>{{ _("Connect to the bitcoin network") }}</p>
<a href="{{ url_for('nodes_endpoint.node_settings')}}">
<p>{{ _("Connect to the Bitcoin network") }}</p>
</a>
</td>
<td>

View file

@ -160,4 +160,8 @@ class SpectrumService(Service):
view_model.get_started_include = (
"spectrum/welcome/components/get_started.jinja"
)
if self.is_spectrum_node_available:
view_model.tick_checkboxes_include = (
"spectrum/welcome/components/tick_checkboxes.jinja"
)
return view_model

View file

@ -15,7 +15,7 @@
<div class="flex px-3 cursor-pointer space-x-2 items-center">
<svg class="w-7 h-7 text-white opacity-20" version="1.1" viewBox="0 0 64 64" xmlns="http://www.w3.org/2000/svg" xmlns:xlink="http://www.w3.org/1999/xlink"><!--Generated by IJSVG (https://github.com/iconjar/IJSVG)--><path d="M54.5946,27.4366l5.66603e-08,-5.66066e-08c-0.745305,0.744598 -1.9414,0.780481 -2.73,0.0819001l1.11948e-07,9.86842e-08c-11.3381,-9.99478 -28.3408,-9.99478 -39.6789,-1.97368e-07l4.1375e-08,-3.6659e-08c-0.788564,0.698682 -1.98474,0.662797 -2.73,-0.0818999l-2.831,-2.8295l4.78383e-08,4.78239e-08c-0.782846,-0.782609 -0.783038,-2.05166 -0.000429116,-2.83451c0.0255969,-0.0256047 0.0518829,-0.0505111 0.078829,-0.0746918l-1.08875e-06,9.72979e-07c14.4215,-12.888 36.2226,-12.888 50.6441,-1.94596e-06l-4.18137e-09,-3.75185e-09c0.823858,0.73923 0.892463,2.00636 0.153233,2.83022c-0.0242251,0.0269984 -0.0491787,0.0533343 -0.0748332,0.0789783Zm-17.6311,13.896l1.74829e-07,9.87123e-08c1.00267,0.56613 1.35656,1.8379 0.79043,2.84057c-0.0942659,0.166954 -0.21111,0.320108 -0.34723,0.45513l-3.6928,3.6684l2.2751e-08,-2.25368e-08c-0.943884,0.934995 -2.46482,0.934995 -3.4087,4.50735e-08l-3.6928,-3.6684l-6.02819e-08,-5.98007e-08c-0.8175,-0.810974 -0.82279,-2.13111 -0.0118161,-2.94861c0.134967,-0.136053 0.288047,-0.252849 0.454916,-0.347088l2.96297e-07,-1.66902e-07c3.07549,-1.7324 6.83251,-1.7324 9.908,3.33805e-07Zm-14.8508,-3.792l3.86385e-08,-3.1954e-08c-0.835403,0.690877 -2.05882,0.634623 -2.8273,-0.13l-2.3847,-2.4084c-1.1739,-1.1855 -1.14,-2.6381 -0.1975,-3.4266l9.62086e-07,-8.05987e-07c8.84671,-7.41133 21.7347,-7.41133 30.5814,1.61198e-06l-5.08261e-08,-4.40698e-08c0.88879,0.770643 0.984568,2.11588 0.213926,3.00467c-0.0332999,0.0384052 -0.0679639,0.075606 -0.103925,0.111531l-2.6883,2.7151l2.63897e-08,-2.62774e-08c-0.768944,0.765671 -1.99317,0.823532 -2.8309,0.1338l-1.43462e-07,-1.17058e-07c-5.75168,-4.69307 -14.0109,-4.69307 -19.7626,2.34116e-07Z" fill="currentColor" fill-rule="evenodd"></path></svg>
<a id="no-node-connection" href="{{url_for('spectrum_endpoint.index')}}">
<div class="text-lg" data-cy="no-spectrum-connection">{{ _("Spectrum Disconnected") }}</div>
<div class="text-lg" data-cy="no-spectrum-connection">{{ _("Disconnected") }}</div>
</a>
</div>
{% endif%}

View file

@ -0,0 +1,89 @@
<h2 class="mt-8 mb-2">{{ _('Getting Started with Spectrum') }}</h2>
<table class="mb-10">
<tbody>
<tr>
<td class="w-12">
<img class="h-6 w-6" src="{{ url_for('static', filename='img/checkbox-' + ('un' if not specter.chain else '') + 'tick.svg') }}">
</td>
<td>
<a href="{{ url_for('spectrum_endpoint.index') }}">
<p>{{ _("Connect to the Bitcoin network") }}</p>
</a>
</td>
<td>
{% if not specter.chain %}
<button type="button" onclick="showPageOverlay('connect-node-help-popup')">Need help?</button>
<div id="connect-node-help-popup" class="hidden">
<h1>{{ _("Connecting Specter to your Bitcoin Core node") }}</h1>
<div>
<button data-style="padding: 10px; width: 80%; font-size: 1.2em; margin: 20px auto;" type="button" class="btn" onclick="hidePageOverlay();showPageOverlay('no-node-help-popup')">{{ _("I don't have a Bitcoin Core node yet.") }}</button>
<button data-style="padding: 10px; width: 80%; font-size: 1.2em; margin: 20px auto;" type="button" class="btn" onclick="hidePageOverlay();showPageOverlay('local-node-help-popup')">{{ _("I have Bitcoin Core on this computer.") }}</button>
<button data-style="padding: 10px; width: 80%; font-size: 1.2em; margin: 20px auto;" type="button" class="btn" onclick="hidePageOverlay();showPageOverlay('remote-node-help-popup')">{{ _("I have a remote Bitcoin Core node.") }}</button>
</div>
</div>
<div id="no-node-help-popup" class="hidden">
<h1>{{ _("Installing and Setting Up Bitcoin Core") }}</h1>
{{ _("Check out these video tutorials on downloading and setting up Bitcoin Core with Specter Desktop") }}:<br><br>
<ul data-style="text-align: left; margin: auto; line-height: 2;">
<li><a href="https://www.keepitsimplebitcoin.com/setup-bitcoin-core/" target="_blank" data-style="color: #fff;">KIS: Setting up Bitcoin Core</a></li>
<li><a href="https://www.keepitsimplebitcoin.com/how-to-use-specter-wallet-1/" target="_blank" data-style="color: #fff;">KIS: Setting up Specter Desktop</a></li>
<li><a href="https://www.youtube.com/watch?v=4koKF2MDXtk&t=2s" target="_blank" data-style="color: #fff;">Ministry of Nodes: Setting up Bitcoin Core and Specter on Windows</a></li>
</ul>
</div>
<div id="local-node-help-popup" class="hidden">
<h1>{{ _('Connecting Specter to your local Bitcoin Core node') }}</h1>
<p>{{ _("If you're running a local Bitcoin Core node, Specter should be able to auto-detect it if its data folder is located at the default location.") }}<br>
{{ _("In case it isn't, you might need to specify the Bitcoin Core data folder path in Specter's settings page.") }}<br>
{{ _("Alternatively, you can switch off auto-detect from the settings and provide the Bitcoin Core RPC credentials and host URL manually.") }}<br><br>
<b>{{ _("Please note:")}}</b><br>{{ _('Your node must be configured with ')}}<code>server=1</code>{{ _(' line in the ')}}<code>bitcoin.conf</code>{{ _(' file.')}}<br>
{{ _("If you don't have that, add it and restart Bitcoin Core.") }}"
</p>
<br><br>
{{ _("In addition, you can check out these video tutorials for setting up Bitcoin Core with Specter Desktop") }}:<br><br>
<ul data-style="text-align: left; margin: auto; line-height: 2;">
<li><a href="https://www.keepitsimplebitcoin.com/setup-bitcoin-core/" target="_blank" data-style="color: #fff;">KIS: Setting up Bitcoin Core</a></li>
<li><a href="https://www.keepitsimplebitcoin.com/how-to-use-specter-wallet-1/" target="_blank" data-style="color: #fff;">KIS: Setting up Specter Desktop</a></li>
<li><a href="https://www.youtube.com/watch?v=4koKF2MDXtk&t=2s" target="_blank" data-style="color: #fff;">Ministry of Nodes: Setting up Bitcoin Core and Specter on Windows</a></li>
</ul>
</div>
<div id="remote-node-help-popup" class="hidden">
<h1>{{ _("Connecting Specter to your remote Bitcoin Core node") }}</h1>
<h3>{{ _('Connecting to a "node in a box"') }}</h3>
<p data-style="font-size: 1.05em;">
{{ _("Specter can be used with a remote Bitcoin Core node running on a machine like RaspiBlitz, myNode, Nodl, Umbrel, and Embassy.") }}<br>
{{ _("RaspiBlitz and myNode currently allow running Specter in the remote machine directly, which means it's possible to use it and skip setting up connection manually.") }}<br><br>
{{ _("If you use a different node or would still like to connect run Specter locally but connect remotely, you can do so by going to Settings, Bitcoin Core tab, and provide the Bitcoin Core RPC credentials and host URL manually.") }}"
</p>
<h3>{{ _("Connecting over Tor") }}</h3>
<p data-style="font-size: 1.05em;">{{ _("Connecting over Tor requires that you first configure Tor on your local machine.") }}<br>
You can checkout <a href="https://www.keepitsimplebitcoin.com/how-to-install-tor/" data-style="color: #fff;" target="_blank">this video tutorial</a>, or read the documentation for <a href="https://github.com/cryptoadvance/specter-desktop/blob/master/docs/tor.md" target="_blank" data-style="color: #fff;">Mac and Linux</a> or <a href="https://github.com/Fonta1n3/FullyNoded/blob/master/Docs/Tor/Tor.md#windows-10" target="_blank" data-style="color: #fff;">Window</a><br>
</p>
</div>
{% endif %}
</td>
</tr>
<tr>
<td class="w-12">
<img class="h-6 w-6" src="{{ url_for('static', filename='img/checkbox-' + ('un' if not (specter.device_manager.devices | length) else '') + 'tick.svg') }}">
</td>
<td>
<a href="{{ url_for('devices_endpoint.new_device_type') }}">
<p>{{ _("Add your signing devices") }}</p>
</a>
</td>
<td></td>
</tr>
<tr>
<td class="w-12">
<img class="h-6 w-6" src="{{ url_for('static', filename='img/checkbox-' + ('un' if not (specter.wallet_manager.wallets | length) else '') + 'tick.svg') }}">
</td>
<td>
<a href="{{ url_for('wallets_endpoint.new_wallet_type') }}">
<p>{{ _("Create your first wallet") }}</p>
</a>
</td>
<td></td>
</tr>
</tbody>
</table>