Skip to content

Commit

Permalink
refactor: update field.css and FieldServiceProvider.php
Browse files Browse the repository at this point in the history
- Update field.css to remove unused Tailwind CSS imports and modify the Nova editable field styles.
- Update FieldServiceProvider.php to improve code readability and add comments.
  • Loading branch information
ferdiunal committed Sep 16, 2024
1 parent 0299e47 commit 25ef9e8
Show file tree
Hide file tree
Showing 4 changed files with 8 additions and 12 deletions.
2 changes: 1 addition & 1 deletion dist/css/field.css

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

1 change: 0 additions & 1 deletion resources/css/field.css
Original file line number Diff line number Diff line change
@@ -1,4 +1,3 @@
@tailwind base;
@tailwind components;
@tailwind utilities;

Expand Down
2 changes: 1 addition & 1 deletion src/FieldServiceProvider.php
Original file line number Diff line number Diff line change
Expand Up @@ -26,7 +26,7 @@ function () {

/**
* Make the field editable on index page
*
*
* @param NovaRequest $request
* @param string $popoverWidth
*/
Expand Down
15 changes: 6 additions & 9 deletions tailwind.config.js
Original file line number Diff line number Diff line change
@@ -1,19 +1,16 @@
// import novaTailwind from "../../../vendor/laravel/nova/tailwind.config.js";
const path = require("path");
const novaTailwind = require(path.resolve(
__dirname,
"../../vendor/laravel/nova/tailwind.config.js"
));

import { generateTailwindColors } from '../../vendor/laravel/nova/generators'
/** @type {import('tailwindcss').Config} */
module.exports = {
prefix: "nr-",
content: ["./resources/**/*{js,vue,blade.php}"],
darkMode: ["class"],
darkMode: ['class', '[class="dark"]'],
theme: {
colors: novaTailwind.theme.colors,
colors: generateTailwindColors(),
extend: {},
},
corePlugins: {
preflight: false,
},
keyframes: {
slideDownAndFade: {
from: { opacity: 0, transform: "translateY(-2px)" },
Expand Down

0 comments on commit 25ef9e8

Please sign in to comment.