forked from roots/sage-installer
-
Notifications
You must be signed in to change notification settings - Fork 44
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Merge pull request roots#43 from strarsis/webpack5
[Sage 9] Update sage-installer to latest dependencies + webpack 5
- Loading branch information
Showing
24 changed files
with
166 additions
and
67 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
|
@@ -7,6 +7,8 @@ | |
"theme", | ||
"foundation", | ||
"bootstrap", | ||
"bootstrap 4", | ||
"bootstrap 5", | ||
"tachyons", | ||
"tailwindcss" | ||
], | ||
|
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,14 @@ | ||
<?php | ||
|
||
namespace Roots\Sage\Installer\Presets; | ||
|
||
class Bootstrap5 extends Preset | ||
{ | ||
/** {@inheritdoc} */ | ||
protected function updatePackagesArray(array $packages) | ||
{ | ||
$packages['dependencies']['bootstrap'] = 'v5.0.1'; | ||
$packages['dependencies']['@popperjs/core'] = '^2.9.2'; | ||
return $packages; | ||
} | ||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,4 @@ | ||
// `sage preset` installed this file automatically. | ||
// Running `sage preset` again could result in automatic deletion of this file. | ||
// Because of this, we do not recommend editing this file. | ||
import 'bootstrap'; |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,4 @@ | ||
// `sage preset` installed this file automatically. | ||
// Running `sage preset` again could result in automatic deletion of this file. | ||
// Because of this, we do not recommend editing this file. | ||
@import "~bootstrap/scss/bootstrap"; |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,8 @@ | ||
// Note: Bootstrap 5 ships with its own default theme colors | ||
|
||
/* | ||
$theme-colors: ( | ||
primary: #525ddc, | ||
secondary: #d1dc52, | ||
); | ||
*/ |
23 changes: 23 additions & 0 deletions
23
src/Presets/stubs/Bootstrap5/styles/components/_comments.scss
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,23 @@ | ||
.comment-list { | ||
@extend .list-unstyled; | ||
} | ||
|
||
.comment-list ol { | ||
list-style: none; | ||
} | ||
|
||
.comment-form p { | ||
@extend .mb-3; | ||
} | ||
|
||
.comment-form input[type="text"], | ||
.comment-form input[type="email"], | ||
.comment-form input[type="url"], | ||
.comment-form textarea { | ||
@extend .form-control; | ||
} | ||
|
||
.comment-form input[type="submit"] { | ||
@extend .btn; | ||
@extend .btn-secondary; | ||
} |
19 changes: 19 additions & 0 deletions
19
src/Presets/stubs/Bootstrap5/styles/components/_forms.scss
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,19 @@ | ||
/** Search form */ | ||
.search-form { | ||
@extend .row; | ||
} | ||
|
||
.search-form label { | ||
@extend .mb-3; | ||
|
||
font-weight: normal; | ||
} | ||
|
||
.search-form .search-field { | ||
@extend .form-control; | ||
} | ||
|
||
.search-form .search-submit { | ||
@extend .btn; | ||
@extend .btn-secondary; | ||
} |
56 changes: 56 additions & 0 deletions
56
src/Presets/stubs/Bootstrap5/styles/components/_wp-classes.scss
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,56 @@ | ||
/** | ||
* WordPress Generated Classes | ||
* @see http://codex.wordpress.org/CSS#WordPress_Generated_Classes | ||
*/ | ||
|
||
/** Media alignment */ | ||
.alignnone { | ||
margin-left: 0; | ||
margin-right: 0; | ||
max-width: 100%; | ||
height: auto; | ||
} | ||
|
||
.aligncenter { | ||
display: block; | ||
margin: ($spacer / 2) auto; | ||
height: auto; | ||
} | ||
|
||
.alignleft, | ||
.alignright { | ||
margin-bottom: ($spacer / 2); | ||
height: auto; | ||
} | ||
|
||
@include media-breakpoint-up(sm) { | ||
.alignleft { | ||
float: left; | ||
margin-right: ($spacer / 2); | ||
} | ||
|
||
.alignright { | ||
float: right; | ||
margin-left: ($spacer / 2); | ||
} | ||
} | ||
|
||
/** Captions */ | ||
.wp-caption { | ||
@extend .figure; | ||
} | ||
|
||
.wp-caption img { | ||
@extend .figure-img; | ||
@extend .img-fluid; | ||
} | ||
|
||
.wp-caption-text { | ||
@extend .figure-caption; | ||
} | ||
|
||
/** Text meant only for screen readers */ | ||
.screen-reader-text { | ||
@extend .visually-hidden; | ||
@extend .visually-hidden-focusable; | ||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,7 @@ | ||
.banner .nav li { | ||
@extend .nav-item; | ||
} | ||
|
||
.banner .nav a { | ||
@extend .nav-link; | ||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,18 @@ | ||
/* eslint-disable */ | ||
|
||
module.exports = (api) => { | ||
|
||
const cssnanoConfig = { | ||
preset: ['default', { discardComments: { removeAll: true } }] | ||
}; | ||
|
||
return { | ||
parser: api.options.ctx.enabled.optimize ? 'postcss-safe-parser' : undefined, | ||
plugins: { | ||
tailwindcss: `${api.options.ctx.paths.assets}/styles/tailwind.config.js`, | ||
autoprefixer: true, | ||
cssnano: api.options.ctx.enabled.optimize ? cssnanoConfig : false, | ||
}, | ||
}; | ||
|
||
}; |
This file was deleted.
Oops, something went wrong.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters