From 3ab108f80e017429199bc0d7e18a2c678c2aeced Mon Sep 17 00:00:00 2001 From: Devanshi Joshi <86941664+devanshijoshi9@users.noreply.github.com> Date: Fri, 19 Aug 2022 10:51:55 +0530 Subject: [PATCH 1/9] Modify style file and readme file --- README.md | 23 +++++++++++++++++++---- composer.json | 5 ++++- languages/blank-theme.pot | 2 +- style.css | 17 +++++++++++++++++ 4 files changed, 41 insertions(+), 6 deletions(-) diff --git a/README.md b/README.md index 101edae..4295cc1 100644 --- a/README.md +++ b/README.md @@ -1,17 +1,32 @@ Blank Theme === -Blank Theme is a custom blank theme created with underscore theme, which includes foundation basic grid system and some basic customizer settings which are required in almost all projects. +Blank Theme is a custom blank theme created with underscore theme, which includes foundation basic grid system and some basic customizer settings which are required in almost all projects. Here are some of the other more interesting things you'll find here: + +* A modern workflow with a pre-made command-line interface to turn your project into a more pleasant experience. +* A just right amount of lean, well-commented, modern, HTML5 templates. +* class-assets that enqueue all you require css and js files. + Getting Started --------------- -After cloning repo run +### Requirements + +`Blank Theme` requires the following dependencies: + +- [Node.js](https://nodejs.org/) +- [Composer](https://getcomposer.org/) + +### Setup + +After cloning/downloading repository, you need to install the necessary Node.js and Composer dependencies : ```bash -npm install +$ composer install +$ npm install ``` and then run the following command which will prompt for the theme name, start renaming and do cleanup. @@ -31,7 +46,7 @@ npm run prod # When ready for production -#### Other Commands +#### Available CLI commands ```bash # Generate pot files diff --git a/composer.json b/composer.json index e931d5f..2ae9d85 100644 --- a/composer.json +++ b/composer.json @@ -16,7 +16,10 @@ }, "config": { "discard-changes": true, - "sort-packages": true + "sort-packages": true, + "allow-plugins": { + "dealerdirect/phpcodesniffer-composer-installer": true + } }, "minimum-stability": "dev", "prefer-stable": true, diff --git a/languages/blank-theme.pot b/languages/blank-theme.pot index 1e41a6a..5902e50 100644 --- a/languages/blank-theme.pot +++ b/languages/blank-theme.pot @@ -1,4 +1,4 @@ -# Copyright (C) 2021 Blank Theme +# Copyright (C) 2022 Blank Theme # This file is distributed under the same license as the Blank Theme package. msgid "" msgstr "" diff --git a/style.css b/style.css index b872c38..0663082 100644 --- a/style.css +++ b/style.css @@ -20,3 +20,20 @@ Underscores is distributed under the terms of the GNU GPL v2 or later. Normalizing styles have been helped along thanks to the fine work of Nicolas Gallagher and Jonathan Neal http://necolas.github.com/normalize.css/ */ + +/*-------------------------------------------------------------- +>>> TABLE OF CONTENTS: +---------------------------------------------------------------- +# Generic + - Normalize + +--------------------------------------------------------------*/ + +/*-------------------------------------------------------------- +# Generic +--------------------------------------------------------------*/ + +/* Normalize +--------------------------------------------- */ + +/*! normalize.css v8.0.1 | MIT License | github.com/necolas/normalize.css */ From 930ed76f4f869dc52a516f0f8418737ec30ada82 Mon Sep 17 00:00:00 2001 From: Devanshi Joshi <86941664+devanshijoshi9@users.noreply.github.com> Date: Wed, 24 Aug 2022 17:26:52 +0530 Subject: [PATCH 2/9] Modify readme file --- README.md | 8 ++++++-- 1 file changed, 6 insertions(+), 2 deletions(-) diff --git a/README.md b/README.md index 4295cc1..83dfee5 100644 --- a/README.md +++ b/README.md @@ -5,8 +5,12 @@ Blank Theme is a custom blank theme created with underscore theme, which include * A modern workflow with a pre-made command-line interface to turn your project into a more pleasant experience. * A just right amount of lean, well-commented, modern, HTML5 templates. -* class-assets that enqueue all you require css and js files. - +* `class-assets.php` that enqueue all your require css and js files. +* `class-blank-theme.php` file in inc/classes is where the theme is setup. This file add all the require theme supports. +* Customizer registration and settings added in `inc/classes/class-customizer.php` file. +* 2 widgets ( Sidebar & Footer ) added in `inc/classes/class-widgets.php` file. +* `inc/helpers/custom-functions.php` where you can add your custom functions. +* Custom template tags in `inc/helpers/template-tags.php` that keep your templates clean and neat and prevent code duplication. From 76bc7a172bf0d48f557cd780de07b10fe9b9e546 Mon Sep 17 00:00:00 2001 From: Devanshi Joshi <86941664+devanshijoshi9@users.noreply.github.com> Date: Wed, 24 Aug 2022 17:46:32 +0530 Subject: [PATCH 3/9] Add assets description in readme file --- README.md | 3 +++ 1 file changed, 3 insertions(+) diff --git a/README.md b/README.md index 83dfee5..8aaa63e 100644 --- a/README.md +++ b/README.md @@ -11,6 +11,9 @@ Blank Theme is a custom blank theme created with underscore theme, which include * 2 widgets ( Sidebar & Footer ) added in `inc/classes/class-widgets.php` file. * `inc/helpers/custom-functions.php` where you can add your custom functions. * Custom template tags in `inc/helpers/template-tags.php` that keep your templates clean and neat and prevent code duplication. +* In `assets/src/js/admin/customizer.js` file, Theme Customizer enhancements added for a better user experience. +* `assets/src/js/components` where you can add the common components for the theme. +* You can add styles in `assets/src/sass` folder. From 944334ae083076dd03e7ac062486fc35a1786e04 Mon Sep 17 00:00:00 2001 From: Devanshi Joshi <86941664+devanshijoshi9@users.noreply.github.com> Date: Wed, 24 Aug 2022 17:48:01 +0530 Subject: [PATCH 4/9] Remove extra space in readme file --- README.md | 1 - 1 file changed, 1 deletion(-) diff --git a/README.md b/README.md index 8aaa63e..7ae35ac 100644 --- a/README.md +++ b/README.md @@ -16,7 +16,6 @@ Blank Theme is a custom blank theme created with underscore theme, which include * You can add styles in `assets/src/sass` folder. - Getting Started --------------- From 531d274120e5f0425ce16df7cba94657cefe43dc Mon Sep 17 00:00:00 2001 From: Devanshi Joshi <86941664+devanshijoshi9@users.noreply.github.com> Date: Fri, 30 Dec 2022 18:38:13 +0530 Subject: [PATCH 5/9] Remove normalise term from the table of contents --- style.css | 5 ----- 1 file changed, 5 deletions(-) diff --git a/style.css b/style.css index 0663082..ce2cf6f 100644 --- a/style.css +++ b/style.css @@ -32,8 +32,3 @@ Nicolas Gallagher and Jonathan Neal http://necolas.github.com/normalize.css/ /*-------------------------------------------------------------- # Generic --------------------------------------------------------------*/ - -/* Normalize ---------------------------------------------- */ - -/*! normalize.css v8.0.1 | MIT License | github.com/necolas/normalize.css */ From 6c879ea81ca1eb28d0d0246ae9a56c34d915ffdc Mon Sep 17 00:00:00 2001 From: Devanshi Joshi <86941664+devanshijoshi9@users.noreply.github.com> Date: Fri, 30 Dec 2022 18:41:45 +0530 Subject: [PATCH 6/9] Remove table of content from style.css file --- style.css | 12 ------------ 1 file changed, 12 deletions(-) diff --git a/style.css b/style.css index ce2cf6f..b872c38 100644 --- a/style.css +++ b/style.css @@ -20,15 +20,3 @@ Underscores is distributed under the terms of the GNU GPL v2 or later. Normalizing styles have been helped along thanks to the fine work of Nicolas Gallagher and Jonathan Neal http://necolas.github.com/normalize.css/ */ - -/*-------------------------------------------------------------- ->>> TABLE OF CONTENTS: ----------------------------------------------------------------- -# Generic - - Normalize - ---------------------------------------------------------------*/ - -/*-------------------------------------------------------------- -# Generic ---------------------------------------------------------------*/ From ad30531917137ed1b48768b44a07f0709032ddbd Mon Sep 17 00:00:00 2001 From: Devanshi Joshi <86941664+devanshijoshi9@users.noreply.github.com> Date: Mon, 2 Jan 2023 19:24:12 +0530 Subject: [PATCH 7/9] Add hint of the theme origin description --- README.md | 2 +- style.css | 3 +-- 2 files changed, 2 insertions(+), 3 deletions(-) diff --git a/README.md b/README.md index 7ae35ac..cc7442e 100644 --- a/README.md +++ b/README.md @@ -1,7 +1,7 @@ Blank Theme === -Blank Theme is a custom blank theme created with underscore theme, which includes foundation basic grid system and some basic customizer settings which are required in almost all projects. Here are some of the other more interesting things you'll find here: +Blank Theme is a custom Blank theme created with underscore theme, which includes foundation basic grid system and some basic customizer settings which are required in almost all projects. Here are some of the other more interesting things you'll find here: * A modern workflow with a pre-made command-line interface to turn your project into a more pleasant experience. * A just right amount of lean, well-commented, modern, HTML5 templates. diff --git a/style.css b/style.css index b872c38..f98dd80 100644 --- a/style.css +++ b/style.css @@ -14,8 +14,7 @@ This theme, like WordPress, is licensed under the GPL. Use it to make something cool, have fun, and share what you've learned with others. -Blank Theme is based on Underscores http://underscores.me/, (C) 2012-2015 Automattic, Inc. -Underscores is distributed under the terms of the GNU GPL v2 or later. +Blank Theme is based on Blank theme https://github.com/rtCamp/blankTheme Normalizing styles have been helped along thanks to the fine work of Nicolas Gallagher and Jonathan Neal http://necolas.github.com/normalize.css/ From 8be9b18d211de5e87ab13027486c588394383816 Mon Sep 17 00:00:00 2001 From: Devanshi Joshi <86941664+devanshijoshi9@users.noreply.github.com> Date: Mon, 2 Jan 2023 19:37:19 +0530 Subject: [PATCH 8/9] Modify search-replace functionality in init file --- bin/init.js | 8 ++++++++ 1 file changed, 8 insertions(+) diff --git a/bin/init.js b/bin/init.js index a62a69b..efe86d9 100755 --- a/bin/init.js +++ b/bin/init.js @@ -154,6 +154,9 @@ const initTheme = (themeInfo) => { blank_theme_: themeInfo.snakeCaseWithUnderscoreSuffix, Blank_Theme_: themeInfo.pascalSnakeCaseWithUnderscoreSuffix, BLANK_THEME_: themeInfo.macroCaseWithUnderscoreSuffix, + 'Blank theme': 'Blank Theme', + 'underscore theme': 'Blank Theme', + blankTheme: 'blank-theme', }; const files = getAllFiles(getRoot()); @@ -239,6 +242,11 @@ const getAllFiles = (dir) => { */ const replaceFileContent = (files, chunksToReplace, newChunk) => { files.forEach((file) => { + + if(path.basename(file) === 'init.js' && (chunksToReplace === 'Blank theme' || chunksToReplace === 'underscore theme' || chunksToReplace === 'blankTheme')) { + return; + } + const filePath = path.resolve(getRoot(), file); try { From 16fd9284280996c132bbe39442427a3d2014635f Mon Sep 17 00:00:00 2001 From: Devanshi Joshi <86941664+devanshijoshi9@users.noreply.github.com> Date: Tue, 3 Jan 2023 09:25:36 +0530 Subject: [PATCH 9/9] Modify readme content --- README.md | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/README.md b/README.md index cc7442e..aec43e5 100644 --- a/README.md +++ b/README.md @@ -1,7 +1,7 @@ Blank Theme === -Blank Theme is a custom Blank theme created with underscore theme, which includes foundation basic grid system and some basic customizer settings which are required in almost all projects. Here are some of the other more interesting things you'll find here: +Blank Theme is a custom theme created with underscore theme, which includes foundation basic grid system and some basic customizer settings which are required in almost all projects. Here are some of the other more interesting things you'll find here: * A modern workflow with a pre-made command-line interface to turn your project into a more pleasant experience. * A just right amount of lean, well-commented, modern, HTML5 templates.