You've already forked wp-bootstrap
Initial theme scaffolding (v0.0.1)
- Bootstrap 5 CSS/JS integration via Yarn (served locally) - Dart Sass build pipeline with PostCSS, Autoprefixer, cssnano - Twig 3.0 via Composer with PSR-4 autoloading - FSE block theme templates (index, home, single, page, archive, search, 404) - Template parts (header, footer) and block patterns - theme.json with Bootstrap 5-aligned design tokens - Gitea CI/CD workflow for automated release packages - WordPress i18n support (en_US base, de_CH translation) Co-Authored-By: Claude <noreply@anthropic.com>
This commit is contained in:
2
src/scss/_custom.scss
Normal file
2
src/scss/_custom.scss
Normal file
@@ -0,0 +1,2 @@
|
||||
// Custom theme styles
|
||||
// Add theme-specific styles here that go beyond Bootstrap defaults
|
||||
42
src/scss/_variables.scss
Normal file
42
src/scss/_variables.scss
Normal file
@@ -0,0 +1,42 @@
|
||||
// Bootstrap variable overrides
|
||||
// These MUST be defined BEFORE importing Bootstrap's variables
|
||||
|
||||
// Colors - matching theme.json palette
|
||||
$white: #FFFFFF;
|
||||
$gray-100: #f8f9fa;
|
||||
$gray-200: #e9ecef;
|
||||
$gray-300: #dee2e6;
|
||||
$gray-400: #ced4da;
|
||||
$gray-500: #adb5bd;
|
||||
$gray-600: #6c757d;
|
||||
$gray-700: #495057;
|
||||
$gray-800: #343a40;
|
||||
$gray-900: #212529;
|
||||
$black: #000000;
|
||||
|
||||
$primary: #0d6efd;
|
||||
$secondary: #6c757d;
|
||||
$success: #198754;
|
||||
$danger: #dc3545;
|
||||
$warning: #ffc107;
|
||||
$info: #0dcaf0;
|
||||
$light: $gray-100;
|
||||
$dark: $gray-800;
|
||||
|
||||
// Layout
|
||||
$container-max-widths: (
|
||||
sm: 540px,
|
||||
md: 720px,
|
||||
lg: 960px,
|
||||
xl: 1140px,
|
||||
xxl: 1320px
|
||||
);
|
||||
|
||||
// Typography - using system fonts (matching theme.json)
|
||||
$font-family-sans-serif: system-ui, -apple-system, "Segoe UI", Roboto, "Helvetica Neue", "Noto Sans", "Liberation Sans", Arial, sans-serif, "Apple Color Emoji", "Segoe UI Emoji", "Segoe UI Symbol", "Noto Color Emoji";
|
||||
|
||||
// Enable dark mode
|
||||
$enable-dark-mode: true;
|
||||
|
||||
// Enable reduced motion
|
||||
$enable-reduced-motion: true;
|
||||
37
src/scss/_wordpress.scss
Normal file
37
src/scss/_wordpress.scss
Normal file
@@ -0,0 +1,37 @@
|
||||
// WordPress FSE block compatibility with Bootstrap 5
|
||||
// Ensures Bootstrap styles don't conflict with block editor styles
|
||||
|
||||
// Focus styles
|
||||
:where(.wp-site-blocks *:focus) {
|
||||
outline-width: 2px;
|
||||
outline-style: solid;
|
||||
}
|
||||
|
||||
// Prevent Bootstrap's reboot from conflicting with block editor
|
||||
.wp-block-group,
|
||||
.wp-block-columns,
|
||||
.wp-block-column {
|
||||
box-sizing: border-box;
|
||||
}
|
||||
|
||||
// Navigation block compatibility
|
||||
.wp-block-navigation {
|
||||
.wp-block-navigation-item__content {
|
||||
outline-offset: 4px;
|
||||
}
|
||||
}
|
||||
|
||||
// Text wrapping (progressive enhancement)
|
||||
h1, h2, h3, h4, h5, h6, blockquote, caption, figcaption, p {
|
||||
text-wrap: pretty;
|
||||
}
|
||||
|
||||
// More block
|
||||
.more-link {
|
||||
display: block;
|
||||
}
|
||||
|
||||
// Preformatted text
|
||||
:where(pre) {
|
||||
overflow-x: auto;
|
||||
}
|
||||
23
src/scss/editor-style.scss
Normal file
23
src/scss/editor-style.scss
Normal file
@@ -0,0 +1,23 @@
|
||||
/*!
|
||||
* WP Bootstrap Theme - Editor Styles
|
||||
*/
|
||||
|
||||
// Import Bootstrap functions and variables for consistency
|
||||
@import "bootstrap/scss/functions";
|
||||
@import "variables";
|
||||
@import "bootstrap/scss/variables";
|
||||
@import "bootstrap/scss/variables-dark";
|
||||
@import "bootstrap/scss/maps";
|
||||
@import "bootstrap/scss/mixins";
|
||||
@import "bootstrap/scss/root";
|
||||
|
||||
// Editor-specific adjustments
|
||||
.editor-styles-wrapper {
|
||||
font-family: system-ui, -apple-system, "Segoe UI", Roboto, "Helvetica Neue", Arial, sans-serif;
|
||||
line-height: 1.5;
|
||||
|
||||
a {
|
||||
text-decoration-thickness: 1px !important;
|
||||
text-underline-offset: 0.1em;
|
||||
}
|
||||
}
|
||||
19
src/scss/style.scss
Normal file
19
src/scss/style.scss
Normal file
@@ -0,0 +1,19 @@
|
||||
/*!
|
||||
* WP Bootstrap Theme
|
||||
* Built with Bootstrap 5
|
||||
*/
|
||||
|
||||
// 1. Import Bootstrap functions first (needed for variable manipulation)
|
||||
@import "bootstrap/scss/functions";
|
||||
|
||||
// 2. Override Bootstrap variables BEFORE they're set
|
||||
@import "variables";
|
||||
|
||||
// 3. Import all of Bootstrap
|
||||
@import "bootstrap/scss/bootstrap";
|
||||
|
||||
// 4. WordPress block compatibility
|
||||
@import "wordpress";
|
||||
|
||||
// 5. Custom styles
|
||||
@import "custom";
|
||||
Reference in New Issue
Block a user