From 4c62ab1735e759464b917a916369fd2296bbac4e Mon Sep 17 00:00:00 2001 From: Paul Bob <69730720+Paul-Bob@users.noreply.github.com> Date: Thu, 29 Feb 2024 12:42:45 +0200 Subject: [PATCH 1/4] fix: rename instantclick to instant_click (#178) --- docs/3.0/customization.md | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/docs/3.0/customization.md b/docs/3.0/customization.md index b03484e4..423fce2f 100644 --- a/docs/3.0/customization.md +++ b/docs/3.0/customization.md @@ -533,7 +533,7 @@ Supported options with default values: ```ruby config.turbo = -> do { - instantclick: true + instant_click: true } end ``` From b92a115c2187927ae260a0e0b39d5d8a197116b0 Mon Sep 17 00:00:00 2001 From: Paul Bob Date: Thu, 29 Feb 2024 20:28:58 +0200 Subject: [PATCH 2/4] record is nil on header evaluation --- docs/3.0/upgrade.md | 8 ++++++++ 1 file changed, 8 insertions(+) diff --git a/docs/3.0/upgrade.md b/docs/3.0/upgrade.md index 1dbc96dd..97ad2da2 100644 --- a/docs/3.0/upgrade.md +++ b/docs/3.0/upgrade.md @@ -73,6 +73,14 @@ field :name, end ::: +:::option `resource.record` or `record` as `nil` on visibility blocks +You may notice that `resource.record == nil` on some visibility blocks. That happens when evaluating the field visibility to render header columns. On index, there is no record. + +This is a consequence of a bug fix where `resource.record` was wrongly storing the last record of the index table. + +Check [this discussion](https://github.com/avo-hq/avo/issues/2544) for a more details +::: + ## Upgrade from 3.3.0 to 3.4.0 Ruby 3.0 is end-of-life and we pushed some code that only works with Ruby 3.1. From ece6b4cf580ee73468d0c6495af45f9b0dc2fc54 Mon Sep 17 00:00:00 2001 From: Paul Bob Date: Thu, 29 Feb 2024 21:19:51 +0200 Subject: [PATCH 3/4] syntax --- docs/3.0/upgrade.md | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/docs/3.0/upgrade.md b/docs/3.0/upgrade.md index 97ad2da2..2b6a9165 100644 --- a/docs/3.0/upgrade.md +++ b/docs/3.0/upgrade.md @@ -78,7 +78,7 @@ You may notice that `resource.record == nil` on some visibility blocks. That hap This is a consequence of a bug fix where `resource.record` was wrongly storing the last record of the index table. -Check [this discussion](https://github.com/avo-hq/avo/issues/2544) for a more details +Check [this discussion](https://github.com/avo-hq/avo/issues/2544) for more details ::: ## Upgrade from 3.3.0 to 3.4.0 From e243536cb456b4efa88d7b7c6623deb44f79524e Mon Sep 17 00:00:00 2001 From: Paul Bob Date: Fri, 1 Mar 2024 13:18:08 +0200 Subject: [PATCH 4/4] instant_click update --- docs/3.0/customization.md | 10 +++++++++- docs/3.0/upgrade.md | 11 +++++++++++ 2 files changed, 20 insertions(+), 1 deletion(-) diff --git a/docs/3.0/customization.md b/docs/3.0/customization.md index 423fce2f..ba526363 100644 --- a/docs/3.0/customization.md +++ b/docs/3.0/customization.md @@ -530,11 +530,19 @@ You can configure it using `config.turbo` option on `avo.rb` initializer Supported options with default values: -```ruby +:::code-group +```ruby [Current version] config.turbo = -> do { instant_click: true } end ``` +```ruby [3.4.2] + config.turbo = -> do + { + instantclick: true + } + end +``` ::: diff --git a/docs/3.0/upgrade.md b/docs/3.0/upgrade.md index 2b6a9165..8694fd6b 100644 --- a/docs/3.0/upgrade.md +++ b/docs/3.0/upgrade.md @@ -3,6 +3,17 @@ We'll update this page when we release new Avo 3 versions. If you're looking for the Avo 2 to Avo 3 upgrade guide, please visit [the dedicated page](./avo-2-avo-3-upgrade). +## Upgrade from 3.4.2 to 3.4.3 +:::option `turbo` configuration +In version `3.4.2` we introduced turbo configuration with `instantclick` option. We decided that `instant_click` is a more appropriate name. + +```ruby +config.turbo = { + instantclick: true # [!code --] + instant_click: true # [!code ++] +} +``` +::: ## Upgrade from 3.4.1 to 3.4.2 :::option Basic Filters URL param changed to `encoded_filters`