From 17952c9cf39cc60a28538f067143f740855cacaf Mon Sep 17 00:00:00 2001 From: Sunil Mohan Adapa Date: Fri, 4 Oct 2024 20:30:17 -0700 Subject: [PATCH] firstboot: Improve the setup complete page with more setups Fixes: #888. - Suggest all the steps that a typical user should likely take. - Custom styling to make the page look good. - Open the links in new windows as this page can't be reached again. - Add a button for software updates as this can be done easily and the most important step. Tests: - Trigger first setup by removing plinth.sqlite3. Notice the improved setup complete page. Text and icons are as expected. Links work and open in a new window. Clicking on 'Update now' button opens a page to software updates with manual upgrade triggered. - Mobile view looks good. Signed-off-by: Sunil Mohan Adapa Reviewed-by: Veiko Aasa --- .../templates/firstboot_complete.html | 90 +++++++++++++++---- static/themes/default/css/main.css | 23 +++++ 2 files changed, 94 insertions(+), 19 deletions(-) diff --git a/plinth/modules/first_boot/templates/firstboot_complete.html b/plinth/modules/first_boot/templates/firstboot_complete.html index d0323dd75..b931395dc 100644 --- a/plinth/modules/first_boot/templates/firstboot_complete.html +++ b/plinth/modules/first_boot/templates/firstboot_complete.html @@ -8,27 +8,79 @@ {% block content %} -

{% trans "Setup Complete!" %}

+

{% trans "Setup Complete! Next Steps:" %}

-

- {% blocktrans trimmed %} - Without any apps, your {{ box_name }} cannot do very much. - {% endblocktrans %} -

+
    +
  1. +
    +
    + {% url 'upgrades:index' as upgrades_url %} + {% blocktrans trimmed %} + Automatic software + update runs daily by default. For the first time, manually run + it now. + {% endblocktrans %} +
    + {% csrf_token %} + +
    +
    +
  2. - +
  3. +
    +
    + {% url 'privacy:index' as privacy_url %} + {% blocktrans trimmed %} + Review privacy options. + {% endblocktrans %} +
    +
  4. -

    -

    - {% url 'networks:index' as networks_url %} - {% blocktrans trimmed %} - You may want to check the network - setup and modify it if necessary. - {% endblocktrans %} -

    -

    +
  5. +
    +
    + {% url 'networks:index' as networks_url %} + {% blocktrans trimmed %} + Review and setup network + connections. Change the default Wi-Fi password, if applicable. + {% endblocktrans %} +
    +
  6. + +
  7. +
    +
    + {% url 'names:index' as names_url %} + {% blocktrans trimmed %} + Configure a domain name. + {% endblocktrans %} +
    +
  8. + +
  9. +
    +
    + {% url 'backups:index' as backups_url %} + {% blocktrans trimmed %} + Configure and schedule remote + backups. + {% endblocktrans %} +
    +
  10. + +
  11. +
    +
    + {% url 'apps' as apps_url %} + {% blocktrans trimmed %} + Put {{ box_name }} to use by installing + apps. + {% endblocktrans %} +
    +
  12. + {% endblock %} diff --git a/static/themes/default/css/main.css b/static/themes/default/css/main.css index 5492689f8..b8aecfe08 100644 --- a/static/themes/default/css/main.css +++ b/static/themes/default/css/main.css @@ -636,6 +636,29 @@ a.menu_link_active { width: 50%; } +.next-steps { + list-style: none; + margin-top: 1.5rem; + padding: 0; +} + +.next-steps li { + display: flex; + align-items: center; + padding: 0.75rem 0; +} + +.next-steps .app-icon { + font-size: 3rem; + margin-right: 1rem; + width: 3rem; + text-align: center; +} + +.next-steps form { + display: inline; +} + /* * Toggle button */