Closed gigorok closed 2 years ago
This is the Sass error I am getting using active_admin 2.10.0:
Error: Undefined variable: "$filter-field-seperator-width".
on line 7:16 of ../../.rbenv/versions/2.7.2/lib/ruby/gems/2.7.0/gems/active_admin_datetimepicker-0.7.4/app/assets/stylesheets/active_admin_datetimepicker.scss
from line 16:9 of app/assets/stylesheets/active_admin.scss
>> width: $filter-field-seperator-width;
My line 16 of app/assets/stylesheets/active_admin.scss
is:
@import "active_admin_datetimepicker";
The issue is fixed for me by changing this line into the following:
$filter-field-seperator-width: 12px;
$sidebar-inner-content-width: $sidebar-width - ($section-padding * 2);
$side-by-side-filter-input-width:
($sidebar-inner-content-width * 0.5) -
($text-input-horizontal-padding * 2) -
$filter-field-seperator-width;
@import "active_admin_datetimepicker";
The issue may come from the fact that these variables are not accessible from the main scope anymore, as they are imported inside a @meda screen
scope. Perhaps we should simply redefine them at the top of active_admin_datepicker
.
@sunny thanks for the workaround. looks like needs to move stylesheets in active_admin_datetimepicker
to @media screen
as well.
@workgena @Fivell what about moving away from travis to github actions? cause now specs are not running
looks like needs to move stylesheets in
active_admin_datetimepicker
to@media screen
as well.
I’ve tried the following, but that doesn’t seem to register as the same shared scope for Sass:
@media print { @import "active_admin_datetimepicker"; }
So I’m guessing we should override the variables, or use new ones. We can also override the variables using the !default;
flag, which ensures that it doesn’t overwrite them if they ever already exist.
Here are the changes we can apply: https://github.com/sunny/active_admin_datetimepicker/pull/1/files
@workgena @Fivell what about moving away from travis to github actions? cause now specs are not running
@gigorok you're admin for this project, feel free to move forward
@gigorok your PR for CI merged!
active_admin_datetimepicker has been already compatible with activeadmin >= v2.11.0 after changes https://github.com/activeadmin/activeadmin/pull/7341. don't think that we have to support compatibility with v2.10.x
the latest active_admin_datetimepicker v0.7.4 is not compatible with activeadmin v2.10.x, but compatible with v2.11.0