Skip to content

Comments

Upgrade to V4#61

Open
davidpiesse wants to merge 6 commits intomasterfrom
v4
Open

Upgrade to V4#61
davidpiesse wants to merge 6 commits intomasterfrom
v4

Conversation

@davidpiesse
Copy link
Owner

An initial version of Toggle for Nova V4.

@davidpiesse davidpiesse mentioned this pull request Jul 21, 2022
@hoczeus
Copy link

hoczeus commented Jul 30, 2022

Feedback: The toggle without more options runs pretty well.
Options like ->editableIndex() or ->falseColor('#bacad6') gets Errors

@muhammadsaeedparacha
Copy link

Bump

@davidpiesse davidpiesse changed the title Upgarde to V4 Upgrade to V4 Oct 3, 2022
@VGirol
Copy link

VGirol commented Oct 3, 2022

When using nova-toggle with Nova 4, there is a bug : in each create form, the save buttons are not well displayed.
When inspecting the html elements, we can see that the css rules provided by the last version of this package conflict with the rules provided by Nova. The background color provided by Nova css class :
.bg-primary-500 { background-color: rgba(var(--colors-primary-500)); }
is overwritten by a rule provided by nova-toggle.css :
[type=button], [type=reset], [type=submit], button { -webkit-appearance: button; background-color: transparent; background-image: none; }
I think there is no need to export a css file with only the tailwind presets.

@VGirol
Copy link

VGirol commented Oct 15, 2022

In the dist/css/field.css file, you can safely remove all selectors that don't begin with tw-.
To do so, you could use the postcss-purgecss-laravel package and modify the webpack.mix.js file as below :

.postCss('resources/sass/app.css', 'public/css', [ require('tailwindcss')(), require('postcss-purgecss-laravel')({ safelist: { greedy: [/^tw-/] } }), ])
I haven't tested it, but I think it might work.

@VGirol
Copy link

VGirol commented Feb 4, 2023

Ok,
Disregard my two previous comments : after upgrading to the latest commit, everything is ok.
I'm sorry for the inconvenience.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

5 participants