Skip to content

Commit

Permalink
Minimal implementation for hiding header (#69)
Browse files Browse the repository at this point in the history
* Minimal implementation for hiding header

* compile assets

Co-authored-by: Rafael Milewski <[email protected]>
  • Loading branch information
Sabine and milewski authored Sep 20, 2021
1 parent 2bb3973 commit faa3963
Show file tree
Hide file tree
Showing 7 changed files with 2,869 additions and 5,488 deletions.
5 changes: 5 additions & 0 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -171,6 +171,11 @@ MegaFilter::make([
'columnsActive' => false,
'filtersActive' => true,
'actionsActive' => true,

/**
* Show/Hide elements
*/
'showHeader' => true,

/**
* Labels
Expand Down
2 changes: 1 addition & 1 deletion dist/js/card.js

Large diffs are not rendered by default.

8,316 changes: 2,843 additions & 5,473 deletions package-lock.json

Large diffs are not rendered by default.

25 changes: 12 additions & 13 deletions package.json
Original file line number Diff line number Diff line change
@@ -1,22 +1,21 @@
{
"private": true,
"scripts": {
"dev": "npm run development",
"development": "cross-env NODE_ENV=development node_modules/webpack/bin/webpack.js --progress --hide-modules --config=node_modules/laravel-mix/setup/webpack.config.js",
"watch": "cross-env NODE_ENV=development node_modules/webpack/bin/webpack.js --watch --progress --hide-modules --config=node_modules/laravel-mix/setup/webpack.config.js",
"watch-poll": "npm run watch -- --watch-poll",
"hot": "cross-env NODE_ENV=development node_modules/webpack-dev-server/bin/webpack-dev-server.js --inline --hot --config=node_modules/laravel-mix/setup/webpack.config.js",
"prod": "npm run production",
"production": "cross-env NODE_ENV=production node_modules/webpack/bin/webpack.js --progress --hide-modules --config=node_modules/laravel-mix/setup/webpack.config.js"
"development": "mix",
"watch": "mix watch",
"watch-poll": "mix watch -- --watch-options-poll=1000",
"hot": "mix watch --hot",
"production": "mix --production"
},
"devDependencies": {
"cross-env": "^7.0.3",
"laravel-mix": "^5.0.9",
"laravel-nova": "^1.7.0",
"vue-template-compiler": "^2.6.12"
},
"dependencies": {
"vue": "^2.6.12",
"laravel-mix": "^6.0.31",
"laravel-nova": "^1.12.3",
"sass": "^1.41.1",
"sass-loader": "^12.1.0",
"vue": "^2.6.14",
"vue-loader": "^15.9.8",
"vue-template-compiler": "^2.6.14",
"vue2-transitions": "^0.3.0"
}
}
2 changes: 1 addition & 1 deletion resources/js/components/MegaFilter.vue
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,7 @@

<card class="mega-filter flex flex-col p-6" @dblclick.native.self="toggleAllSections">

<div class="flex justify-between items-center">
<div v-if="card.settings.showHeader" class="flex justify-between items-center">

<h4>{{ settings.headerLabel }}</h4>

Expand Down
5 changes: 5 additions & 0 deletions src/MegaFilter.php
Original file line number Diff line number Diff line change
Expand Up @@ -38,6 +38,11 @@ class MegaFilter extends Card
'filtersActive' => true,
'actionsActive' => true,

/**
* Show/Hide elements
*/
'showHeader' => true,

/**
* Labels
*/
Expand Down
2 changes: 2 additions & 0 deletions webpack.mix.js
Original file line number Diff line number Diff line change
@@ -1,6 +1,8 @@
const mix = require('laravel-mix')
const path = require('path')

mix.setPublicPath('dist')
.vue()
.js('resources/js/card.js', 'js')
.webpackConfig({
resolve: {
Expand Down

0 comments on commit faa3963

Please sign in to comment.