From b786bf24e0c0aa6d49da67c8bbec3e42ed5faf06 Mon Sep 17 00:00:00 2001 From: Andy Smith Date: Wed, 11 Feb 2026 16:36:09 -0600 Subject: [PATCH 1/2] Clarify importing accounts --- app/assets/stylesheets/import.css | 33 +++++++++++++++++++++++++ app/assets/stylesheets/utilities.css | 1 + app/views/account/imports/new.html.erb | 14 ++++++++--- app/views/account/imports/show.html.erb | 32 ++++++++++++++---------- 4 files changed, 63 insertions(+), 17 deletions(-) create mode 100644 app/assets/stylesheets/import.css diff --git a/app/assets/stylesheets/import.css b/app/assets/stylesheets/import.css new file mode 100644 index 000000000..5ab6b2cc5 --- /dev/null +++ b/app/assets/stylesheets/import.css @@ -0,0 +1,33 @@ +@layer components { + .import-status { + --import-status-border-color: var(--color-ink-light); + --import-status-color: var(--color-ink); + + border: 1px dashed var(--import-status-border-color); + border-radius: 1ch; + color: var(--import-status-color); + font-size: var(--text-medium); + padding: 1.5ch; + + .btn { + font-size: var(--text-small); + margin-block-start: 1.5ch; + } + } + + .import-status--success { + --import-status-border-color: var(--color-positive); + --import-status-color: var(--color-positive); + } + + .import-status--error { + --import-status-border-color: var(--color-negative); + --import-status-color: var(--color-negative); + } + + @keyframes dash { + to { + background-position: 100% 0%, 0% 100%, 0% 0%, 100% 100%; + } + } +} diff --git a/app/assets/stylesheets/utilities.css b/app/assets/stylesheets/utilities.css index 76dedfe12..53837034c 100644 --- a/app/assets/stylesheets/utilities.css +++ b/app/assets/stylesheets/utilities.css @@ -32,6 +32,7 @@ .txt-link { color: var(--color-link); text-decoration: underline; } .font-weight-normal { font-weight: normal; } + .font-weight-semibold { font-weight: 600; } .font-weight-bold { font-weight: bold; } .font-weight-black { font-weight: 900; } diff --git a/app/views/account/imports/new.html.erb b/app/views/account/imports/new.html.erb index fd837a7b6..ab6af3a51 100644 --- a/app/views/account/imports/new.html.erb +++ b/app/views/account/imports/new.html.erb @@ -1,9 +1,15 @@ <% @page_title = "Import an account" %> - -
+
-

Import a Fizzy account

-
Create an account using data from a Fizzy export. Upload the exported .zip file below.
+

Import a Fizzy account

+ + <% if Fizzy.saas? %> +
Move a self-hosted account to fizzy.do
+
Export your self-hosted account, then upload the .zip file below.
+ <% else %> +
Move an account from fizzy.do to a self-hosted instance
+
Export your fizzy.do account, then upload the .zip file below.
+ <% end %>
<%= form_with url: account_imports_path, class: "flex flex-column gap", data: { controller: "form upload-preview" }, multipart: true do |form| %> diff --git a/app/views/account/imports/show.html.erb b/app/views/account/imports/show.html.erb index a6d966059..44d9228e6 100644 --- a/app/views/account/imports/show.html.erb +++ b/app/views/account/imports/show.html.erb @@ -2,25 +2,31 @@ <%= turbo_stream_from @import %> -
+

Import status

<% case @import.status %> <% when "pending", "processing" %> -

Your import is in progress. This may take a while for large accounts.

+
+ Your import is in progress. This may take a while for large accounts. +
<% when "completed" %> -

Your import has completed successfully!

- <%= link_to "Go to your account", landing_url(script_name: @import.account.slug), class: "btn btn--link center txt-medium" %> +
+
Your import was successfull!
+ <%= link_to "Go to your account →", landing_url(script_name: @import.account.slug), class: "btn btn--link" %> +
<% when "failed" %> -

Your import failed.

- <% if @import.failed_due_to_conflict? %> -

It looks like the account you are trying to import already exists.

- <% elsif @import.failed_due_to_invalid_export? %> -

The ZIP file isn't a Fizzy account export.

- <% else %> -

This may be due to corrupted export data or a conflict with existing data. Please try again with a fresh export.

- <% end %> - <%= link_to "Try again", new_account_import_path, class: "btn btn--plain center txt-medium" %> +
+
Import failed
+ <% if @import.failed_due_to_conflict? %> +
The account you‘re trying to import already exists. Make sure you‘re importing a <%= Fizzy.saas? ? "self-hosted" : "fizzy.do" %> account.
+ <% elsif @import.failed_due_to_invalid_export? %> +
The .zip file you uploaded doesn‘t look like a Fizzy account export.
+ <% else %> +
This may be due to corrupted export data or a conflict with existing data. Please try again with a fresh export.
+ <% end %> + <%= link_to "Try again", new_account_import_path, class: "btn" %> +
<% end %>
From d7814792e3c2a8dffe9ed3c10aea8fd5f1a8d588 Mon Sep 17 00:00:00 2001 From: Andy Smith Date: Fri, 13 Feb 2026 15:17:33 -0600 Subject: [PATCH 2/2] Tweak language --- app/views/account/imports/new.html.erb | 8 +++++--- 1 file changed, 5 insertions(+), 3 deletions(-) diff --git a/app/views/account/imports/new.html.erb b/app/views/account/imports/new.html.erb index ab6af3a51..b4e12e94b 100644 --- a/app/views/account/imports/new.html.erb +++ b/app/views/account/imports/new.html.erb @@ -4,11 +4,11 @@

Import a Fizzy account

<% if Fizzy.saas? %> -
Move a self-hosted account to fizzy.do
+
Running Fizzy on your own server and want us to host on fizzy.do instead?
Export your self-hosted account, then upload the .zip file below.
<% else %> -
Move an account from fizzy.do to a self-hosted instance
-
Export your fizzy.do account, then upload the .zip file below.
+
Ready to host Fizzy on your own server?
+
Export your fizzy.do account, then upload the .zip file below.
<% end %> @@ -23,6 +23,8 @@ Start Import → <% end %> + +

If you run into issues or would like assistance, just send us an email.

<% content_for :footer do %>