diff --git a/README.md b/README.md index 6b5f016..36ec413 100644 --- a/README.md +++ b/README.md @@ -35,7 +35,7 @@ Or add manually to `package.json`: ``` "dependencies": { - "@activeadmin-plugins/active_admin_theme": "^2.0.0" + "@activeadmin-plugins/active_admin_theme": "^3.0.0" } ``` and execute: @@ -159,9 +159,9 @@ cannot show both. `auto` removes the attribute, so the media query decides and the page follows the operating system live; the other two pin the choice in `localStorage` under -`aa-theme`. ActiveAdmin 4's own toggle writes `light` or `dark` on the first -click and never writes `auto` back, so a user there cannot return to following -the system without clearing storage by hand — hence the third state. +`aa-theme`. The third state is there so that following the system stays +reachable: a two-state toggle writes a preference on the first click and has no +way back short of clearing storage by hand. The glyphs are inline SVG used as a CSS `mask`, so the gem still ships no image files, there is nothing for a host application's CSP to allow, and the icon diff --git a/app/assets/javascripts/wigu/theme_toggle.js b/app/assets/javascripts/wigu/theme_toggle.js index 9a7f45e..d96b516 100644 --- a/app/assets/javascripts/wigu/theme_toggle.js +++ b/app/assets/javascripts/wigu/theme_toggle.js @@ -10,9 +10,9 @@ // a project can restyle it, instead of in a script it would have to fork. // // Binds by delegation to anything carrying .dark-mode-toggle or #theme_toggle, -// the way ActiveAdmin 4 does, so the control can live anywhere and survive a -// re-render. If neither exists it appends its own entry to the utility -// navigation. No jQuery and no ujs, so it does not care how the admin is built. +// so the control can live anywhere and survive a re-render. If neither exists +// it inserts its own entry into the utility navigation. No jQuery and no ujs, +// so it does not care how the admin is built. (function () { "use strict"; diff --git a/lib/active_admin_theme/version.rb b/lib/active_admin_theme/version.rb index 82ef7bf..b26db68 100644 --- a/lib/active_admin_theme/version.rb +++ b/lib/active_admin_theme/version.rb @@ -1,3 +1,3 @@ module ActiveAdminTheme - VERSION = "2.0.0" + VERSION = "3.0.0" end diff --git a/package.json b/package.json index 3565393..55a0eb5 100644 --- a/package.json +++ b/package.json @@ -1,6 +1,6 @@ { "name": "@activeadmin-plugins/active_admin_theme", - "version": "2.0.0", + "version": "3.0.0", "description": "Flat design for ActiveAdmin", "main": "src/active_admin_theme.scss", "author": "Igor Fedoronchuk ",