Skip to content

Commit

Permalink
Merge pull request #5 from Codeinwp/fix/issue-4
Browse files Browse the repository at this point in the history
Varius Style Changes
  • Loading branch information
JohnPixle authored Jan 5, 2024
2 parents e9648a4 + cf0b6aa commit b8827bb
Show file tree
Hide file tree
Showing 74 changed files with 111 additions and 3,000 deletions.
14 changes: 7 additions & 7 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -2,15 +2,15 @@

Welcome to the development repository for the default theme that will launch with [WordPress 6.4](https://make.wordpress.org/core/6-4/).

<img width="1920" alt="2023" src="https://github.com/WordPress/twentytwentyfour/assets/1813435/d965b75d-03cd-4365-b963-b3862d482329">
<img width="1920" alt="2023" src="https://github.com/WordPress/quickwp/assets/1813435/d965b75d-03cd-4365-b963-b3862d482329">

Twenty Twenty-Four is built as a [block theme](https://developer.wordpress.org/block-editor/how-to-guides/themes/block-theme-overview/). The theme aims to ship with as little CSS as possible: our goal is for all theme styles to be configured through [`theme.json`](https://developer.wordpress.org/block-editor/how-to-guides/themes/theme-json/) and editable through Global Styles. The theme development team will work closely with [Gutenberg](https://github.com/wordpress/gutenberg) contributors to build design tools in the block editor that enable this goal.

You can view a demo of this theme at [2024.wordpress.net](https://2024.wordpress.net/), which is synced to `trunk` branch of this repository every 2 minutes.

## Contributing

If you would like to contribute code, the list of [open issues](https://github.com/WordPress/twentytwentyfour/issues) is a great place to start looking for tasks — but contributing is not just for developers. There are many opportunities to help with testing, triage, discussion, design, building [patterns](https://github.com/WordPress/twentytwentyfour/issues?q=is%3Aissue+is%3Aopen+label%3A%22%5BComponent%5D+Block+Patterns%22) and templates, and more.
If you would like to contribute code, the list of [open issues](https://github.com/WordPress/quickwp/issues) is a great place to start looking for tasks — but contributing is not just for developers. There are many opportunities to help with testing, triage, discussion, design, building [patterns](https://github.com/WordPress/quickwp/issues?q=is%3Aissue+is%3Aopen+label%3A%22%5BComponent%5D+Block+Patterns%22) and templates, and more.

If you'd like to help with triage, let @luminuu and @MaggieCabrera know in [WordPress.org's Slack instance](https://make.wordpress.org/chat/). We'll help you get set up with the ability to add labels to issues and PRs.

Expand All @@ -26,9 +26,9 @@ Also, consider enabling [development mode](https://make.wordpress.org/core/2023/

### Design

The theme is designed in [Figma](https://www.figma.com/file/AlYr03vh4dVimwYwQkTdf6/Twenty-Twenty-Four?type=design&t=C79166eDp3vX7OOD-6). You can contribute by designing one of the [patterns](https://github.com/WordPress/twentytwentyfour/issues?q=is%3Aissue+is%3Aopen+label%3A%22%5BComponent%5D+Block+Patterns%22) planned for Twenty Twenty-Four.
The theme is designed in [Figma](https://www.figma.com/file/AlYr03vh4dVimwYwQkTdf6/Twenty-Twenty-Four?type=design&t=C79166eDp3vX7OOD-6). You can contribute by designing one of the [patterns](https://github.com/WordPress/quickwp/issues?q=is%3Aissue+is%3Aopen+label%3A%22%5BComponent%5D+Block+Patterns%22) planned for Twenty Twenty-Four.

As a default WordPress theme, it is important to leverage the existing design system wherever possible. That is the font sizes, [color palette choices](https://github.com/WordPress/twentytwentyfour/pull/106), and [spacing presets](https://github.com/WordPress/twentytwentyfour/pull/102). All patterns and templates will leverage this systems extensively.
As a default WordPress theme, it is important to leverage the existing design system wherever possible. That is the font sizes, [color palette choices](https://github.com/WordPress/quickwp/pull/106), and [spacing presets](https://github.com/WordPress/quickwp/pull/102). All patterns and templates will leverage this systems extensively.

## Token Cheat-sheet

Expand Down Expand Up @@ -110,15 +110,15 @@ Make sure to add alt text to your images and to make sure to remove the IDs from

```
<!-- wp:image {"id":125,"sizeSlug":"large","linkDestination":"none"} -->
<figure class="wp-block-image size-large"><img src="http://wp-stable.test/wp-content/themes/twentytwentyfour/assets/images/project.webp" alt="" class="wp-image-125"/></figure>
<figure class="wp-block-image size-large"><img src="http://wp-stable.test/wp-content/themes/quickwp/assets/images/project.webp" alt="" class="wp-image-125"/></figure>
<!-- /wp:image -->
```

would turn into

```
<!-- wp:image {"sizeSlug":"large","linkDestination":"none"} -->
<figure class="wp-block-image size-large"><img src="<?php echo esc_url( get_template_directory_uri() ); ?>/assets/images/project.webp" alt="<?php echo esc_attr_x( 'Picture of a building', 'Alt text for project picture', 'twentytwentyfour' ); ?>"/></figure>
<figure class="wp-block-image size-large"><img src="<?php echo esc_url( get_template_directory_uri() ); ?>/assets/images/project.webp" alt="<?php echo esc_attr_x( 'Picture of a building', 'Alt text for project picture', 'quickwp' ); ?>"/></figure>
<!-- /wp:image -->
```

Expand Down Expand Up @@ -152,7 +152,7 @@ turns into

and

`<!-- wp:template-part {"slug":"header-portfolio","theme":"twentytwentyfour","area":"header","tagName":"header"} /-->`
`<!-- wp:template-part {"slug":"header-portfolio","theme":"quickwp","area":"header","tagName":"header"} /-->`

turns into

Expand Down
12 changes: 3 additions & 9 deletions composer.json
Original file line number Diff line number Diff line change
@@ -1,19 +1,13 @@
{
"name": "wordpress/twentytwentyfour",
"name": "codeinwp/quickwp",
"type": "package",
"description": "The default WordPress theme for 2024",
"description": "The default QuickWP theme.",
"keywords": [
"WordPress",
"Themes"
],
"homepage": "https://github.com/WordPress/twentytwentyfour",
"homepage": "https://github.com/Codeinwp/quickwp-theme",
"license": "GPL-2.0-or-later",
"authors": [
{
"name": "Contributors",
"homepage": "https://github.com/WordPress/twentytwentyfour/contributors.md"
}
],
"require": {
"php": ">=5.6"
},
Expand Down
51 changes: 37 additions & 14 deletions composer.lock

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

43 changes: 29 additions & 14 deletions functions.php
Original file line number Diff line number Diff line change
Expand Up @@ -8,24 +8,39 @@
* @since Twenty Twenty-Four 1.0
*/

/**
* Register Theme Support
*/

if ( ! function_exists( 'quickwp_setup' ) ) :
/**
* Sets up theme defaults and registers support for various WordPress features.
*/
function quickwp_setup() {
remove_theme_support( 'core-block-patterns' );
}
endif;

add_action( 'after_setup_theme', 'quickwp_setup' );

/**
* Register block styles.
*/

if ( ! function_exists( 'twentytwentyfour_block_styles' ) ) :
if ( ! function_exists( 'quickwp_block_styles' ) ) :
/**
* Register custom block styles
*
* @since Twenty Twenty-Four 1.0
* @return void
*/
function twentytwentyfour_block_styles() {
function quickwp_block_styles() {

register_block_style(
'core/details',
array(
'name' => 'arrow-icon-details',
'label' => __( 'Arrow icon', 'twentytwentyfour' ),
'label' => __( 'Arrow icon', 'quickwp' ),
/*
* Styles for the custom Arrow icon style of the Details block
*/
Expand All @@ -48,7 +63,7 @@ function twentytwentyfour_block_styles() {
'core/post-terms',
array(
'name' => 'pill',
'label' => __( 'Pill', 'twentytwentyfour' ),
'label' => __( 'Pill', 'quickwp' ),
/*
* Styles variation for post terms
* https://github.com/WordPress/gutenberg/issues/24956
Expand All @@ -75,7 +90,7 @@ function twentytwentyfour_block_styles() {
'core/list',
array(
'name' => 'checkmark-list',
'label' => __( 'Checkmark', 'twentytwentyfour' ),
'label' => __( 'Checkmark', 'quickwp' ),
/*
* Styles for the custom checkmark list block style
* https://github.com/WordPress/gutenberg/issues/51480
Expand All @@ -94,7 +109,7 @@ function twentytwentyfour_block_styles() {
'core/navigation-link',
array(
'name' => 'arrow-link',
'label' => __( 'With arrow', 'twentytwentyfour' ),
'label' => __( 'With arrow', 'quickwp' ),
/*
* Styles for the custom arrow nav link block style
*/
Expand All @@ -111,20 +126,20 @@ function twentytwentyfour_block_styles() {
}
endif;

add_action( 'init', 'twentytwentyfour_block_styles' );
add_action( 'init', 'quickwp_block_styles' );

/**
* Enqueue block stylesheets.
*/

if ( ! function_exists( 'twentytwentyfour_block_stylesheets' ) ) :
if ( ! function_exists( 'quickwp_block_stylesheets' ) ) :
/**
* Enqueue custom block stylesheets
*
* @since Twenty Twenty-Four 1.0
* @return void
*/
function twentytwentyfour_block_stylesheets() {
function quickwp_block_stylesheets() {
/**
* The wp_enqueue_block_style() function allows us to enqueue a stylesheet
* for a specific block. These will only get loaded when the block is rendered
Expand All @@ -136,7 +151,7 @@ function twentytwentyfour_block_stylesheets() {
wp_enqueue_block_style(
'core/button',
array(
'handle' => 'twentytwentyfour-button-style-outline',
'handle' => 'quickwp-button-style-outline',
'src' => get_parent_theme_file_uri( 'assets/css/button-outline.css' ),
'ver' => wp_get_theme( get_template() )->get( 'Version' ),
'path' => get_parent_theme_file_path( 'assets/css/button-outline.css' ),
Expand All @@ -145,20 +160,20 @@ function twentytwentyfour_block_stylesheets() {
}
endif;

add_action( 'init', 'twentytwentyfour_block_stylesheets' );
add_action( 'init', 'quickwp_block_stylesheets' );

/**
* Register pattern categories.
*/

if ( ! function_exists( 'twentytwentyfour_pattern_categories' ) ) :
if ( ! function_exists( 'quickwp_pattern_categories' ) ) :
/**
* Register pattern categories
*
* @since Twenty Twenty-Four 1.0
* @return void
*/
function twentytwentyfour_pattern_categories() {
function quickwp_pattern_categories() {

register_block_pattern_category(
'page',
Expand All @@ -170,4 +185,4 @@ function twentytwentyfour_pattern_categories() {
}
endif;

add_action( 'init', 'twentytwentyfour_pattern_categories' );
add_action( 'init', 'quickwp_pattern_categories' );
4 changes: 2 additions & 2 deletions package-lock.json

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

8 changes: 4 additions & 4 deletions package.json
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
{
"name": "twentytwentyfour",
"name": "quickwp",
"private": true,
"version": "0.0.1",
"description": "The default WordPress theme for 2024",
Expand All @@ -9,13 +9,13 @@
"WordPress",
"theme"
],
"homepage": "https://github.com/WordPress/twentytwentyfour#readme",
"homepage": "https://github.com/WordPress/quickwp#readme",
"repository": {
"type": "git",
"url": "git+https://github.com/WordPress/twentytwentyfour.git"
"url": "git+https://github.com/WordPress/quickwp.git"
},
"bugs": {
"url": "https://github.com/WordPress/twentytwentyfour/issues"
"url": "https://github.com/WordPress/quickwp/issues"
},
"devDependencies": {
"@wordpress/stylelint-config": "^20.0.2",
Expand Down
2 changes: 1 addition & 1 deletion parts/footer.html
Original file line number Diff line number Diff line change
@@ -1 +1 @@
<!-- wp:pattern {"slug":"twentytwentyfour/footer"} /-->
<!-- wp:pattern {"slug":"quickwp/footer"} /-->
2 changes: 1 addition & 1 deletion parts/post-meta.html
Original file line number Diff line number Diff line change
@@ -1 +1 @@
<!-- wp:pattern {"slug":"twentytwentyfour/hidden-post-meta"} /-->
<!-- wp:pattern {"slug":"quickwp/hidden-post-meta"} /-->
2 changes: 1 addition & 1 deletion parts/sidebar.html
Original file line number Diff line number Diff line change
@@ -1 +1 @@
<!-- wp:pattern {"slug":"twentytwentyfour/hidden-sidebar"} /-->
<!-- wp:pattern {"slug":"quickwp/hidden-sidebar"} /-->
Loading

0 comments on commit b8827bb

Please sign in to comment.