diff --git a/Gemfile.lock b/Gemfile.lock index 116c5edd..223dfabb 100644 --- a/Gemfile.lock +++ b/Gemfile.lock @@ -1295,7 +1295,7 @@ GEM execjs coffee-script-source (1.12.2) concurrent-ruby (1.1.10) - connection_pool (2.2.5) + connection_pool (2.3.0) crass (1.0.6) csv (3.2.5) d3-rails (5.9.2) @@ -1555,9 +1555,9 @@ GEM railties (>= 3.2) tilt redcarpet (3.5.1) - redis (5.0.2) - redis-client (~> 0.7) - redis-client (0.7.3) + redis (5.0.5) + redis-client (>= 0.9.0) + redis-client (0.10.0) connection_pool remotipart (1.4.4) responders (3.0.1) @@ -1593,10 +1593,10 @@ GEM rubyzip (>= 1.2.2, < 3.0) websocket (~> 1.0) semantic_range (3.0.0) - sidekiq (6.5.6) - connection_pool (>= 2.2.5) + sidekiq (6.5.5) + connection_pool (>= 2.2.2) rack (~> 2.0) - redis (>= 4.5.0, < 5) + redis (>= 4.5.0) simplecov (0.13.0) docile (~> 1.1.0) json (>= 1.8, < 3) diff --git a/app/controllers/subscriptions_controller.rb b/app/controllers/subscriptions_controller.rb index 5887c081..2edb0063 100644 --- a/app/controllers/subscriptions_controller.rb +++ b/app/controllers/subscriptions_controller.rb @@ -1,7 +1,7 @@ class SubscriptionsController < ApplicationController protect_from_forgery except: :stripe_webhook - before_action :authenticate_user!, except: [:redeem] + before_action :authenticate_user!, except: [:redeem, :faq] before_action :set_navbar_actions, except: [:redeem, :prepay_paid] before_action :set_sidenav_expansion, except: [:redeem, :prepay_paid] @@ -231,6 +231,9 @@ class SubscriptionsController < ApplicationController redirect_back(fallback_location: subscription_path, notice: "Promo code successfully activated!") end + def faq + end + private def move_user_to_plan_requested(plan_id) @@ -264,12 +267,18 @@ class SubscriptionsController < ApplicationController end def set_navbar_actions - @navbar_actions = [{ - label: "Your plan", - href: main_app.subscription_path - }, { - label: "Billing history", - href: main_app.billing_history_path - }] + if user_signed_in? + @navbar_actions = [{ + label: "Your plan", + href: main_app.subscription_path + }, { + label: "Billing history", + href: main_app.billing_history_path + }, + { + label: 'Billing FAQ', + href: main_app.billing_faq_path + }] + end end end diff --git a/app/helpers/marketing_helper.rb b/app/helpers/marketing_helper.rb new file mode 100644 index 00000000..ad4a3551 --- /dev/null +++ b/app/helpers/marketing_helper.rb @@ -0,0 +1,7 @@ +module MarketingHelper + def linked_page_type(text:, page_type:) + content_tag(:a, href: send("#{page_type.name.downcase}_worldbuilding_info_path"), class: page_type.text_color) do + content_tag(:strong, text) + end + end +end diff --git a/app/javascript/components/Footer.js b/app/javascript/components/Footer.js index 012fad14..49d066f3 100644 --- a/app/javascript/components/Footer.js +++ b/app/javascript/components/Footer.js @@ -19,6 +19,10 @@ class Footer extends React.Component { GitHub +  ·  + + Discord + diff --git a/app/views/subscriptions/faq.html.erb b/app/views/subscriptions/faq.html.erb new file mode 100644 index 00000000..cc71ea76 --- /dev/null +++ b/app/views/subscriptions/faq.html.erb @@ -0,0 +1,285 @@ +

Frequently-asked questions about billing on Notebook.ai

+ + + +

Have a question that wasn't answered here?

+

+ Feel free to reach out to me any time at andrew@indentlabs.com + or post on the <%= link_to 'Site Support', 'https://www.notebook.ai/forum/site-support' %> + discussion board. I'm constantly working to make the site better and I'm always happy + to help! +

diff --git a/app/views/subscriptions/new.html.erb b/app/views/subscriptions/new.html.erb index 065d2a9e..0cc66bbb 100644 --- a/app/views/subscriptions/new.html.erb +++ b/app/views/subscriptions/new.html.erb @@ -39,6 +39,8 @@ You will be charged <%= number_to_currency(@active_billing_plan.monthly_cents / 100) %> on the <%= renewal_day %><%= renewal_day.ordinal %> of each month. <% end %> + + Click <%= link_to 'here', billing_faq_path %> to view our cancellation policy and other frequently-asked questions. <% end %> <% end %>

diff --git a/config/routes.rb b/config/routes.rb index 9c700f39..1ca33c31 100644 --- a/config/routes.rb +++ b/config/routes.rb @@ -179,8 +179,9 @@ Rails.application.routes.draw do # Info pages scope '/about' do - get '/paper', to: 'main#paper', as: :green_paper - get '/privacy', to: 'main#privacyinfo', as: :privacy_policy + get '/paper', to: 'main#paper', as: :green_paper + get '/privacy', to: 'main#privacyinfo', as: :privacy_policy + get '/billing/faq', to: 'subscriptions#faq' end # Landing pages diff --git a/public/503.html b/public/503.html index ac5afd2d..26c49cf6 100644 --- a/public/503.html +++ b/public/503.html @@ -2,7 +2,7 @@ - Notebook | Server Error + Maintenance Mode @@ -58,7 +58,7 @@ } .error { - font-size: 9rem; + font-size: 6rem; font-weight: bold; padding: 0 4rem; border-right: 1px solid #707980; @@ -82,6 +82,13 @@ margin-bottom: 1rem; } + .maintenance-description { + color: #707980; + font-weight: 100; + font-size: 1.2rem; + margin-bottom: 1rem; + } + a { display: inline-block; padding: 0.7rem 2rem; @@ -131,14 +138,24 @@
-
503
+
+ Maintenance +
We'll be right back
- We're working on servers under scheduled maintenance and will be back shortly.
- Thank you for your patience! + We're updating the servers to prepare for National Novel Writing Month
+ and will be back shortly. Thank you for your patience! +
+
+ Expected maintenance window: 9:20pm PST — 10:00pm PST +
+