From d8068565d96577d5fe1e5a7c8379de24de66b334 Mon Sep 17 00:00:00 2001 From: Yudai Takada <13041216+ydah@users.noreply.github.com> Date: Thu, 9 Jun 2022 02:28:01 +0900 Subject: [PATCH] Improve some wording and correct some typos (#1336) * Unification of words "behaviour" -> "behavior" * Unify format - `a`, `b`, `c` -> `A`, `B`, `C` - D -> `D` * Fix typo "againt" -> "against" * Fix typo "Passanger" -> "Passenger" * Fix typo "qeury" -> "query" --- docs/docs/getting-started/simple-mode.md | 2 +- docs/docs/going-further/acts-as-taggable-on.md | 8 ++++---- docs/docs/going-further/i18n.md | 2 +- spec/ransack/predicate_spec.rb | 2 +- 4 files changed, 7 insertions(+), 7 deletions(-) diff --git a/docs/docs/getting-started/simple-mode.md b/docs/docs/getting-started/simple-mode.md index dfd6baa..336d69e 100644 --- a/docs/docs/getting-started/simple-mode.md +++ b/docs/docs/getting-started/simple-mode.md @@ -50,7 +50,7 @@ This may be disabled by setting the `strip_whitespace` option in a Ransack initi ```ruby Ransack.configure do |c| - # Change whitespace stripping behaviour. + # Change whitespace stripping behavior. # Default is true c.strip_whitespace = false end diff --git a/docs/docs/going-further/acts-as-taggable-on.md b/docs/docs/going-further/acts-as-taggable-on.md index 97ba5fe..546a999 100644 --- a/docs/docs/going-further/acts-as-taggable-on.md +++ b/docs/docs/going-further/acts-as-taggable-on.md @@ -67,24 +67,24 @@ When you're writing a `Ransack` search form, you can choose any of the following ### Option A - Match keys exactly -Option `a` will match keys exactly. This is the solution to choose if you want to distinguish 'Home' from 'Homework': searching for 'Home' will return just the `Task` with id 1. It also allows searching for more than one tag at once (comma separated): +Option `A` will match keys exactly. This is the solution to choose if you want to distinguish 'Home' from 'Homework': searching for 'Home' will return just the `Task` with id 1. It also allows searching for more than one tag at once (comma separated): - `Home, Personal` will return task 1 - `Home, Homework` will return task 1 and 2 ### Option B - match key combinations -Option `b` will match all keys exactly. This is the solution if you wanna search for specific combinations of tags: +Option `B` will match all keys exactly. This is the solution if you wanna search for specific combinations of tags: - `Home` will return nothing, as there is no Task with just the `Home` tag - `Home, Personal` will return task 1 ### Option C - match substrings -Option `c` is used to match substrings. This is useful when you don't care for the exact tag, but only for part of it: +Option `C` is used to match substrings. This is useful when you don't care for the exact tag, but only for part of it: - `Home` will return task 1 and 2 (`/Home/` matches both `"Home"` and `"Homework"`) ### Option D - select from a list of tags -In Option D we allow the user to select a list of valid tags and then search againt them. We use the plural name here. +In Option `D` we allow the user to select a list of valid tags and then search against them. We use the plural name here. ```erb
diff --git a/docs/docs/going-further/i18n.md b/docs/docs/going-further/i18n.md index bee4b8c..7e61ab6 100644 --- a/docs/docs/going-further/i18n.md +++ b/docs/docs/going-further/i18n.md @@ -27,7 +27,7 @@ en: gt: greater than lt: less than models: - person: Passanger + person: Passenger attributes: person: name: Full Name diff --git a/spec/ransack/predicate_spec.rb b/spec/ransack/predicate_spec.rb index ce58391..8d2530a 100644 --- a/spec/ransack/predicate_spec.rb +++ b/spec/ransack/predicate_spec.rb @@ -368,7 +368,7 @@ module Ransack expect(@s.result.to_sql).to match /#{field} IS NULL/ end - describe 'with association qeury' do + describe 'with association query' do it 'generates a value IS NOT NULL query' do @s.comments_id_not_null = true sql = @s.result.to_sql