mirror of
https://github.com/indentlabs/notebook.git
synced 2025-10-26 11:19:22 +00:00
minor qa polish
This commit is contained in:
parent
6e5ce5b935
commit
193c1a5bf3
@ -57,4 +57,8 @@ class Timeline < ApplicationRecord
|
||||
def initialize_first_event
|
||||
timeline_events.create(title: "Untitled Event", position: 1)
|
||||
end
|
||||
|
||||
def cached_word_count
|
||||
0 # until we implement it :)
|
||||
end
|
||||
end
|
||||
|
||||
@ -411,7 +411,7 @@
|
||||
</h2>
|
||||
|
||||
<p class="mt-4 text-xs tracking-wider font-bold text-gray-500">
|
||||
Showing <%= pluralize content.count, 'pages' %>
|
||||
Showing <%= pluralize content.count, 'page' %>
|
||||
</p>
|
||||
<ul class="mt-1 text-gray-600">
|
||||
<% content_counts_per_type.each do |content_type, count| %>
|
||||
@ -532,7 +532,7 @@
|
||||
|
||||
<div class="inline-block mr-4">
|
||||
<i class="material-icons float-left mr-1 <%= DocumentAnalysis.text_color %>">spellcheck</i>
|
||||
<% total_word_count = content.map(&:cached_word_count).sum %>
|
||||
<% total_word_count = content.map(&:cached_word_count).reject(&:nil?).sum %>
|
||||
<span class="text-sm">
|
||||
<strong class="font-bold text-gray-700"><%= number_with_delimiter total_word_count %></strong>
|
||||
<%= 'total word'.pluralize(total_word_count) %>
|
||||
|
||||
Loading…
Reference in New Issue
Block a user